| Summary: | JPA facet needs runtime changed listener/handler | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [WebTools] Dali JPA Tools | Reporter: | Leonard Theivendra <theivend> | ||||||||
| Component: | General | Assignee: | Paul Fullbright <paul.fullbright> | ||||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||||
| Severity: | normal | ||||||||||
| Priority: | P3 | CC: | gindik, jpitman, karenfbutzke, konstantin, neil.hauge, paul.fullbright | ||||||||
| Version: | unspecified | Flags: | neil.hauge:
review+
|
||||||||
| Target Milestone: | 2.3.1 | ||||||||||
| Hardware: | PC | ||||||||||
| OS: | Windows XP | ||||||||||
| Whiteboard: | |||||||||||
| Attachments: |
|
||||||||||
|
Description
Leonard Theivendra
Created attachment 172348 [details]
Patch to add a runtime changed listener to the JPA facet
Konstantin, does this patch look right, or is this something that should be handled within the library provider framework? Or are we not utilizing the library provider framework correctly within this context? The facet should call into the library provider framework upon runtime change as the available libraries could be different in the new context, but the attached patch isn't the right way to do this. The attached patch is correct for facets that use the basic ClasspathHelper API (like the module facets), but for facets that use the library provider framework, the body of the listener needs to be different. It should look more like the version change action. You will need to create LibraryInstallDelegate and run it to let it do it's thing. Created attachment 172687 [details]
patch
Unfortunately, I don't really have any runtime definitions that provide libraries for JPA, so I can't test this patch out. I don't have a way to set up a runtime library provider.
Konstantin, is this pretty much what you're talking about?
Len, does this solve your problem?
That looks about right. Leonard, can you verify that the patch addresses your problem? I'd like to have something released soon. (In reply to comment #6) > Leonard, can you verify that the patch addresses your problem? I'd like to > have something released soon. Hi Paul, I just tried the patch and it doesn't seem to work. In debugging, it does get into your new listener, but the following call returns null for the working copy so nothing is done: IFacetedProjectWorkingCopy fpwc = facetedProjectEvent.getWorkingCopy(); Created attachment 172915 [details]
updated patch
Ah, hadn't tested the situation where the faceted project wasn't actually being changed.
Can you try the updated patch?
(In reply to comment #8) > Created an attachment (id=172915) [details] > updated patch > Ah, hadn't tested the situation where the faceted project wasn't actually being > changed. > Can you try the updated patch? OK that seems to work just fine. Thanks. Committed to head. Please reopen if there are further issues. |