Skip to content
This repository was archived by the owner on Jan 7, 2026. It is now read-only.

add my blog#20

Open
duchh-manabie wants to merge 1 commit into
mainfrom
removing-dependency-between-microservices
Open

add my blog#20
duchh-manabie wants to merge 1 commit into
mainfrom
removing-dependency-between-microservices

Conversation

@duchh-manabie

Copy link
Copy Markdown
Contributor

No description provided.

slug = "removing-dependency-between-microservices"
+++

***In this blog post, I will show for you guys solution to solve the problem we have met when deploying in microservices***

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

show you guys


#### Problem

A little bit information about our system:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a little bit of

**Nats-jetstream**: We are using it for our message broker system. We also have a blog about
[it](https://blog.manabie.io/2022/03/set-up-nats-multi-tenant-in-golang/).

Currently, our system is in process migrate from monolithic to microservice. We deploy our all services by one helm chart, their

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in the process of doing sth

Currently, our system is in process migrate from monolithic to microservice. We deploy our all services by one helm chart, their
deploy process are parallel. In order to start a service, it requires some logics like: `connect DB success, connect Nats success,
register logic, upsert streams of nats-jetstream, create subscriber of nats-jetstream,...` if one of these things fail then the deploy
process fail too. So what is `upsert streams of nats-jetstream, create subscriber of nats-jetstream` means :thinking:?

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what does ... mean

register logic, upsert streams of nats-jetstream, create subscriber of nats-jetstream,...` if one of these things fail then the deploy
process fail too. So what is `upsert streams of nats-jetstream, create subscriber of nats-jetstream` means :thinking:?

1. **Upsert streams of nats-jetstream**: We write a library to check the `stream` by golang code. Is it exist? -> create a new one.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does it exist

process fail too. So what is `upsert streams of nats-jetstream, create subscriber of nats-jetstream` means :thinking:?

1. **Upsert streams of nats-jetstream**: We write a library to check the `stream` by golang code. Is it exist? -> create a new one.
Is it have any update? -> update it. Is it need to delete? -> delete it.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does it have, does it need

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant