Sorry for being so newbie. I really need to know how to run from inside Eclipse 
so that I can set the breakpoint and get the stack trace. 

Sent from my iPhone

> On Mar 21, 2014, at 1:14 PM, Dan Haywood <[email protected]> 
> wrote:
> 
> Navigate > Open Type, then enter RootOidDefault.  Eclipse will show the
> source from the downloaded xxx-sources.jar for this module.
> 
> 
> 
> 
> 
>> On 21 March 2014 12:08, james agada <[email protected]> wrote:
>> 
>> how can i set the breakpoint in RootOID without importing the isis source
>> code?
>> 
>> 
>> On Thu, Mar 20, 2014 at 10:48 AM, Dan Haywood
>> <[email protected]>wrote:
>> 
>>> No need to import all of Isis source code if just being a "user"; the
>> page
>>> to look at is [1]
>>> 
>>> As Jeroen says in his subsequent post, do take a look around the Isis
>>> website [2]; it's always being updated and is in reasonable shape now, I
>>> think.
>>> 
>>> [1]
>> http://isis.apache.org/components/objectstores/jdo/datanucleus-and-eclipse.html
>>> .
>>> [2] http://isis.apache.org/documentation.html
>>> 
>>> 
>>> 
>>> 
>>>> On 19 March 2014 19:04, Jeroen van der Wal <[email protected]> wrote:
>>>> 
>>>> Really no IDE? You're making things so much harder without. I suggest
>>>> installing Eclipse Kepler for Java and import your project into it.
>>> There's
>>>> a guide on the Isis site [1] which covers how to set up your dev
>>>> environment. It's aimed at comitters so you can skip importing the Isis
>>>> source code if you're developing using the released version.
>>>> 
>>>> Let me know if you need further guidance.
>>>> 
>>>> Cheers,
>>>> 
>>>> Jeroen
>>>> 
>>>> [1]  http://isis.apache.org/contributors/development-environment.html
>>>>> On 19 Mar 2014 18:32, "james agada" <[email protected]> wrote:
>>>>> 
>>>>> I am not sure how to setup this up. I currently write my code without
>>> the
>>>>> IDE. I don't mind setting up to use Eclipse though if you guide me
>> -:)
>>>>> 
>>>>> 
>>>>> On Tue, Mar 18, 2014 at 12:36 AM, Dan Haywood
>>>>> <[email protected]>wrote:
>>>>> 
>>>>>> Not completely sure what's happening yet, but I think that Isis is
>>>>>> expecting an object being loaded by JDO to be a regular entity, and
>>>>> instead
>>>>>> it's getting an SCO (a JDO term, I think it means "secondary class
>>>>>> object").  This is probably the view object that was defined.
>>>>>> 
>>>>>> Whatever.
>>>>>> 
>>>>>> Searching through the code, that "contains an '@' symbol" string
>>>> appears
>>>>> in
>>>>>> the constructor for RootOidDefault.
>>>>>> 
>>>>>> Could you put a break point there with a conditional to break only
>>> when
>>>>> the
>>>>>> identifier contains an "@" symbol (as per [1]); when you hit the
>>>>> breakpoint
>>>>>> could you then copy out the stacktrace for me.
>>>>>> 
>>>>>> Thx
>>>>>> Dan
>>>>>> 
>>>>>> [1]
>> https://www.dropbox.com/s/yjt8efefb9tis2d/Screenshot%202014-03-17%2023.34.03.png
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>>> On 17 March 2014 23:27, james agada <[email protected]> wrote:
>>>>>>> 
>>>>>>> I checked the source code and the error seems to be raised from
>>> here
>>>>>>> 
>>>>>>>    private <T> T withLogging(PersistenceCapable pojo,
>> Callable<T>
>>>>>>> runnable, CalledFrom calledFrom) {
>>>>>>>>        if (LOG.isDebugEnabled()) {
>>>>>>>>            LOG.debug(logString(calledFrom,
>>> LoggingLocation.ENTRY,
>>>>>>> pojo));
>>>>>>>>        }
>>>>>>>>        try {
>>>>>>>>            return runnable.call();
>>>>>>>>        } catch (Exception e) {
>>>>>>>>            throw new RuntimeException(e);
>>>>>>>>        } finally {
>>>>>>>>            if (LOG.isDebugEnabled()) {
>>>>>>>>                LOG.debug(logString(calledFrom,
>>>> LoggingLocation.EXIT,
>>>>>>> pojo));
>>>>>>>>            }
>>>>>>>>        }
>>>>>>>>    }
>>>>>>> from
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.FrameworkSynchronizer.withLogging(FrameworkSynchronizer.java:273)
>>>>>>> .
>>>>>>> What I don't know is why and under what circumstances should the
>>>>>>> RuntimeException be raised.
>>>>>>> 
>>>>>>> 
>>>>>>> On Mon, Mar 17, 2014 at 9:54 PM, Jeroen van der Wal <
>>>>> [email protected]
>>>>>>>> wrote:
>>>>>>> 
>>>>>>>> Hi James,
>>>>>>>> 
>>>>>>>> The invoice summaries in Estatio also contain queries.
>>>>>>>> 
>>>>>>>> Example:
>> https://github.com/estatio/estatio/blob/master/dom/src/main/java/org/estatio/dom/invoice/viewmodel/InvoiceSummaryForInvoiceRun.java
>>>>>>>> Accessed through the repository:
>> https://github.com/estatio/estatio/blob/master/dom/src/main/java/org/estatio/dom/invoice/viewmodel/InvoiceSummariesForInvoiceRun.java
>>>>>>>> 
>>>>>>>> Hope this helps.
>>>>>>>> 
>>>>>>>> Jeroen
>>>>>>>> On 17 Mar 2014 20:50, "james agada" <[email protected]>
>>> wrote:
>>>>>>>> 
>>>>>>>>> any help? Cant seem to be able to track this down.
>>>>>>>>> 
>>>>>>>>> 
>>>>>>>>> On Sun, Mar 16, 2014 at 7:52 PM, james agada <
>>>> [email protected]
>>>>>> 
>>>>>>>> wrote:
>>>>>>>>> 
>>>>>>>>>> Following the examples in Estatio, I have defined a query
>>> model
>>>>>> like
>>>>>>>> this
>>>>>>>>>> 
>>>>>>>>>>> 
>>>>>>>>>>> @javax.jdo.annotations.PersistenceCapable(
>>>>>>>>>>> 
>>>>>>>>>>>    identityType = IdentityType.NONDURABLE,
>>>>>>>>>>> 
>>>>>>>>>>>    table = "DailySalesTotalForParty",
>>>>>>>>>>> 
>>>>>>>>>>>    extensions = {
>>>>>>>>>>> 
>>>>>>>>>>>        @Extension(vendorName = "datanucleus", key =
>>>>>>>>>>> "view-definition-mysql",
>>>>>>>>>>> 
>>>>>>>>>>>            value = "CREATE VIEW {DailySalesTotalForParty}
>>> " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "( " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "  {this.transactionDate}, " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "  {this.totalAmount} ," +
>>>>>>>>>>> 
>>>>>>>>>>>                    "  {this.fromPartyReference}, " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "  {this.transactiontype} " +
>>>>>>>>>>> 
>>>>>>>>>>>                    ") AS " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "SELECT " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "   {Transaction.transactionDate} , "
>> +
>>>>>>>>>>> 
>>>>>>>>>>> 
>>>>>>>>>>>                    "   SUM({Transaction.faceValue}) AS
>>>>>> totalAmount
>>>>>>>> ," +
>>>>>>>>>>> 
>>>>>>>>>>>                   // "
>>>>>> \"Transaction\".\"fromParty_Party_ID_OID\"
>>>>>>>> AS
>>>>>>>>>>> \"fromParty\", " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "   {Transaction.fromPartyReference}
>> ,
>>> "
>>>> +
>>>>>>>>>>> 
>>>>>>>>>>> 
>>>>>>>>>>> "   {Transaction.transactiontype} " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "  FROM " +
>>>>>>>>>>> 
>>>>>>>>>>> "   {Transaction} " +
>>>>>>>>>>> 
>>>>>>>>>>>                    "GROUP BY " +
>>>>>>>>>>> 
>>>>>>>>>>>                    " {Transaction.transactionDate},  " +
>>>>>>>>>>> 
>>>>>>>>>>> " {Transaction.fromPartyReference}, " +
>>>>>>>>>>> 
>>>>>>>>>>> " {Transaction.transactiontype} "
>>>>>>>>>>> 
>>>>>>>>>>> +
>>>>>>>>>>> 
>>>>>>>>>>>                    "ORDER BY " +
>>>>>>>>>>> 
>>>>>>>>>>>                    " {Transaction.transactionDate}, " +
>>>>>>>>>>> 
>>>>>>>>>>> " {Transaction.fromPartyReference}, " +
>>>>>>>>>>> 
>>>>>>>>>>> " {Transaction.transactiontype}"
>>>>>>>>>>> 
>>>>>>>>>>> )
>>>>>>>>>>> 
>>>>>>>>>>>     })
>>>>>>>>>>> 
>>>>>>>>>>> @javax.jdo.annotations.Inheritance(strategy =
>>>>>>>>>>> InheritanceStrategy.NEW_TABLE)
>>>>>>>>>>> 
>>>>>>>>>>> @javax.jdo.annotations.Queries( {
>>>>>>>>>>> 
>>>>>>>>>>> @javax.jdo.annotations.Query(
>>>>>>>>>>> 
>>>>>>>>>>> name="DailySalesForParty", language="JDOQL",
>>>>>>>>>>> 
>>>>>>>>>>> value="SELECT FROM dom.todo.DailySalesTotalForParty WHERE
>>>>>>>>>>> fromPartyReference == :party ")
>>>>>>>>>>> 
>>>>>>>>>>> })
>>>>>>>>>>> 
>>>>>>>>>>> @Bookmarkable
>>>>>>>>>>> 
>>>>>>>>>>> @Immutable
>>>>>>>>>>> 
>>>>>>>>>>> public class DailySalesTotalForParty  { ........
>>>>>>>>>> 
>>>>>>>>>> I try to get the records from the view using the Query
>>>> definition
>>>>>> in
>>>>>>> a
>>>>>>>>>> service as
>>>>>>>>>> 
>>>>>>>>>>> @Programmatic
>>>>>>>>>>> 
>>>>>>>>>>> public List<DailySalesTotalForParty>
>>>>>>> getDailySalesTotalForParty(Party
>>>>>>>>> p){
>>>>>>>>>>> 
>>>>>>>>>>> //get party id
>>>>>>>>>>> 
>>>>>>>>>>> //get party
>>>>>>>>>>> 
>>>>>>>>>>> //String party = p.getUniqueRef();
>>>>>>>>>>> 
>>>>>>>>>>> //party="2";
>>>>>>>>>>> 
>>>>>>>>>>> return allMatches(
>>>>>>>>>>> 
>>>>>>>>>>> new QueryDefault<DailySalesTotalForParty>(
>>>>>>>>> DailySalesTotalForParty.class,
>>>>>>>>>>> 
>>>>>>>>>>> "DailySalesForParty",
>>>>>>>>>>> 
>>>>>>>>>>> "party",p.getUniqueRef());
>>>>>>>>>>> 
>>>>>>>>>>> }
>>>>>>>>>> 
>>>>>>>>>> But I end up with this error during runtime
>>>>>>>>>> 
>>>>>>>>>> [exec] 19:52:40,699  [Native               qtp1993764967-32
>>>>> DEBUG]
>>>>>>>>> SELECT
>>>>>>>>>>> 'dom.todo.DailySalesTotalForParty' AS
>> NUCLEUS_TYPE,`A0`.`FROMPARTYREFERENCE`,`A0`.`TOTALAMOUNT`,`A0`.`TRANSACTIONDATE`,`A0`.`TRANSACTIONTYPE`
>>>>>>>>>>> FROM `DAILYSALESTOTALFORPARTY` `A0` WHERE
>>>>>> `A0`.`FROMPARTYREFERENCE`
>>>>>>> =
>>>>>>>>> <'2'>
>>>>>>>>>>> 
>>>>>>>>>>>     [exec] 19:52:40,778  [RequestCycleExtra
>>>> qtp1993764967-32
>>>>>>> WARN
>>>>>>>> ]
>>>>>>>>>>> ********************************
>>>>>>>>>>> 
>>>>>>>>>>>     [exec] 19:52:40,778  [RequestCycleExtra
>>>> qtp1993764967-32
>>>>>>> WARN
>>>>>>>> ]
>>>>>>>>>>> Handling the following exception
>>>>>>>>>>> 
>>>>>>>>>>>     [exec] org.apache.wicket.WicketRuntimeException:
>> Error
>>>>>>> attaching
>>>>>>>>>>> this container for rendering: [WebMarkupContainer
>> [Component
>>>> id
>>>>> =
>>>>>>>> body]]
>>>>>>>>>>> 
>>>>>>>>>>>     [exec] at
>> org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1693)
>>>>>>>>>>> 
>>>>>>>>>>>     [exec]
>>>>>>>>>> ..........
>>>>>>>>>> 
>>>>>>>>>>     [exec] Caused by: java.lang.RuntimeException:
>>>>>>>>>> java.lang.IllegalArgumentException: identifier
>>>> 'org.datanucleus.identity.SCOID_org.datanucleus.identity.SCOID@73946e71
>>>>>>>> '
>>>>>>>>>> contains an '@' symbol
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.FrameworkSynchronizer.withLogging(FrameworkSynchronizer.java:273)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.FrameworkSynchronizer.withLogging(FrameworkSynchronizer.java:282)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.FrameworkSynchronizer.postLoadProcessingFor(FrameworkSynchronizer.java:69)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.queries.PersistenceQueryProcessorAbstract.loadAdapters(PersistenceQueryProcessorAbstract.java:82)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.queries.PersistenceQueryFindUsingApplibQueryProcessor.process(PersistenceQueryFindUsingApplibQueryProcessor.java:64)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.persistence.queries.PersistenceQueryFindUsingApplibQueryProcessor.process(PersistenceQueryFindUsingApplibQueryProcessor.java:43)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.DataNucleusObjectStore.processPersistenceQuery(DataNucleusObjectStore.java:542)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.objectstore.jdo.datanucleus.DataNucleusObjectStore.loadInstancesAndAdapt(DataNucleusObjectStore.java:537)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.persistence.PersistenceSession$1.execute(PersistenceSession.java:461)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.persistence.PersistenceSession$1.execute(PersistenceSession.java:458)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.transaction.IsisTransactionManager.executeWithinTransaction(IsisTransactionManager.java:217)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.persistence.PersistenceSession.getInstancesFromPersistenceLayer(PersistenceSession.java:458)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.persistence.PersistenceSession.getInstances(PersistenceSession.java:454)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.persistence.PersistenceSession.findInstances(PersistenceSession.java:391)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.system.persistence.PersistenceSession.findInstances(PersistenceSession.java:386)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.runtime.persistence.internal.RuntimeContextFromSession$8.allMatchingQuery(RuntimeContextFromSession.java:260)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.core.metamodel.services.container.DomainObjectContainerDefault.allMatches(DomainObjectContainerDefault.java:400)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>> org.apache.isis.applib.AbstractContainedObject.allMatches(AbstractContainedObject.java:175)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at
>>>>> dom.todo.Partytypes.getDailySalesTotalForParty(Partytypes.java:392)
>>>>>>>>>> 
>>>>>>>>>>     [exec] at dom.todo.Party.getDailySales(Party.java:283)
>>>>>>>>>> 
>>>>>>>>>> What could be wrong? What does
>>>> org.datanucleus.identity.SCOID_org.datanucleus.identity.SCOID@73946e71
>>>>>>>> '
>>>>>>>>>> contains an '@' symbol mean? Where do I start to look for
>> the
>>>>>>> problem?
>>>>>>>>>> 
>> 

Reply via email to