Skip to content

Conversation

@marcleblanc2
Copy link
Contributor

Expanded the filtering mechanism beyond commenting on extensions, to address new features in Postgres v17 which are not available in our SG Cloud pg v16 databases, as well as SQL queries / commands which break Google Cloud SQL's very fragile import.

Also renamed "primary.sql" to "pgsql.sql" to be consistent, as this is the only place across our entire codebase that this database got yet-another-name.

Test plan

Tested on customer Cloud migration

Updated unit tests

Updated process docs for IE team performing these migrations

@marcleblanc2 marcleblanc2 enabled auto-merge (squash) November 1, 2025 16:37
@marcleblanc2 marcleblanc2 changed the title Fix src snapshot upload filter for incompatible SQL statements Chore: Fix snapshot upload filter for incompatible SQL statements Nov 1, 2025
Predefined targets are available based on default Sourcegraph configurations ('docker', 'k8s').
Custom targets configuration can be provided in YAML format with '--targets=target.yaml', e.g.
primary:
Copy link
Member

@bobheadxi bobheadxi Nov 1, 2025

Choose a reason for hiding this comment

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

I don't think we should rename this in this change, as it's unrelated to the main thing being fixed, and is also a configuration change

I also don't think this is correct? If anything it should be called frontend https://sourcegraph.sourcegraph.com/github.com/sourcegraph/sourcegraph/-/blob/migrations/README.md but either way, I dont think we should change that here

Copy link
Member

Choose a reason for hiding this comment

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

Hmm, I suppose we call the container pgsql in some places... I'm not sure that's what we want to align on though, and either way, separate change 🙏

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Noted, have removed it from this PR, will submit it in a new PR. From the self-hosted customer's perspective, this database is known as the pgsql database, as it's the container / pod they deal with.

@bobheadxi
Copy link
Member

Thanks! but let's keep PRs one-fix-at-a-time, and also I'm not sure pgsql is the right name for this

Copy link
Member

@bobheadxi bobheadxi left a comment

Choose a reason for hiding this comment

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

thank you!

@marcleblanc2 marcleblanc2 merged commit c15e396 into main Nov 3, 2025
10 checks passed
@marcleblanc2 marcleblanc2 deleted the marc-fix-src-snapshot-upload-for-postgres-17 branch November 3, 2025 02:54
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