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

Remove kenai code from versioning and bugtracking modules #7198

Merged
merged 1 commit into from
Apr 1, 2024

Conversation

mbien
Copy link
Member

@mbien mbien commented Mar 27, 2024

Kenai was the successor of java.net and home for many java projects - but it is long gone now.

NB still has code which integrates kenai with various versioning and bugtracking IDE modules. This PR removes the code and the friend dependencies. The API stubs of versioning.util are kept for now.

@mbien mbien added Code cleanup subversion [ci] enable versioning job git [ci] enable versioning job tests mercurial [ci] aka hg; enable versioning job and removed tests labels Mar 27, 2024
@ebarboni
Copy link
Contributor

I guess, Kenai was unplugged in 2017 with no replacement.
Do we have a policy for effective removal ?

@mbien
Copy link
Member Author

mbien commented Mar 27, 2024

Do we have a policy for effective removal?

I am not aware of a policy. This does not touch public API as you can see since no sig tests failed. I am planning to keep the friend api like VCSKenaiAccessor in the repo, but deprecate it with forRemoval=true, so it can be removed once there is a public api removal policy.

@mbien mbien force-pushed the versioning-kenai-cleanup branch 2 times, most recently from f51d5dc to 0d9f149 Compare March 27, 2024 18:05
@mbien mbien marked this pull request as ready for review March 27, 2024 18:38
Copy link
Contributor

@lkishalmi lkishalmi left a comment

Choose a reason for hiding this comment

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

LGTM.

Copy link
Contributor

@matthiasblaesing matthiasblaesing left a comment

Choose a reason for hiding this comment

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

Wow this is a really ugly integration for a single hosting system. Only explanation can be, that the NetBeans sponsor and the hoster were the same.

General comment:

  • versioning.util exports friend-only to NetBeans modules, so I suggest not to deprecate, but directly kill (incrementing the module major version should be done then and that would be the point anybody should notice this)
  • for the other changes were deprecations were used instead of direct removals, I think none of the changes touched API (bugzilla and the versioning modules all have a package ...api which is the exported api), so I suggest the same there.

@@ -512,7 +508,7 @@ void reloadForm(boolean force) {
clearHighlights();

boolean isNew = issue.isNew();
boolean showProductCombo = isNew || !(issue.getRepository() instanceof KenaiRepository) || NBBugzillaUtils.isNbRepository(issue.getRepository().getUrl());
boolean showProductCombo = true;
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
boolean showProductCombo = true;
boolean showProductCombo = isNew || NBBugzillaUtils.isNbRepository(issue.getRepository().getUrl());

or kill NBBugzillaUtils and change to:

Suggested change
boolean showProductCombo = true;
boolean showProductCombo = isNew;

Copy link
Member Author

Choose a reason for hiding this comment

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

my thinking was that !(issue.getRepository() instanceof KenaiRepository) is essentially always evaluating to true now?

Copy link
Member Author

Choose a reason for hiding this comment

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

i checked and NBBugzillaUtils is probably something for another PR (if at all possible). Since it sits in team.commons which has a much bigger friends list.

Copy link
Member Author

@mbien mbien Mar 30, 2024

Choose a reason for hiding this comment

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

@matthiasblaesing the code either displays the product field as combo box or as text field if it is a kenai project.

new-bugzilla-issue

with kenai gone, I believe it is ok to always display it as combo box, no?

@mbien mbien changed the title Remove kenai code from versioning modules and deprecate friend API Remove kenai code from versioning and bugtracking modules Mar 29, 2024
@mbien
Copy link
Member Author

mbien commented Mar 30, 2024

pushed a commit

  • bumps spec version in ide/mercurial and ide/versioning.util
  • removes the deprecated stubs I left in the repo and also all other deprecated code of the versioning modules
  • this required regenerating the sig file of ide/mercurial

Copy link
Contributor

@matthiasblaesing matthiasblaesing left a comment

Choose a reason for hiding this comment

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

I would not have made api incompatible changes in mercurial, but given that the "API" is friend-only with a single user, I think this is ok. Thank you.

@mbien
Copy link
Member Author

mbien commented Mar 31, 2024

I would not have made api incompatible changes in mercurial, but given that the "API" is friend-only with a single user

I must have misunderstood your review comment then. What is the friend export you are worried about? There is still time to revert things.

@matthiasblaesing
Copy link
Contributor

I would not have made api incompatible changes in mercurial, but given that the "API" is friend-only with a single user

I must have misunderstood your review comment then. What is the friend export you are worried about? There is still time to revert things.

Sorry for the misunderstanding. My final comment was directed at the changes in ide/mercurial/src/org/netbeans/modules/mercurial/api/Mercurial.java. I don't remember, that they were in the original changeset (or I overlooked them). My first glance trigger my "API!!!"-reflex (from package name) and the second look then showed that the mercurial module has no public api.

It is done and cleanup, so I suggest to keep the change and merge as-is.

 - affected areas: git, svn, hg and issues/bugzilla
 - remove deprecated internal friend api code
 - bump major spec version of versioning.util and mercurial
@mbien mbien added this to the NB22 milestone Mar 31, 2024
@mbien mbien merged commit 905ff7e into apache:master Apr 1, 2024
34 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code cleanup git [ci] enable versioning job mercurial [ci] aka hg; enable versioning job subversion [ci] enable versioning job
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants