Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    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 #618707] Fri, 29 January 2010 20:13 Go to next message
Leonard Theivendra is currently offline Leonard TheivendraFriend
Messages: 36
Registered: July 2009
Member
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 #618708 is a reply to message #618707] Fri, 29 January 2010 20:55 Go to previous messageGo to next message
Paul Fullbright is currently offline Paul FullbrightFriend
Messages: 201
Registered: July 2009
Senior Member
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 #618709 is a reply to message #618708] Fri, 29 January 2010 21:09 Go to previous messageGo to next message
Neeraj Agrawal is currently offline Neeraj AgrawalFriend
Messages: 22
Registered: July 2009
Junior Member
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 #618710 is a reply to message #618709] Fri, 29 January 2010 21:25 Go to previous message
Paul Fullbright is currently offline Paul FullbrightFriend
Messages: 201
Registered: July 2009
Senior Member
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:Re: 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: Thu Apr 25 07:36:12 GMT 2024

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

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

Back to the top