Skip to content

feat: add pov of maintain scheama version in git #11232

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Sonichigo
Copy link
Member

Thanks for contributing to the Harness Developer Hub! Our code owners will review your submission.

Description

  • Please describe your changes:
    This pull request adds a new documentation page explaining best practices for maintaining database schema versions in a Git repository using Harness Database DevOps. The page covers version control benefits, workflows for initializing changelogs, committing changes, deploying via Harness pipelines, and recommended conventions for managing schema updates.
  • Jira/GitHub Issue numbers (if any):https://harness.atlassian.net/browse/DBOPS-434
  • Preview links/images (Internal contributors only): __________________

PR lifecycle

We aim to merge PRs within one week or less, but delays happen sometimes.

If your PR is open longer than two weeks without any human activity, please tag a code owner in a comment.

PRs must meet these requirements to be merged:

  • Successful preview build.
  • Code owner review.
  • No merge conflicts.
  • Release notes/new features docs: Feature/version released to at least one prod environment.

@Sonichigo Sonichigo self-assigned this Aug 12, 2025
@bot-gitexp-user
Copy link

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://689b44e9d8b1fe9d56e3d081--harness-developer.netlify.app

If you already have your changelog files:
- Organize them following your chosen Harness DB DevOps repository structure (for example, one root changelog.yml including multiple changeset files).
- Commit your current schema state to Git.
For example:
Copy link
Contributor

Choose a reason for hiding this comment

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

considering that the happy path, and most common config we've seen across out customers is just a single changelog file, I don't think this is a good example. If we want to document any structures more complex than that, we'd need to cover there usecases and why you might want to structure things that way... which I don't think this doc is trying to do. (to fix just remove the example).

Harness executes your .yml changelogs in sequence during pipeline runs, ensuring every environment stays consistent. The pipeline automatically checks your Git repository for unapplied changesets and executes only the new ones, maintaining idempotency.
How it works:

- **Contexts**: Instead of maintaining separate changelog files for each environment, you can annotate changesets with contexts (e.g., dev, staging, prod).
Copy link
Contributor

Choose a reason for hiding this comment

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

context support syntax specifying lists of contexts, and nots (basically full boolean logic). it might be worth having a doc on how to do that, and linking to it here.

Signed-off-by: Animesh Pathak <[email protected]>
@bot-gitexp-user
Copy link

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://68a593288145e6f6047bab17--harness-developer.netlify.app

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.

3 participants