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

CRD generator holds onto outdated class information #3442

Closed
metacosm opened this issue Sep 2, 2021 · 0 comments · Fixed by #3443
Closed

CRD generator holds onto outdated class information #3442

metacosm opened this issue Sep 2, 2021 · 0 comments · Fixed by #3443
Assignees
Milestone

Comments

@metacosm
Copy link
Collaborator

metacosm commented Sep 2, 2021

If some classes are reloaded and CRD generation is requested again, it's possible that the associated information held in the DefinitionRepository will be outdated thus leading in improper CRD generation. The solution is to be able to request the DefinitionRepository to clear its held data when needed from the CRDGenerator. Note that this also requires a fix in sundrio since right now, the DefinitionRepository.clear method only clears existing definitions, not TypeDef suppliers which might be used to regenerate some of the definitions. However, since these suppliers also reference older versions of the classes, it's therefore not enough to just clear the definitions. As a result, fixing this issue will need #3438 to be merged first (or, alternatively, sundrio 0.40.2 with a backported fix to be released).

@metacosm metacosm added this to the 5.8.0 milestone Sep 2, 2021
@metacosm metacosm self-assigned this Sep 2, 2021
metacosm added a commit that referenced this issue Sep 3, 2021
This is needed when classes might have been reloaded since the last
generation round. If we were to hold onto already generated TypeDefs,
we would get an outdated CRD. While this isn't a typical scenario, this
situation occurs during Quarkus live reload.

Fixes #3442
metacosm added a commit that referenced this issue Sep 3, 2021
This is needed when classes might have been reloaded since the last
generation round. If we were to hold onto already generated TypeDefs,
we would get an outdated CRD. While this isn't a typical scenario, this
situation occurs during Quarkus live reload.

Fixes #3442
metacosm added a commit that referenced this issue Sep 7, 2021
This is needed when classes might have been reloaded since the last
generation round. If we were to hold onto already generated TypeDefs,
we would get an outdated CRD. While this isn't a typical scenario, this
situation occurs during Quarkus live reload.

Fixes #3442
manusa pushed a commit that referenced this issue Sep 8, 2021
This is needed when classes might have been reloaded since the last
generation round. If we were to hold onto already generated TypeDefs,
we would get an outdated CRD. While this isn't a typical scenario, this
situation occurs during Quarkus live reload.

Fixes #3442
@manusa manusa modified the milestones: 5.8.0, 5.7.3 Sep 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants