【问题标题】:Boilerplate for independently deployable microservices based on Serverless framework基于 Serverless 框架的可独立部署微服务的样板
【发布时间】:2021-03-15 01:50:52
【问题描述】:

遵循微服务的原则,

Defined domain: Each microservice has a defined domain of responsibility (sometimes referred to as a bounded context). The microservice manages this domain itself, without concerning itself about other domains.

Self-contained: Each microservice is a self-contained unit. It may contain multiple components that all work together.

Independently deployable: Each microservice can be built and deployed as an independent entity. Deploying one microservice does not affect another microservice.

Manages data stores: The data store or stores used by each microservice should be contained within the microservice boundary, thereby ensuring that there are no hidden dependencies caused by data stores being shared.

Loosely coupled: Microservices should be loosely coupled, and ideally communication will occur asynchronously using event sourcing or queues.

Highly automated: The build, deployment, and ongoing management of microservices should emphasize automation wherever possible.

我正在寻找实现这些原则的代码结构/样板的建议,尤其是 - 可独立部署、松散耦合和包含数据存储。在 AWS 上使用无服务器框架。如果能够参考运行良好的样板并实现这些原则,这样部署顺序就无关紧要了,那就太好了。

我遇到了https://github.com/trilom/sls-microservice,但它有生成文件。不喜欢不得不使用它们的想法。

【问题讨论】:

  • 我记得检查过这个:github.com/brietsparks/guestbook 也许会以某种方式帮助你。
  • 感谢分享。它虽然没有使用无服务器框架。 @Marcin我特别想了解应该在哪里定义资源/数据库/队列,以便部署顺序无关紧要。

标签: amazon-web-services microservices serverless-framework serverless boilerplate


【解决方案1】:

我发现这正是正确的目的: https://github.com/zotoio/generator-mono-serverless

【讨论】:

    猜你喜欢
    • 2015-09-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-02-16
    • 1970-01-01
    • 2017-06-12
    • 1970-01-01
    • 2021-09-04
    相关资源
    最近更新 更多