Frage

Here is some background on my problem - I am using NodeJS for it even-driven, Non-Blocking, Reactor Pattern advantage to handle HTTP(S) requests. Single node instance doesn't scale well when it has to do computation or time consuming task due to its single threaded nature. My NodeJS HTTP(S) handler publishes the data to Redis Server (LPUSH command).

Now I want to write a Redis Client which can consume the data (BRPOP command) from the Redis Server and then process (some sort of CPU intensive computation) it. I know Java so my preference to write this data processor piece is in Java. Just now I read this nice video about Vert.X here @ http://www.youtube.com/watch?v=8ClYUo_A3h0, which is better that NodeJS for handling the non blocking IO and CPU intensive operations as well.

I have to use Redis Client now as other components are using them in Production.

So now if I have to use java based solution for Redis Client will Vert.X fits here? If yes then is there any open source library available?

Thanks in advance.

War es hilfreich?

Lösung

A quick glance at Vert.X suggests its just running on the JVM, so you should be able to use any Java redis client. Seems like the most common option (which is open source) is Jedis. Also, Lettuce looks popular and has the advantage of offering a non-blocking interface to redis in cases where you don't need to wait for a response.

Also, thanks for the link to the video. Vert.x looks pretty awesome.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top