You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Michael Imhof <mi...@nowhow.ch> on 2007/05/01 11:15:08 UTC

Error in simple-method operation

I got an OutOfMemoryError using simple-method <entity-and (same with
<find-by-and).

Error in simple-method operation [<entity-and/>]:
java.lang.OutOfMemoryError: Java heap space

The Error occurs only once (the first call of the service). 
Then it works fine...

<entity-and entity-name="Country" list-name="countryList">
    <field-map field-name="itaCode" value="${itaValue}"/>
</entity-and>

Does somebody has an idea where this is coming from??? And why does it only
occurs the first time (probably something with initialization, cache, ..??)?

Michael
-- 
View this message in context: http://www.nabble.com/Error-in-simple-method-operation-tf3674071.html#a10266407
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Error in simple-method operation

Posted by Michael Imhof <mi...@nowhow.ch>.
We're using an ofbiz version of mid february. We made some changes, but
nothing
concerning mini-lang or entity-engine. 

But i made changes on the entityengine.xml (had to, of course:-)).
I loaded the old version of entity-engine.xml and the error was gone!! So
what happens??

Playing and testing around I figured out that the attribute check-on-start
is kidding me!

<datasource name="isDatabase"
        helper-class="org.ofbiz.entity.datasource.GenericHelperDAO"
        field-type-name="mysql"
        check-on-start="false"
...
---> OutOfMemory Error

<datasource name="isDatabase"
        helper-class="org.ofbiz.entity.datasource.GenericHelperDAO"
        field-type-name="mysql"
  check-on-start="true"
...
---> Alll is working fine...

Michael




David E. Jones-2 wrote:
> 
> 
> Which version/revision of OFBiz are you using? Have you made any  
> changes?
> 
> -David
> 
> 
> On May 1, 2007, at 5:20 AM, Michael Imhof wrote:
> 
>>
>> Yes, thats something I was thinking about. But the table has only  
>> 70 entries.
>> I tried the query with the <find-by-and operator and tested
>> use-iterator=true/false & use-cache=true/false.
>>
>> <find-by-and use-iterator="true" entity-name="Country"
>> map-name="countryLookup" list-name="countryList" />
>>
>> But still the same error.. Next I will delete the table and try
>> again...Strange?!
>> Michael
>>
>>
>> David E. Jones-2 wrote:
>>>
>>>
>>> Or perhaps you're trying to do a query to get results from a very
>>> large table without using the entity list iterator?
>>>
>>> -David
>>>
>>>
>>> On May 1, 2007, at 5:00 AM, Michael Imhof wrote:
>>>
>>>>
>>>> Hi Mridul,
>>>>
>>>> increasing the heap space is not solving the problem. It just takes
>>>> longer
>>>> for the exception
>>>> to appear. Seems to be a loop somewhere...
>>>>
>>>> Michael
>>>>
>>>>
>>>> Mridul Pathak wrote:
>>>>>
>>>>> Hi Micheal,
>>>>>    For the OutOfMemoryError here is the solution I think that
>>>>> might work
>>>>> in
>>>>> your case:
>>>>>   For running ofbiz from command line..instead of java -jar
>>>>> ofbiz.jar you
>>>>> can use
>>>>>   java -Xms512m -Xmx1024m -jar ofbiz.jar
>>>>>   This will solve ur OutOfMemory problem in any of the ofbiz
>>>>> operations.
>>>>> Regards,
>>>>> Mridul
>>>>>
>>>>>
>>>>>
>>>>> On 5/1/07, Michael Imhof <mi...@nowhow.ch> wrote:
>>>>>>
>>>>>>
>>>>>> I got an OutOfMemoryError using simple-method <entity-and (same  
>>>>>> with
>>>>>> <find-by-and).
>>>>>>
>>>>>> Error in simple-method operation [<entity-and/>]:
>>>>>> java.lang.OutOfMemoryError: Java heap space
>>>>>>
>>>>>> The Error occurs only once (the first call of the service).
>>>>>> Then it works fine...
>>>>>>
>>>>>> <entity-and entity-name="Country" list-name="countryList">
>>>>>>     <field-map field-name="itaCode" value="${itaValue}"/>
>>>>>> </entity-and>
>>>>>>
>>>>>> Does somebody has an idea where this is coming from??? And why
>>>>>> does it
>>>>>> only
>>>>>> occurs the first time (probably something with initialization,
>>>>>> cache,
>>>>>> ..??)?
>>>>>>
>>>>>> Michael
>>>>>> --
>>>>>> View this message in context:
>>>>>> http://www.nabble.com/Error-in-simple-method-operation-
>>>>>> tf3674071.html#a10266407
>>>>>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>> -- 
>>>> View this message in context: http://www.nabble.com/Error-in-simple-
>>>> method-operation-tf3674071.html#a10267473
>>>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>>>
>>>
>>>
>>>
>>>
>>
>> -- 
>> View this message in context: http://www.nabble.com/Error-in-simple- 
>> method-operation-tf3674071.html#a10267646
>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>
> 
> 
>  
> 

-- 
View this message in context: http://www.nabble.com/Error-in-simple-method-operation-tf3674071.html#a10268403
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Error in simple-method operation

Posted by "David E. Jones" <jo...@hotwaxmedia.com>.
Which version/revision of OFBiz are you using? Have you made any  
changes?

-David


On May 1, 2007, at 5:20 AM, Michael Imhof wrote:

>
> Yes, thats something I was thinking about. But the table has only  
> 70 entries.
> I tried the query with the <find-by-and operator and tested
> use-iterator=true/false & use-cache=true/false.
>
> <find-by-and use-iterator="true" entity-name="Country"
> map-name="countryLookup" list-name="countryList" />
>
> But still the same error.. Next I will delete the table and try
> again...Strange?!
> Michael
>
>
> David E. Jones-2 wrote:
>>
>>
>> Or perhaps you're trying to do a query to get results from a very
>> large table without using the entity list iterator?
>>
>> -David
>>
>>
>> On May 1, 2007, at 5:00 AM, Michael Imhof wrote:
>>
>>>
>>> Hi Mridul,
>>>
>>> increasing the heap space is not solving the problem. It just takes
>>> longer
>>> for the exception
>>> to appear. Seems to be a loop somewhere...
>>>
>>> Michael
>>>
>>>
>>> Mridul Pathak wrote:
>>>>
>>>> Hi Micheal,
>>>>    For the OutOfMemoryError here is the solution I think that
>>>> might work
>>>> in
>>>> your case:
>>>>   For running ofbiz from command line..instead of java -jar
>>>> ofbiz.jar you
>>>> can use
>>>>   java -Xms512m -Xmx1024m -jar ofbiz.jar
>>>>   This will solve ur OutOfMemory problem in any of the ofbiz
>>>> operations.
>>>> Regards,
>>>> Mridul
>>>>
>>>>
>>>>
>>>> On 5/1/07, Michael Imhof <mi...@nowhow.ch> wrote:
>>>>>
>>>>>
>>>>> I got an OutOfMemoryError using simple-method <entity-and (same  
>>>>> with
>>>>> <find-by-and).
>>>>>
>>>>> Error in simple-method operation [<entity-and/>]:
>>>>> java.lang.OutOfMemoryError: Java heap space
>>>>>
>>>>> The Error occurs only once (the first call of the service).
>>>>> Then it works fine...
>>>>>
>>>>> <entity-and entity-name="Country" list-name="countryList">
>>>>>     <field-map field-name="itaCode" value="${itaValue}"/>
>>>>> </entity-and>
>>>>>
>>>>> Does somebody has an idea where this is coming from??? And why
>>>>> does it
>>>>> only
>>>>> occurs the first time (probably something with initialization,
>>>>> cache,
>>>>> ..??)?
>>>>>
>>>>> Michael
>>>>> --
>>>>> View this message in context:
>>>>> http://www.nabble.com/Error-in-simple-method-operation-
>>>>> tf3674071.html#a10266407
>>>>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> -- 
>>> View this message in context: http://www.nabble.com/Error-in-simple-
>>> method-operation-tf3674071.html#a10267473
>>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>>
>>
>>
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/Error-in-simple- 
> method-operation-tf3674071.html#a10267646
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>


Re: Error in simple-method operation

Posted by Michael Imhof <mi...@nowhow.ch>.
Yes, thats something I was thinking about. But the table has only 70 entries.
I tried the query with the <find-by-and operator and tested
use-iterator=true/false & use-cache=true/false.

<find-by-and use-iterator="true" entity-name="Country"
map-name="countryLookup" list-name="countryList" />

But still the same error.. Next I will delete the table and try
again...Strange?!
Michael


David E. Jones-2 wrote:
> 
> 
> Or perhaps you're trying to do a query to get results from a very  
> large table without using the entity list iterator?
> 
> -David
> 
> 
> On May 1, 2007, at 5:00 AM, Michael Imhof wrote:
> 
>>
>> Hi Mridul,
>>
>> increasing the heap space is not solving the problem. It just takes  
>> longer
>> for the exception
>> to appear. Seems to be a loop somewhere...
>>
>> Michael
>>
>>
>> Mridul Pathak wrote:
>>>
>>> Hi Micheal,
>>>    For the OutOfMemoryError here is the solution I think that  
>>> might work
>>> in
>>> your case:
>>>   For running ofbiz from command line..instead of java -jar  
>>> ofbiz.jar you
>>> can use
>>>   java -Xms512m -Xmx1024m -jar ofbiz.jar
>>>   This will solve ur OutOfMemory problem in any of the ofbiz  
>>> operations.
>>> Regards,
>>> Mridul
>>>
>>>
>>>
>>> On 5/1/07, Michael Imhof <mi...@nowhow.ch> wrote:
>>>>
>>>>
>>>> I got an OutOfMemoryError using simple-method <entity-and (same with
>>>> <find-by-and).
>>>>
>>>> Error in simple-method operation [<entity-and/>]:
>>>> java.lang.OutOfMemoryError: Java heap space
>>>>
>>>> The Error occurs only once (the first call of the service).
>>>> Then it works fine...
>>>>
>>>> <entity-and entity-name="Country" list-name="countryList">
>>>>     <field-map field-name="itaCode" value="${itaValue}"/>
>>>> </entity-and>
>>>>
>>>> Does somebody has an idea where this is coming from??? And why  
>>>> does it
>>>> only
>>>> occurs the first time (probably something with initialization,  
>>>> cache,
>>>> ..??)?
>>>>
>>>> Michael
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/Error-in-simple-method-operation- 
>>>> tf3674071.html#a10266407
>>>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>>>
>>>>
>>>
>>>
>>
>> -- 
>> View this message in context: http://www.nabble.com/Error-in-simple- 
>> method-operation-tf3674071.html#a10267473
>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>
> 
> 
>  
> 

-- 
View this message in context: http://www.nabble.com/Error-in-simple-method-operation-tf3674071.html#a10267646
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Error in simple-method operation

Posted by "David E. Jones" <jo...@hotwaxmedia.com>.
Or perhaps you're trying to do a query to get results from a very  
large table without using the entity list iterator?

-David


On May 1, 2007, at 5:00 AM, Michael Imhof wrote:

>
> Hi Mridul,
>
> increasing the heap space is not solving the problem. It just takes  
> longer
> for the exception
> to appear. Seems to be a loop somewhere...
>
> Michael
>
>
> Mridul Pathak wrote:
>>
>> Hi Micheal,
>>    For the OutOfMemoryError here is the solution I think that  
>> might work
>> in
>> your case:
>>   For running ofbiz from command line..instead of java -jar  
>> ofbiz.jar you
>> can use
>>   java -Xms512m -Xmx1024m -jar ofbiz.jar
>>   This will solve ur OutOfMemory problem in any of the ofbiz  
>> operations.
>> Regards,
>> Mridul
>>
>>
>>
>> On 5/1/07, Michael Imhof <mi...@nowhow.ch> wrote:
>>>
>>>
>>> I got an OutOfMemoryError using simple-method <entity-and (same with
>>> <find-by-and).
>>>
>>> Error in simple-method operation [<entity-and/>]:
>>> java.lang.OutOfMemoryError: Java heap space
>>>
>>> The Error occurs only once (the first call of the service).
>>> Then it works fine...
>>>
>>> <entity-and entity-name="Country" list-name="countryList">
>>>     <field-map field-name="itaCode" value="${itaValue}"/>
>>> </entity-and>
>>>
>>> Does somebody has an idea where this is coming from??? And why  
>>> does it
>>> only
>>> occurs the first time (probably something with initialization,  
>>> cache,
>>> ..??)?
>>>
>>> Michael
>>> --
>>> View this message in context:
>>> http://www.nabble.com/Error-in-simple-method-operation- 
>>> tf3674071.html#a10266407
>>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>>
>>>
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/Error-in-simple- 
> method-operation-tf3674071.html#a10267473
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>


Re: Error in simple-method operation

Posted by Michael Imhof <mi...@nowhow.ch>.
Hi Mridul,

increasing the heap space is not solving the problem. It just takes longer
for the exception 
to appear. Seems to be a loop somewhere...

Michael


Mridul Pathak wrote:
> 
> Hi Micheal,
>    For the OutOfMemoryError here is the solution I think that might work
> in
> your case:
>   For running ofbiz from command line..instead of java -jar ofbiz.jar you
> can use
>   java -Xms512m -Xmx1024m -jar ofbiz.jar
>   This will solve ur OutOfMemory problem in any of the ofbiz operations.
> Regards,
> Mridul
> 
> 
> 
> On 5/1/07, Michael Imhof <mi...@nowhow.ch> wrote:
>>
>>
>> I got an OutOfMemoryError using simple-method <entity-and (same with
>> <find-by-and).
>>
>> Error in simple-method operation [<entity-and/>]:
>> java.lang.OutOfMemoryError: Java heap space
>>
>> The Error occurs only once (the first call of the service).
>> Then it works fine...
>>
>> <entity-and entity-name="Country" list-name="countryList">
>>     <field-map field-name="itaCode" value="${itaValue}"/>
>> </entity-and>
>>
>> Does somebody has an idea where this is coming from??? And why does it
>> only
>> occurs the first time (probably something with initialization, cache,
>> ..??)?
>>
>> Michael
>> --
>> View this message in context:
>> http://www.nabble.com/Error-in-simple-method-operation-tf3674071.html#a10266407
>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/Error-in-simple-method-operation-tf3674071.html#a10267473
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Error in simple-method operation

Posted by Mridul Pathak <mr...@adititechlabs.com>.
Hi Micheal,
   For the OutOfMemoryError here is the solution I think that might work in
your case:
  For running ofbiz from command line..instead of java -jar ofbiz.jar you
can use
  java -Xms512m -Xmx1024m -jar ofbiz.jar
  This will solve ur OutOfMemory problem in any of the ofbiz operations.
Regards,
Mridul



On 5/1/07, Michael Imhof <mi...@nowhow.ch> wrote:
>
>
> I got an OutOfMemoryError using simple-method <entity-and (same with
> <find-by-and).
>
> Error in simple-method operation [<entity-and/>]:
> java.lang.OutOfMemoryError: Java heap space
>
> The Error occurs only once (the first call of the service).
> Then it works fine...
>
> <entity-and entity-name="Country" list-name="countryList">
>     <field-map field-name="itaCode" value="${itaValue}"/>
> </entity-and>
>
> Does somebody has an idea where this is coming from??? And why does it
> only
> occurs the first time (probably something with initialization, cache,
> ..??)?
>
> Michael
> --
> View this message in context:
> http://www.nabble.com/Error-in-simple-method-operation-tf3674071.html#a10266407
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>
>