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

kie-issues#114: JavaCodeCompletion module fails to compile because of API change #2453

Merged
merged 25 commits into from
Jul 1, 2024

Conversation

yesamer
Copy link
Contributor

@yesamer yesamer commented Jun 27, 2024

Finally closes apache/incubator-kie-issues#114

One year ago the JDT.LS API suddenly changed breaking the Java class "Fetching" mechanism we had in place.
We that change, it was no longer possible to retrieve a class FQCN, which is a required property for the "Fetching" mechanism to properly work.
In the latest release, the API now supports the TypeHierarchy command: given a class name, that command can retrieve the class hierarchy and the first items represent the class itself in FQCN format.
To restore the "Fetching" feature, we can then rely on this new command.

For example, if we use that command on a String type variable, this will return:
Screenshot 2024-06-12 at 10 46 23
The first item contains exactly what we need.

Screen.Recording.2024-06-12.at.10.37.29.mov

yesamer added 23 commits May 23, 2023 10:21
# Conflicts:
#	packages/vscode-java-code-completion-extension-plugin/vscode-java-code-completion-extension-plugin-core/src/main/java/org/kogito/core/internal/handlers/GetAccessorsHandler.java
#	pnpm-lock.yaml
# Conflicts:
#	packages/vscode-java-code-completion-extension-plugin/vscode-java-code-completion-extension-plugin-core/src/main/java/org/kogito/core/internal/handlers/GetAccessorsHandler.java
# Conflicts:
#	packages/vscode-java-code-completion-extension-plugin/vscode-java-code-completion-extension-plugin-core/src/main/java/org/kogito/core/internal/handlers/GetAccessorsHandler.java
…14-latest

# Conflicts:
#	packages/import-java-classes-component/tests/ImportJavaClasses/ImportJavaClasses.test.tsx
@yesamer yesamer requested a review from tiagobento as a code owner June 27, 2024 09:00
@yesamer yesamer requested a review from jomarko June 27, 2024 09:01
@@ -1,7 +1,7 @@
package com.redhat;
package org.kie;
Copy link
Contributor

Choose a reason for hiding this comment

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

I guess org.apache.kie would be more future-proof...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated @tiagobento

@tiagobento
Copy link
Contributor

Thanks @yesamer! It's been a long long journey. I respect the patience and the resilience!!! 💪

@tiagobento tiagobento added area:dmn lang:java Pull requests that update Java code labels Jun 27, 2024
Copy link
Contributor

@jomarko jomarko left a comment

Choose a reason for hiding this comment

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

@yesamer thank you for the PR. I did not find an issue during my manual check.

@yesamer yesamer merged commit 5372b59 into apache:main Jul 1, 2024
14 checks passed
@yesamer yesamer deleted the kie-issues#114-latest branch July 1, 2024 11:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:dmn lang:java Pull requests that update Java code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

JavaCodeCompletion module fails to compile because of API change
3 participants