Bug 1092860
| Summary: | KieModuleMetaDataImpl's initialization and Builder's verifyExternalClass doesn't accord with Maven's default behavior | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Retired] JBoss BPMS Platform 6 | Reporter: | kylin <ksoong> | ||||
| Component: | Business Central | Assignee: | Mario Fusco <mfusco> | ||||
| Status: | CLOSED WONTFIX | QA Contact: | Marek Baluch <mbaluch> | ||||
| Severity: | high | Docs Contact: | |||||
| Priority: | high | ||||||
| Version: | 6.0.1 | CC: | kverlaen, mwinkler, tkobayas | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | All | ||||||
| OS: | All | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2014-05-06 12:11:02 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
Created attachment 891025 [details]
reproduce
How to Reproduce ================ 1. start BPMS 6 with remote debug enable 2. download reproduce.zip, login to business-central, select Authoring -> Artifact repository ->Upload, upload attached checkservice-1.0.jar 3. create a new project, add checkservice-1.0.jar as dependency 4. Build & Deploy the new created project. Build & Deploy, 5. add breakpoint at org.kie.scanner.KieModuleMetaDataImpl's init() method, you will find all packeges and class under package be picked up add saved. 6. add reakpoint at org.guvnor.common.services.builder.Builder's verifyExternalClass() method, you will find verified failed due to Maven doesn't load implicit class to class path cause no class found error Created attachment 891062 [details]
error log
I need add 2 supplements * from business-central, execute Build & Deploy, the "Build Successful" prompt, but no deployments in Deploy -> Deployments, so build failed * Build failed with lots of WARN output as attached server.log, https://bugzilla.redhat.com/show_bug.cgi?id=1092839 has recorded this. *** Bug 1094295 has been marked as a duplicate of this bug. *** That verifyExternalClass() method is necessary and it has been added to solve the other issue reported here: https://bugzilla.redhat.com/show_bug.cgi?id=1007055 |
Description of problem: org.kie.scanner.KieModuleMetaDataImpl's init() method add all dependencies' package to a package set Set<String> packages = new HashSet<String>(); and add all classes to class map Map<String, Collection<String>> classes = new HashMap<String, Collection<String>>(); Then in org.guvnor.common.services.builder.Builder's verifyExternalClass() method verified class like ~~~ clazz.getDeclaredConstructors(); clazz.getDeclaredFields(); clazz.getDeclaredMethods(); clazz.getDeclaredClasses(); clazz.getDeclaredAnnotations(); ~~~ This may cause class not found error, because Maven's default behavior didn't load the filed class referred jars to class path, this cause Build & Deploy failed. I will add reproduce project shortly