nameko

Nameko - invoking RPC method from another service

懵懂的女人 提交于 2020-01-06 06:51:27
问题 I am trying to understand how nameko works for basic RPC. I am looking to define microservices in separate files and being able to run them from command shell. With this structure service2 is not being able to invoke service1's RPC method. What is missing to get this working? I have the following file structure: -rwxrwxr-x 1 user user 240 Dec 15 01:49 nameko.sh* -rw-rw-r-- 1 user user 251 Dec 15 01:46 service1.py -rw-rw-r-- 1 user user 305 Dec 15 01:47 service2.py Content of files are: $ cat

Connecting to rabbitmq docker container from service in another container

▼魔方 西西 提交于 2019-12-07 09:18:07
问题 I've done a lot of searching but I cannot fix this issue. I have a basic Rabbitmq container running via this command: docker run -d --hostname rabbitmqhost --name rabbitmq -p 15672:15672 -p 5672:5672 rabbitmq:3-management I am using nameko to create a microservice which connects to this container. Here's a basic microservice module main.py : from nameko.rpc import rpc class Service_Name(object): name = "service_name" @rpc def service_endpoint(self, arg=None): logging.info('service_one

Connecting to rabbitmq docker container from service in another container

前提是你 提交于 2019-12-05 17:19:25
I've done a lot of searching but I cannot fix this issue. I have a basic Rabbitmq container running via this command: docker run -d --hostname rabbitmqhost --name rabbitmq -p 15672:15672 -p 5672:5672 rabbitmq:3-management I am using nameko to create a microservice which connects to this container. Here's a basic microservice module main.py : from nameko.rpc import rpc class Service_Name(object): name = "service_name" @rpc def service_endpoint(self, arg=None): logging.info('service_one endpoint, arg = %s', arg) This service runs and connects to the rabbitmq from my host machine with the command