
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
node-mutil-downloader
Advanced tools
a new method download http data in multiple, resume, retry.
download-task-list
[{downloadTask},{downloadTask},{downloadTask}]
shell
npm i --save node-multi-resume-retry-downloader
npm i -d
js
const DownloadTask = require('node-mutil-downloader').DownloadTask;
const DownloadTaskList = require('node-mutil-downloader').DownloadTaskList;
OR SEE test
const downloadTaskList = new DownloadTaskList();
downloadTask = new DownloadTask({
downloadUrl,
savePath
});
downloadTaskList.register(downloadTask);
downloadTaskList.startDownloadTask(downloadTask, index, progressCatch(dispatch, getState), downloadResultHandler(dispatch, getState));
reducers
function downloadTaskList(state = {
list: new DownloadTaskList(),
trigger: 'init'
}, action = {}) {
switch (action.type) {
case types.UPDATE_LIST:
return {
list: action.list,
time: action.time
};
case types.CLEAR_LIST:
return {
list: action.list,
time: action.time
};
case types.REMOVE_DOWNLOAD:
return {
list: action.list,
time: action.time
};
case types.DOWNLOAD_PROGRESS:
return {
trigger: action.trigger,// progress || finish
list: action.list,
time: action.time
};
default:
return state
}
}
handlers:
function progressCatch(dispatch) {
const getState = [].slice.call(arguments, 1)[0];
return function () {
const downloadTaskList = getState().downloadTaskList.list;
return dispatch(downloadProgressUpdate(downloadTaskList, "progress"));
}
}
function processMapFileAction(file,directory) {
return async (dispatch, getState) => {
const mapInfo = await mapUtils.analysisMapTarGz(file,directory);
mapInfo.time = new Date().valueOf();
await mapUtils.saveMapMetaToDB(mapInfo);
return dispatch(choseMap(mapInfo));
}
}
caller:
const downloadTaskList = getState().downloadTaskList.list;
const downloadTask = new DownloadTask({
type,
downloadUrl,
savePath,
saveName
});
downloadTaskList.register(downloadTask);
downloadTask.start(progressCatch(dispatch, getState), downloadResultHandler(dispatch, getState));
FAQs
node-mutil-downloader base from node-fetch-retry
We found that node-mutil-downloader demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.