Skip to main content



      Home
Home » Eclipse Projects » Dali » JPA facet and the utility facet as fixed vs required
JPA facet and the utility facet as fixed vs required [message #511100] Fri, 29 January 2010 15:13 Go to next message
Eclipse UserFriend
Hi, due in part to changes in Dali 2.3 in the jpa facet implementation changing the jst.utility facet as both fixed and required to just required only, we uncovered a problem (potentially in the facet framework) detailed in https://bugs.eclipse.org/bugs/show_bug.cgi?id=301027 . Basically we're seeing unwanted facets get selected when changing the runtime target in the JPA project wizard (the configuration goes to <custom>), and the workaround is to manually select the "Minimal JPA x.y configuration"

In order to help fix the problem, we'd like to understand the reasons behind this change from the previous Dali release where the utility facet was declared in the fixed list:

<template id="jpt.jpa.template">
<label>%JPA_TEMPLATE_LABEL</label>
<fixed facet="jst.java"/>
<fixed facet="jst.utility"/>
<fixed facet="jpt.jpa"/>
<preset id="jpt.jpa.preset"/>
</template>

On a side note, if it is part of the fixed list, or if it is removed from the required list (below), the problem doesn't occur.

<project-facet-version facet="jpt.jpa" version="1.0">
<constraint>
<and>
<requires facet="jst.java" version="[5.0"/>
<or>
<requires facet="jst.utility" version="[1.0"/>
<requires facet="jst.appclient" version="[1.2"/>
<requires facet="jst.ejb" version="[1.1"/>
<requires facet="jst.connector" version="[1.0"/>
<requires facet="jst.web" version="[2.2"/>
</or>
</and>
</constraint>
</project-facet-version>

Thanks,
Len.
Re: JPA facet and the utility facet as fixed vs required [message #511103 is a reply to message #511100] Fri, 29 January 2010 15:55 Go to previous messageGo to next message
Eclipse UserFriend
Hi Len,

We've had all kinds of problems "playing nicely" with the facets framework with regards to this.

We removed the utility facet from being fixed so that a user could instead change the facet to being a web or ejb, etc. facet when creating a JPA project. We still require *one of* ejb/dynamic web/utility/connector/app client facets, and removing this from the template allows the user to change it.

As I understand it, changing the runtime allows the runtime provider to dictate what facets are selected by default. I'm not sure I understand why exactly, but some were requesting the ability for the runtime to drive the facets selection more than we were allowing.

The only required bits while running this wizard are JPA (and therefore java), but the runtime and user determine the rest of it.

- Paul
Re: JPA facet and the utility facet as fixed vs required [message #511104 is a reply to message #511103] Fri, 29 January 2010 16:09 Go to previous messageGo to next message
Eclipse UserFriend
Is there any good reason to have one of utility, ejb, web, appclient . ?

As far as i know all the available facets would be displayed even if this condition is relaxed and a user can still install facet of his choice if he wished to do so.
Re: JPA facet and the utility facet as fixed vs required [message #511106 is a reply to message #511104] Fri, 29 January 2010 16:25 Go to previous message
Eclipse UserFriend
One of those facets is required for the JPA facet, period, but the user has multiple ways to fulfill the requirement within this dialog.

We need a "module" facet to enable runtime library usage, for determination of source file by deploy path location (flexible project structure), and other "EE" features. We are working on solutions that remove this requirement for SE use cases.

Please follow any changes to this status here: https://bugs.eclipse.org/bugs/show_bug.cgi?id=234383
Previous Topic:Restricting certain JPA facet versions for particular runtimes
Next Topic:Activate 'Java Persistence' and 'JPA Development' Perspective in Eclipse 3.3
Goto Forum:
  


Current Time: Mon Jul 07 10:17:21 EDT 2025

Powered by FUDForum. Page generated in 0.10895 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top