Skip to content

Move postgres controller code to package, cleanup crds, fix minor issues#1791

Merged
mploski merged 3 commits intofeature/database-controllersfrom
feature/database-controllers-base-refactor
Mar 24, 2026
Merged

Move postgres controller code to package, cleanup crds, fix minor issues#1791
mploski merged 3 commits intofeature/database-controllersfrom
feature/database-controllers-base-refactor

Conversation

@mploski
Copy link
Collaborator

@mploski mploski commented Mar 23, 2026

Description

What does this PR have in it?

Key Changes

Highlight the updates in specific files

Testing and Verification

How did you test these changes? What automated tests are added?

Related Issues

Jira tickets, GitHub issues, Support tickets...

PR Checklist

  • Code changes adhere to the project's coding standards.
  • Relevant unit and integration tests are included.
  • Documentation has been updated accordingly.
  • All tests pass locally.
  • The PR description follows the project's guidelines.

@github-actions
Copy link
Contributor

CLA Assistant Lite bot:
Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contribution License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment with the exact sentence copied from below.


I have read the CLA Document and I hereby sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request

@mploski mploski force-pushed the feature/database-controllers-base-refactor branch from eca7bec to eff8782 Compare March 23, 2026 14:00
@mploski mploski force-pushed the feature/database-controllers-base-refactor branch from eff8782 to 05055ac Compare March 23, 2026 14:02
Copy link

@DmytroPI-dev DmytroPI-dev left a comment

Choose a reason for hiding this comment

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

We have pkg/postgresql/database/core/types.go and pkg/postgresql/cluster/core/types.go, both in core package, can we have some conflicts here?

@mploski
Copy link
Collaborator Author

mploski commented Mar 23, 2026

We have pkg/postgresql/database/core/types.go and pkg/postgresql/cluster/core/types.go, both in core package, can we have some conflicts here?

We might, in this case we can have separate "shared" directory with reusable types later on. Currently most of the things are not shared

CNPG *enterprisev4.CNPGConfig
}
const (
ClusterTotalWorker int = 2

Choose a reason for hiding this comment

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

Nit: Is that a requirement for SOK? I wasn't testing the code against two parallel goroutines running at the same time. Does it work such that one worker starts on an event, but if it's still processing and another event comes in, it doesn't just sit in the queue, it can be picked up by another worker? I’d like to trigger that for future local tests, that's why I’m asking.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

They just asked us to provide this info explicit. Yes your assumption is correct how it works, with one exception: if changes is related to the same CR it still will be queued to provide proper serialisation

@mploski mploski merged commit 5f6d971 into feature/database-controllers Mar 24, 2026
13 of 16 checks passed
@mploski mploski deleted the feature/database-controllers-base-refactor branch March 24, 2026 12:39
@github-actions github-actions bot locked and limited conversation to collaborators Mar 24, 2026
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.

3 participants