{"id":20258567,"url":"https://github.com/kaleharshavardhan07/multi_thread_file_downloader","last_synced_at":"2025-10-08T14:24:41.661Z","repository":{"id":251374866,"uuid":"837229592","full_name":"kaleharshavardhan07/Multi_thread_File_downloader","owner":"kaleharshavardhan07","description":"This project is a C++ multithreaded file downloader that utilizes the cURL library to download a large file in parts concurrently. Each part is downloaded by a separate thread, and the parts are then merged to form the complete file.","archived":false,"fork":false,"pushed_at":"2024-08-02T13:48:17.000Z","size":5,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-14T04:09:17.775Z","etag":null,"topics":["cpp","multithreading"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kaleharshavardhan07.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-02T13:41:46.000Z","updated_at":"2024-12-10T06:41:11.000Z","dependencies_parsed_at":"2024-08-02T15:40:48.597Z","dependency_job_id":null,"html_url":"https://github.com/kaleharshavardhan07/Multi_thread_File_downloader","commit_stats":null,"previous_names":["kaleharshavardhan07/multi_thread_file_downloader"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kaleharshavardhan07%2FMulti_thread_File_downloader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kaleharshavardhan07%2FMulti_thread_File_downloader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kaleharshavardhan07%2FMulti_thread_File_downloader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kaleharshavardhan07%2FMulti_thread_File_downloader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kaleharshavardhan07","download_url":"https://codeload.github.com/kaleharshavardhan07/Multi_thread_File_downloader/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241717935,"owners_count":20008472,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpp","multithreading"],"created_at":"2024-11-14T11:09:40.617Z","updated_at":"2025-10-08T14:24:36.594Z","avatar_url":"https://github.com/kaleharshavardhan07.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"Certainly! Here’s the updated `README.md` with added tags for better searchability.\n\n---\n\n# C++ Multithreaded File Downloader\n\n## Overview\n\nThis project is a C++ multithreaded file downloader that utilizes the cURL library to download a large file in parts concurrently. Each part is downloaded by a separate thread, and the parts are then merged to form the complete file.\n\n## Features\n\n- **Multithreaded Downloading**: Splits the file into multiple parts and downloads them simultaneously.\n- **Part Merging**: Merges the downloaded parts into a single file.\n- **cURL Integration**: Uses the cURL library for HTTP requests and file downloads.\n\n## Requirements\n\n- **C++ Compiler**: A C++11 compliant compiler.\n- **cURL Library**: The cURL library should be installed and linked with your project.\n\n## Clone the Repository\n\n1. **Clone the Repository**:\n\n   ```bash\n   git clone https://github.com/kaleharshavardhan07/Multi_thread_File_downloader.git\n   ```\n\n\n\n## Build the Project\n\n1. **Install cURL**: Ensure cURL is installed on your system. You can download it from [cURL's official website](https://curl.se/download.html).\n\n2. **Compile the Code**: Use the following command to compile the code with g++ (assuming cURL is correctly installed and linked):\n\n   ```bash\n   g++ -std=c++11 -o downloader downloader.cpp -lcurl\n   ```\n\n   Replace `downloader.cpp` with the name of your source file if different.\n\n## How to Run\n\n1. **Execute the Program**:\n\n   ```bash\n   ./downloader\n   ```\n\n2. **Input the URL**: Enter the URL of the file you wish to download when prompted.\n\n3. **Specify the File Size**: Enter the total size of the file in bytes.\n\n   - The program will split the file into parts and start downloading each part in a separate thread.\n   - After all threads complete, the downloaded parts will be merged into a single file named `largefile.zip`.\n\n## Example\n\n```\nENTER THE LINK ADDRESS: https://example.com/largefile.zip\nENTER THE SIZE OF ZIP FILE: 104857600\n```\n\n## Thread Work Diagram\n\nBelow is a diagram showing the multithreaded download process:\n\n```\n+-----------------+\n|     Main Thread |\n+-----------------+\n        |\n        v\n+-----------------+                 +-----------------+\n|  Thread 1       |                 |  Thread 2       |\n|  Download Part  |                 |  Download Part  |\n|  (0 - N/4)      |                 |  (N/4 - N/2)    |\n+-----------------+                 +-----------------+\n        |                                |\n        v                                v\n+-----------------+                 +-----------------+\n|  Thread 3       |                 |  Thread 4       |\n|  Download Part  |                 |  Download Part  |\n|  (N/2 - 3N/4)   |                 |  (3N/4 - N)     |\n+-----------------+                 +-----------------+\n        |                                |\n        v                                v\n+-----------------------------+\n|       Merge Parts           |\n| (Combine all downloaded     |\n|  parts into final file)     |\n+-----------------------------+\n        |\n        v\n+-----------------------------+\n|     Download Completed      |\n+-----------------------------+\n```\n\nIn the diagram:\n- The **Main Thread** initializes and manages the downloading threads.\n- **Thread 1** through **Thread 4** each handle downloading a different part of the file.\n- After all threads complete, the **Merge Parts** step combines the individual parts into the final file.\n\n## Troubleshooting\n\n- **cURL Initialization Failure**: Ensure that cURL is correctly installed and linked. Check the installation and library paths.\n- **File Size Issues**: Make sure to input the correct file size. Incorrect sizes may lead to incomplete downloads or merging errors.\n\n## Tags\n\n- **C++**\n- **Multithreading**\n- **File Downloader**\n- **cURL**\n- **Concurrent Download**\n- **Threading**\n- **HTTP Requests**\n- **File Merging**\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkaleharshavardhan07%2Fmulti_thread_file_downloader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkaleharshavardhan07%2Fmulti_thread_file_downloader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkaleharshavardhan07%2Fmulti_thread_file_downloader/lists"}