Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
rq-scheduler
Advanced tools
npm install rq-scheduler
const TQueue = require('rq-scheduler')
const tQueue = new TQueue({prefix: 'TQ1', interval: 1000})
// connect to redis cluster
// if you have 3 redis, can set TQueue.connect([6379, 6380, 6381])
const tq = tQueue.connect([6379])
// tq.on('error', callback)
// tq.on('close', callback)
// create 'test' job queue in timed-queue instance
const testQueue = tQueue.tQueue('test')
// add 'job' listener
testQueue.on('job', function (jobObj) {
// ... just do some thing
// ACK the job
// jobObj : {
// queue: 'testetst',
// job: '121$6bcef79e64fd41db9c9972d923cd49c9',
// id: '121',
// timing: 1531914416025,
// active: 1531927285969,
// retryCount: 92 }
console.log('job id: ', jobObj.id)
testQueue.ackjob(jobObj.job)
})
// add job to queue
// promise
Promise.all([
testQueue.addjob('121', new Date().getTime() + 5000),
testQueue.addjob('121', new Date().getTime() + 10000)
])
// testQueue.show()
// or generator
require('co')(function * () {
yield [
testQueue.addjob('121', new Date().getTime() + 5000),
testQueue.addjob('121', new Date().getTime() + 10000)
]
})
// delete job
// return promise
testQueue.deljob('121')
Timed Queue
It is base on Timed Queue and support one job add multi-time
FAQs
Distributed timed job queue, backed by Redis.
The npm package rq-scheduler receives a total of 1 weekly downloads. As such, rq-scheduler popularity was classified as not popular.
We found that rq-scheduler 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.