drccrd commented on code in PR #4007:
URL:
https://github.com/apache/incubator-kie-tools/pull/4007#discussion_r4284588126
##########
packages/drools-lsp/drools-lsp-server/src/main/java/org/drools/lsp/server/DroolsLspServer.java:
##########
@@ -246,12 +251,33 @@ boolean isDependencyClasspathResolved() {
return dependencyClasspathResolved;
}
+ /**
+ * Registers the custom operators declared on the project's own build
output
+ * and on its dependencies, whenever either set may have changed. The
+ * dependency list from {@code mvn dependency:build-classpath} does not
carry
+ * the project's own {@code target/classes}, which is where its
+ * {@code META-INF/kie.properties.conf} lives, so both sets are scanned.
+ * Dependency jars change only when the classpath resolves, so their ids
are
+ * read there and only the class directories are rescanned here.
+ */
+ private void registerCustomOperators() {
+ Set<Path> scanned = filterDirectories(classpathEntries);
+ scanned.addAll(buildOutputDirs);
+ Set<String> operators = new TreeSet<>(jarCustomOperators);
+ operators.addAll(CustomOperators.register(scanned));
+ if (!operators.equals(registeredCustomOperators)) {
+ registeredCustomOperators = operators;
+ logger.info(() -> "Custom DRL operators: " + operators);
+ }
+ }
Review Comment:
😕 this is not true...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]