场景:
目前,我们在这种模式中采用了多层体系结构。
DBLayer => Tasks to DB
SouthBound => Talks to other devices like router/controller
SrvcLayer => Talks to both SouthBound and DBLayer
UILayer => Talks to UI and SrvcLayer该应用程序构建在Spring 4.2, Java 8, MongoDB上。
要求:
我们需要将SouthBound分离为一个单独的应用程序,或者可以说是微服务。
发行:
我们正在考虑两种方法
采用哪种方法比较合适。关于如何构建这个usecase.的任何其他建议
发布于 2018-11-09 07:21:33
在我们的应用程序中,我们有REST来通信UI <->后端部分,其后端部分是通过AMQP连接的。
顺便说一句,RabbitMQ似乎有异步的超短RabbitMQ asynchronous support,所以这可能就足够了。
RabbitMQ的同步工作仍然是可能的(Is it appropriate to use message queues for synchronous rpc calls via ajax,https://www.rabbitmq.com/tutorials/tutorial-six-java.html),但无论如何,如果您同步使用AMQP,这将以延迟结束,所以我认为最好使用REST
https://stackoverflow.com/questions/53221236
复制相似问题