![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@coya/task-manager
Advanced tools
Scheduler for run tasks successively or simultaneously.
npm install @coya/task-manager
git clone https://github.com/Cooya/TaskManager
cd TaskManager
npm install // it will also install the development dependencies
npm run build
npm run example // run the example script in "examples" folder
const { TaskManager, Task } = require('@coya/task-manager');
const firstTask = new Task('firstTask', 10, function() { // processed every 10 seconds
console.log('hello');
return Promise.resolve();
});
const secondTask = new Task('secondTask', 5, function() { // processed every 5 seconds
console.log('hola');
return Promise.resolve();
});
const taskManager = new TaskManager();
taskManager.processAsynchronousTasks([firstTask, secondTask])
.then(function() {
taskManager.getLogs().info('Task manager stopped.');
}, function(error) {
taskManager.getLogs().error(error);
process.exit(1); // cancel all other scheduled tasks
});
Process tasks list successively, it means that tasks are executed one by one. The following task is executed once the previous one is done.
Parameter | Type | Description | Default value |
---|---|---|---|
taskList | array | list of objects implementing or inheriting the Task class | none |
Process tasks list simultaneously, it means that tasks are executed in the same time (using setTimeout()). It is different from setInterval() because the timer is launched after the task has been processed.
Parameter | Type | Description | Default value |
---|---|---|---|
taskList | array | list of objects implementing or inheriting the Task class | none |
The Task class, and so its constructor, contains three fields :
FAQs
Scheduler for run tasks successively or simultaneously
The npm package @coya/task-manager receives a total of 4 weekly downloads. As such, @coya/task-manager popularity was classified as not popular.
We found that @coya/task-manager 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.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.