
Research
Security News
Malicious npm Packages Target BSC and Ethereum to Drain Crypto Wallets
Socket uncovered four malicious npm packages that exfiltrate up to 85% of a victim’s Ethereum or BSC wallet using obfuscated JavaScript.
bokeh (pronounced boh-kay) is a simple, scalable and blazing-fast task queue built on Node.js and ZeroMQ. It allows you to offload tasks from your main application process and distribute them among a pool of workers. Workers can be running on the same host as your application, or scaled out onto multiple machines for greater processing power.
When you want a worker to run a task, just submit it to the broker using the client API. A task is simply any class in your application which responds to the run
method.
Bokeh consists of three components:
The only prerequisite is that you have ZeroMQ installed.
OS X
Install ZeroMQ using brew:
$ brew install zeromq
Ubuntu 10.04 LTS
Install ZeroMQ using Chris Lea's PPA:
$ sudo add-apt-repository ppa:chris-lea/zeromq
$ sudo apt-get update
$ sudo apt-get install libzmq-dbg libzmq-dev libzmq1
Install Bokeh using npm:
$ npm install bokeh
A task is a class which responds to the run
method. A task is dealt to a worker and executed.
Once the task has been completed, you must call the callback with any data you want to pass back to your application.
class Reverse
run: (data, callback) -> callback null, data.split("").reverse().join("")
The client is used by your application to submit tasks to the broker and monitor their progress.
bokeh = require "bokeh"
handle = bokeh.getClient().submitTask "Reverse", "hello world"
handle.on "complete", (data) -> console.log "Task %s completed: %s", handle.id, data
handle.on "error", (error) -> console.error "Task %s failed: %s", handle.id, error
The broker is responsible for routing messages from clients, persisting them to the data store and dealing them to workers.
bokeh = require "bokeh"
broker = new bokeh.Broker
Bokeh supports pluggable data stores for persisting tasks, currently in-memory, Redis and Riak are supported.
A worker is a process which receives tasks from a broker and executes them. You must register all your task classes with the worker.
bokeh = require "bokeh"
worker = new bokeh.Worker
worker.registerTask "Reverse", require("./tasks/reverse")
Bokeh is released under the MIT license.
1.0.3 (2019-02-19)
FAQs
A blazing-fast task queue built on Node.js and ZeroMQ.
The npm package bokeh receives a total of 7 weekly downloads. As such, bokeh popularity was classified as not popular.
We found that bokeh 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
Socket uncovered four malicious npm packages that exfiltrate up to 85% of a victim’s Ethereum or BSC wallet using obfuscated JavaScript.
Security News
TC39 advances 9 JavaScript proposals, including Array.fromAsync, Error.isError, and Explicit Resource Management, which are now headed into the ECMAScript spec.
Security News
Vite releases Rolldown-Vite, a Rust-based bundler preview offering faster builds and lower memory usage as a drop-in replacement for Vite.