Hi Lenny & Tapestry Users,

Yep I tried exclude in the template.  No such luck.  The thing errors out in 
setupRender - I might do the fetching of the List<CalledEvent> in onActivate 
(even though it's in the wrong place to put such stuff).

I tried a few things, like the other suggestion to use @Inject BeanModelSource 
and also what is on the jumpstart page using

myModel = beanModelSource.createDisplayModel(CalledEvent.class, 
componentResources.getMessages()).exclude("_persistence_shouldRefreshFetchGroup");

But it still didn't work.   Not exactly sure where the problem is, in 
EclipseLink or somewhere in Tapestry's use of BeanModel -  I'll just use a Loop 
for now whilst I'm still deving.

When I find some time next week I'll create a simple 
tapestry-jpa/tapestry-hibernate to see if that will work on Glassfish with the 
Grid component.

Otherwise, I might go back to testing on JBoss so I can use Grid.  It'll be a 
toss up whether the gains in getting easy webservices RS/SOAP on glassfish is 
worth not having use of BeanModel stuff.

This is my persistence.xml in case you can see something I'm missing to make it 
work.

<?xml version="1.0" encoding="UTF-8"?>

<persistence xmlns="http://java.sun.com/xml/ns/persistence";
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
        xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
   http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd";
        version="1.0">

        <persistence-unit name="CTIServerEM" transaction-type="JTA">
                
<provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
                <jta-data-source>jdbc/fullcti1DS</jta-data-source>
                
<class>org.opencsta.ctiserver.business.callservices.model.BasicEvent</class>
                
<class>org.opencsta.ctiserver.business.callevents.model.CalledEvent</class>
                <properties>
                        <!-- <property name="eclipselink.ddl-generation" 
value="drop-and-create-tables" 
                                /> -->
                        <property name="eclipselink.ddl-generation" 
value="create-tables" />
                        <property name="eclipselink.logging.level" value="INFO" 
/>
                </properties>
        </persistence-unit>
        <persistence-unit name="ReadOnlyAlerteeEM"
                transaction-type="JTA">
                
<provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
                <jta-data-source>jdbc/d6alerteetestDS</jta-data-source>
                <class>com.alertee.contacts.model.CustomAlerteeContacts</class>
                <class>com.alertee.contacts.model.CustomAlerteeNumbers</class>
                <properties>
                        <property name="eclipselink.ddl-generation" 
value="none" />
                        <property name="eclipselink.logging.level" value="INFO" 
/>
                        <property name="eclipselink.read-only" value="true" />
                </properties>
        </persistence-unit>
</persistence>


Thanks for your suggestions!

Chris

On 22/09/2011, at 1:24 AM, Lenny Primak wrote:

> Have you tried exclude= in your template?  That worked for me and is simple. 
> 
> 
> 
> On Sep 21, 2011, at 11:18 AM, Chris Mylonas <ch...@opencsta.org> wrote:
> 
>> Hi!!
>> 
>> It is EclipseLink (glassfish 3.1.1), I've just tried the first time now and 
>> it failed again (same reason) but I'll try a few other things based on 
>> Thiago's response earlier (re: BeanModel).
>> 
>> Here is CalledEvent which the error comes from if you can see anything 
>> strange, apologies Thiago for sending it to you directly earlier!!
>> 
>> package org.opencsta.ctiserver.business.callevents.model;
>> 
>> import java.io.Serializable;
>> 
>> import javax.persistence.Entity;
>> import javax.persistence.GeneratedValue;
>> import javax.persistence.GenerationType;
>> import javax.persistence.Id;
>> import javax.persistence.NamedQueries;
>> import javax.persistence.NamedQuery;
>> import javax.persistence.Transient;
>> 
>> /**
>> * @author chrismylonas
>> * 
>> */
>> @Entity
>> @NamedQueries({ @NamedQuery(name 
>> =org.opencsta.ctiserver.business.callevents.model.CalledEvent.QUERY_GETALL, 
>> query ="select c FROM CalledEvent c") })
>> public class CalledEvent implements Serializable {
>> 
>>   /**
>>    * 
>>    */
>>   private static final long serialVersionUID =-35384297244606697L;
>> 
>>   /**
>>    * 
>>    */
>>   public static final String QUERY_GETALL 
>> ="org.opencsta.ctiserver.business.callevents.model.CalledEvent.QUERY_GETALL";
>> 
>>   /**
>>    * 
>>    */
>>   @Id
>>   @GeneratedValue(strategy =GenerationType.IDENTITY)
>>   private Long id;
>> 
>>   /**
>>    * 
>>    */
>>   private String name;
>> 
>>   /**
>>    * 
>>    */
>>   private String callingParty;
>> 
>>   /**
>>    * 
>>    */
>>   private String calledParty;
>> 
>>   /**
>>    * 
>>    */
>>   private String dialedNumber;
>> 
>>   /**
>>    * 
>>    */
>>   private String trunk;
>> 
>>   /**
>>    * 
>>    */
>>   private String server;
>> 
>>   /**
>>    * @return
>>    */
>>   public Long getId() {
>>       return id;
>>   }
>> 
>>   /**
>>    * @param id
>>    */
>>   public void setId(Long id) {
>>       this.id =id;
>>   }
>> 
>>   /**
>>    * @return
>>    */
>>   public String getName() {
>>       return name;
>>   }
>> 
>>   /**
>>    * @param name
>>    */
>>   public void setName(String name) {
>>       this.name =name;
>>   }
>> 
>>   /**
>>    * @return
>>    */
>>   public String getCallingParty() {
>>       return callingParty;
>>   }
>> 
>>   /**
>>    * @param callingParty
>>    */
>>   public void setCallingParty(String callingParty) {
>>       this.callingParty ĂŠllingParty;
>>   }
>> 
>>   /**
>>    * @return
>>    */
>>   public String getCalledParty() {
>>       return calledParty;
>>   }
>> 
>>   /**
>>    * @param calledParty
>>    */
>>   public void setCalledParty(String calledParty) {
>>       this.calledParty ĂŠlledParty;
>>   }
>> 
>>   /**
>>    * @return
>>    */
>>   public String getDialedNumber() {
>>       return dialedNumber;
>>   }
>> 
>>   /**
>>    * @param dialedNumber
>>    */
>>   public void setDialedNumber(String dialedNumber) {
>>       this.dialedNumber =dialedNumber;
>>   }
>> 
>>   /**
>>    * @return
>>    */
>>   public String getTrunk() {
>>       return trunk;
>>   }
>> 
>>   /**
>>    * @param trunk
>>    */
>>   public void setTrunk(String trunk) {
>>       this.trunk =trunk;
>>   }
>> 
>>   /**
>>    * @return
>>    */
>>   public String getServer() {
>>       return server;
>>   }
>> 
>>   /**
>>    * @param server
>>    */
>>   public void setServer(String server) {
>>       this.server =server;
>>   }
>> }
>> 
>> 
>> 
>> On 22/09/2011, at 12:53 AM, Lenny Primak wrote:
>> 
>>> This is EclipseLink.  I use it and ran into the same problem.
>>> 
>>> On Sep 21, 2011, at 10:28 AM, Lenny Primak wrote:
>>> 
>>>> If you add exclude="_persistence_shouldRefreshFetchGroup"
>>>> to your grid definition, this should resolve the problem.
>>>> 
>>>> On Sep 21, 2011, at 3:10 AM, Chris Mylonas wrote:
>>>> 
>>>>> Hello Tapestry Users,
>>>>> 
>>>>> I've got a problem with the grid element.
>>>>> 
>>>>> <t:grid source="calledEvents" value="calledEvent" />
>>>>> 
>>>>> It doesn't happen if I put my List<CalledEvent> into a Loop element and 
>>>>> build the table.
>>>>> 
>>>>>   <t:loop source="calledEvents" value="calledEvent">
>>>>>       <tr>
>>>>>           <td>${calledEvent.id}</td>
>>>>>           <td>${calledEvent.calledParty}</td>
>>>>>           <td>${calledEvent.callingParty}</td>
>>>>>           <td>${calledEvent.dialedNumber}</td>
>>>>>       </tr>
>>>>>   </t:loop>
>>>>> 
>>>>> I'm getting this error when using the grid
>>>>> 
>>>>> Render queue error in SetupRender[Index:grid.columns]: Failure reading 
>>>>> parameter 'model' of component Index:grid: Exception generating conduit 
>>>>> for expression '_persistence_shouldRefreshFetchGroup': Unable to add 
>>>>> method java.lang.Object get(java.lang.Object) to class 
>>>>> $PropertyConduit_1328ac84ee8: [source error] 
>>>>> _persistence_shouldRefreshFetchGroup() not found in 
>>>>> org.opencsta.ctiserver.business.callevents.model.CalledEvent
>>>>> 
>>>>> 
>>>>> What does this mean?
>>>>> 
>>>>> I'm using Geoff's @EJB stuff from jumpstart's EJBAnnotationWorker example
>>>>> 
>>>>> 
>>>>> I'd really like to use the grid because then I can use the rowsPerPage 
>>>>> parameter for "developer productivity" :P
>>>>> 
>>>>> Thanks for any help,
>>>>> Chris
>>>> 
>>>> 
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
>>>> For additional commands, e-mail: users-h...@tapestry.apache.org
>>>> 
>>> 
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
>>> For additional commands, e-mail: users-h...@tapestry.apache.org
>>> 
>> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
> 

Reply via email to