Giter Site home page Giter Site logo

rabbit.js within AngularJS about rabbit.js HOT 6 OPEN

rtubio avatar rtubio commented on August 27, 2024
rabbit.js within AngularJS

from rabbit.js.

Comments (6)

squaremo avatar squaremo commented on August 27, 2024

rabbit.js is fairly portable code in itself (although, inevitably, written in callback/promises style); however, since it relies on amqp.node (aka amqplib), I don't think it's usable outside a Node.JS environment.

from rabbit.js.

rtubio avatar rtubio commented on August 27, 2024

@squaremo : I know that I made you a question in the repository for AMQP that is pretty similar to this one, but I want to explore all the possibilities.

Is there any pure JS or AngularJS library for RabbitMQ?

from rabbit.js.

analytik avatar analytik commented on August 27, 2024

I don't think anyone really connects directly to RabbitMQ from a browser. What's your use case?

from rabbit.js.

rtubio avatar rtubio commented on August 27, 2024

@analytik : my use case is a system composed of 2 different types of clients:

  • Web application developed with Angular JS that, right now, is using pusher.com and JSON/RPC over HTTPS for the communications with a Django server.
  • Python client that connects to a Twisted server to exchange messages with low latency (real time).

I am trying to find an integrated communications system to use a single protocol for all the above mentioned 3 connections. RabbitMQ, together with Redis, Crossbar.io and gunicorn-websockets, match pretty well my requirements; however, each of them has a little drawback that I am trying to work around:

  1. RabbitMQ and Redis do not have an Angular/Javascript browser support, so I cannot directly communicate my first app (Angular JS based) with the server;
    1. crossbar.io and gunicorn-websocket: libraries available for JS and even Angular (WAMP);
  2. RabbitMQ and Redis directly integrate with Django through Celery (2/3 steps configuration process) that is really fast and efficient;
    1. crossbar.io and gunicorn-websocket: not a so-clear-integration process w/Django;
    2. there is a project/example to integrate crossbar.io w/Django through Celery, but it is not very mature yet;
  3. crossbar.io and gunicorn-websocket implement WAMP, which is the correct protocol for this application (offers RPC and PUB/SUB, both for clients ant the web);
    1. RabbitMQ offers STOMP, but you kind of have to run it as a slightly separate server on its own.

As you may have noticed, I am trying to find the most suitable option and that is why I am asking for clarifications on some of the issues above to understand correctly the actual limits of these options.

from rabbit.js.

analytik avatar analytik commented on August 27, 2024

www.rethinkdb.com

Although no single technology ever will be a silver bullet, I would say that RethinkDB has the potential to simplify your stack, although maybe not exactly as you imagine. It can replace Pusher.com with its realtime push, it's a full-featured database, and to some degree it can work as PUB/SUB, although it's not trying to compete with RabbitMQ.

In the next release (1-3 months) it will add support for direct connection from browsers, although I'm not sure if they plan any library-specific support on Day 1. However, hooking up RethinkDB -> Node.js + Socket.io -> Angular + Socket.io is very easy, and can be done in an hour or two.

If you're a fan of ORMs, you can use Angular + JS-Data-Angular -> Node.js + JS-Data-RethinkDB, although that doesn't have a direct support for websockets/push, but can get you up and running with basic filtering in place.

You could also try https://github.com/mikemintz/rethinkdb-websocket-client - but I have not tried that one.

(And sorry to squaremo if this feels disrespectful to have this discussion on a rabbit.js issue.)

from rabbit.js.

squaremo avatar squaremo commented on August 27, 2024

(And sorry to squaremo if this feels disrespectful to have this discussion on a rabbit.js issue.)

Yeah that is a bit cheeky, but since you had the grace to apologise, I'll allow it ;)

from rabbit.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.