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

fix(maven): Reject releases only for Maven Central repository #32287

Conversation

zharinov
Copy link
Collaborator

@zharinov zharinov commented Nov 1, 2024

Changes

Context

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@rarkins
Copy link
Collaborator

rarkins commented Nov 1, 2024

I'm it sure this is what we want. It's private registries which have the release problems

@zharinov
Copy link
Collaborator Author

zharinov commented Nov 1, 2024

Another suggestion is to exclude jetbrains repo, as it doesn't seem to follow the structure we expect anyways (e.g. at the earlier stage we fail to fetch metadata xml for the latest release).

@rarkins
Copy link
Collaborator

rarkins commented Nov 2, 2024

Does that mean that that repo didn't used to work at all when we used to eagerly check releases?

@zharinov
Copy link
Collaborator Author

zharinov commented Nov 2, 2024

Yes, I think it never worked to the full extent, though HTML page is good enough to extract the list of versions (i.e. without metadata)

@rarkins
Copy link
Collaborator

rarkins commented Nov 2, 2024

Might be better to make this logic configurable?

  • never check (no timestamps possible)
  • optional (use data if available)
  • strict (enforce/filter)

@zharinov
Copy link
Collaborator Author

zharinov commented Nov 2, 2024

Isn't it overcomplication, though? Originally we only wanted to skip releases which were found in metadata.xml but don't have corresponding pom file, which breaks maven build. I'm not sure it makes sense outside of Maven Central.

@zharinov
Copy link
Collaborator Author

zharinov commented Nov 2, 2024

After all, reject is the strong tool, so we should limit its usage. I actually surprised why I didn't limited it to the Maven Central for the initial implementation.

@rarkins
Copy link
Collaborator

rarkins commented Nov 2, 2024

I'm pretty sure the problem which Pom checking solves was primarily in in maven central

@rarkins
Copy link
Collaborator

rarkins commented Nov 2, 2024

Wasn't the bug about extractVersion and not custom registries?

@zharinov
Copy link
Collaborator Author

zharinov commented Nov 2, 2024

I think extractVersion isn't relevant

@zharinov zharinov changed the title fix(maven): Reject releases only for default registries fix(maven): Reject releases only for Maven Central repository Nov 2, 2024
@zharinov zharinov requested a review from rarkins November 2, 2024 13:40
Copy link
Collaborator

@rarkins rarkins left a comment

Choose a reason for hiding this comment

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

This is not what we want. This feature was designed for private registries, not maven central

@zharinov zharinov closed this Nov 6, 2024
@zharinov zharinov deleted the fix/maven-reject-default-registries-only branch November 6, 2024 19:25
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 7, 2024
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.

extractVersion with postProcessRelease (maven) causes rejected release
2 participants