Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add: local development setup instructions #29

Merged
merged 3 commits into from
Dec 12, 2024
Merged

Conversation

dennis-tra
Copy link
Contributor

@dennis-tra dennis-tra commented Dec 12, 2024

Adds setup instructions for local development. The issue here is that our production clickhouse database operates in "clustered" mode. This means we need to use the Replicated merge tree variants. You can see in the migration that we use the ENGINE = ReplicatedMergeTree. However, when running locally we cannot apply this migration because when we run a single Clickhouse instance we need to use the plaing MergeTree engine.

In this PR I just remove all occurences of the string Replicated with an empty string `` from the migrations and put the resulting files in a local subdirectory which is excluded from git. When running `local-migrate-up` go-migrate will look into this subdirectory and apply the migrations.

I haven't found anything only how people deal with that.

Copy link
Contributor

@guillaumemichel guillaumemichel left a comment

Choose a reason for hiding this comment

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

Tested and approved!

@guillaumemichel guillaumemichel merged commit 7ad4fe4 into dev Dec 12, 2024
1 check passed
@guillaumemichel guillaumemichel deleted the setup-docs branch December 12, 2024 10:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants