Giter Site home page Giter Site logo

Service discovery in Redis? about cote HOT 11 CLOSED

dashersw avatar dashersw commented on August 25, 2024 2
Service discovery in Redis?

from cote.

Comments (11)

dashersw avatar dashersw commented on August 25, 2024 1

@ksmithut just a small correction: using Kubernetes, Docker Cloud, Docker Swarm or any other orchestration tool with overlay networks lets you attach any cloud provider. Effectively, you don't need bare metal; but if you want to use cloud servers you should use an orchestration tool. I am fond of Docker Cloud and am personally running production services with it. Previously I was using DigitalOcean as the provider and then I've switched an entire cluster of servers (10 servers in total) over to AWS in about 10 minutes, with 0 downtime.

from cote.

dashersw avatar dashersw commented on August 25, 2024

A reader on Medium had suggested adapters for etcd or redis for service discovery. Implementing this is actually somewhat straightforward but as you pointed out would make it a hard dependency — users could think it would be the best way to use cote.

The problem is, a redis instance is not a simple thing. One needs to scale it as well; at least have a modest cluster. Then the redis has to be scaled to other geographical regions and then locally configured, which add a huge level of complexity that doesn't need to exist.

And about Docker; it's the evolution of application deployments. It's not impossible but difficult nowadays to deploy a scalable microservices app without the help of K8S, Docker Cloud and other tools. Orchestration tools enable the cattle vs pet approach and overlay networks, which fits very well with microservices deployments. So if the best way to deploy your app is through Docker, one should adopt it. Out of the box, comes support for cote.

Having said that, I can't ignore the fact that instinctively a centralized discovery solution feels like a better solution, and I would support it if someone took on the challenge of building it and making it work with cote. We might find a way to augment cote with plugin support for other discovery adapters without damaging its zero-dependency nature.

from cote.

ksmithut avatar ksmithut commented on August 25, 2024

This looks like an awesome library and would love to use it in our production environment, but we're using AWS with elasticbeanstalk for our apps. Since multicast is not supported, we would have to leverage a docker overlay network, which is only supported using ECS as far as I understand, which would mean everyone would be running on one or two instances, which kind of defeats of purpose for high availability. Having an adapter for service discovery is essential if you want to deploy this using something besides bare metal. Configuring each node to point to a redis cluster is still better than not using cote (or something like it).

That being said, I have some Raspberry Pi projects that I'm totally going to play around with this summer using cote. So excited!

from cote.

nrccua-AnthonyS avatar nrccua-AnthonyS commented on August 25, 2024

You could deploy to Elastic Beanstalk with Docker.

from cote.

ksmithut avatar ksmithut commented on August 25, 2024

@nrccua-AnthonyS If you have multiple elasticbeanstalk apps using docker, do they use the same overlay network?

from cote.

anthonyshull avatar anthonyshull commented on August 25, 2024

I believe you can set that up. I'm looking to use Digital Ocean and they seem to support it: https://www.digitalocean.com/community/tutorials/how-to-create-a-cluster-of-docker-containers-with-docker-swarm-and-digitalocean-on-ubuntu-16-04

from cote.

ksmithut avatar ksmithut commented on August 25, 2024

That would be nice. We ruled out using Docker Cloud for other reasons (policy compliance and other things), but it would be interesting to use Kubernetes or Swarm. Unfortunately, we're probably not going to spend the enormous amount of money to change our infrastructure to support this one module, no matter how awesome it is (and it is awesome!). Anyway, just my two cents. Keep up the good work!

from cote.

thelinuxlich avatar thelinuxlich commented on August 25, 2024

Since cote.js only supports Docker Cloud(docker doesn't have multicast), this really becomes an issue

from cote.

dashersw avatar dashersw commented on August 25, 2024

@ksmithut did you check out Weave? It has support for multicast / broadcast for Docker Swarm and Kubernetes.

from cote.

dashersw avatar dashersw commented on August 25, 2024

I have added a redis backend plugin for service discovery. Please check out the readme.

from cote.

thelinuxlich avatar thelinuxlich commented on August 25, 2024

I advise you to use ioredis internally instead of node_redis because it supports redis cluster and also spreads the reads between slaves.

from cote.

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.