VerveineJ out of memory error

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

VerveineJ out of memory error

Fabrizio Perin
Hi,
i just try to use VerveineJ to import Java code in moose and i'm not able to make it work: first i tried by command line to use VerveineJ to create the mse of LANModel and it worked. Than i tried to use it with one of my case study and i got: java.lang.OutOfMemoryError: Java heap space.

I tried to modify the script verveinej.sh adding the -Xmx2048m option ( JOPT="-Xmx2048m" ) and it still doesn't work.

Than i tried to use the Moose Wizard and again for the LANModel no problem, but when i tried to import one of my case study i get an error: a message box appear saying that the output.mse file doesn't exist and it ask me to point to an existing file. Apparently verveinej just does not create the file because not able to parse the project and the importer try to go ahead but it does not have any output file from verveinej.

Someone has a similar problem? Am i doing something wrong?

Cheers,

Fabrizio
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: VerveineJ out of memory error

anquetil.nicolas
Hi Fabrizio,

Is your project big? I used VerveineJ to parse Eclipse 3.1 which has
about 4500 java classes and interfaces.

For this what I did is a copy of the verveinej.sh shell script
specially tailored to eclipse: I put like you said 'java -Xmx2500m'
and the specific classpath required to parse successfully eclipse.

If I can have access to your java project, I could try to understand
what is happening....

Another thing that you can do is trying to import your project in
Eclipse. Since VerveineJ is based on JDT parser, if Eclipse accepts
it, then VerveineJ should accept it too ...

nicolas

On Thu, Nov 18, 2010 at 3:47 PM, Fabrizio Perin <[hidden email]> wrote:

> Hi,
> i just try to use VerveineJ to import Java code in moose and i'm not able to make it work: first i tried by command line to use VerveineJ to create the mse of LANModel and it worked. Than i tried to use it with one of my case study and i got: java.lang.OutOfMemoryError: Java heap space.
>
> I tried to modify the script verveinej.sh adding the -Xmx2048m option ( JOPT="-Xmx2048m" ) and it still doesn't work.
>
> Than i tried to use the Moose Wizard and again for the LANModel no problem, but when i tried to import one of my case study i get an error: a message box appear saying that the output.mse file doesn't exist and it ask me to point to an existing file. Apparently verveinej just does not create the file because not able to parse the project and the importer try to go ahead but it does not have any output file from verveinej.
>
> Someone has a similar problem? Am i doing something wrong?
>
> Cheers,
>
> Fabrizio
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>



--
Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: VerveineJ out of memory error

Fabrizio Perin
Hi Nicolas,
well one of that case study that i was trying to import is Adempiere:

http://sourceforge.net/projects/adempiere/files/

I will try again with the command line and than i will let you know. Regarding eclipse, well is it not straight import that mess into eclipse in such a way that the code compiles. Anyhow I will try also that way.

Thanks for the quick answer.

Cheers,

Fabrizio



On 18 Nov 2010, at 15:58, [hidden email] wrote:

> Hi Fabrizio,
>
> Is your project big? I used VerveineJ to parse Eclipse 3.1 which has
> about 4500 java classes and interfaces.
>
> For this what I did is a copy of the verveinej.sh shell script
> specially tailored to eclipse: I put like you said 'java -Xmx2500m'
> and the specific classpath required to parse successfully eclipse.
>
> If I can have access to your java project, I could try to understand
> what is happening....
>
> Another thing that you can do is trying to import your project in
> Eclipse. Since VerveineJ is based on JDT parser, if Eclipse accepts
> it, then VerveineJ should accept it too ...
>
> nicolas
>
> On Thu, Nov 18, 2010 at 3:47 PM, Fabrizio Perin <[hidden email]> wrote:
>> Hi,
>> i just try to use VerveineJ to import Java code in moose and i'm not able to make it work: first i tried by command line to use VerveineJ to create the mse of LANModel and it worked. Than i tried to use it with one of my case study and i got: java.lang.OutOfMemoryError: Java heap space.
>>
>> I tried to modify the script verveinej.sh adding the -Xmx2048m option ( JOPT="-Xmx2048m" ) and it still doesn't work.
>>
>> Than i tried to use the Moose Wizard and again for the LANModel no problem, but when i tried to import one of my case study i get an error: a message box appear saying that the output.mse file doesn't exist and it ask me to point to an existing file. Apparently verveinej just does not create the file because not able to parse the project and the importer try to go ahead but it does not have any output file from verveinej.
>>
>> Someone has a similar problem? Am i doing something wrong?
>>
>> Cheers,
>>
>> Fabrizio
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>
>
>
> --
> Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: VerveineJ out of memory error

anquetil.nicolas
Fabrizio,

I believe the project is too big.

I have been downloading the source code for the past 90 minutes and
it's still not done.
I already have close to 20000 java source files.

I am afraid it will not be possible to put all this in memory at the same time.

The problem is:
- the ASTs are all created in memory because to resolve bindings, the
parser may need all the entities
- on top of that, there is all the Famix Entities that represent the
node in the ASTs and have relations one to the other ...

So it is a lot of things to keep in memory and for a project this
size, I am afraid the java VM will not allow you to have a big enough
memory space (on my machine it is limited to about 2.5 G., not by the
computer but by the JVM)

Anyway, it is not even clear you could then load the resulting MSE in Moose ?!?

One could think of doing some kind of "separate compilation" (what the
java compiler actually does), but it would be way past my time
resources.

If it is a solution for you, II can only suggest to divide the whole
project into subprojects (something that probably already exist in the
source code, I doubt they manage such a big system in only one piece)
and deal with the sub-projects separately.

nicolas

On Thu, Nov 18, 2010 at 4:17 PM, Fabrizio Perin <[hidden email]> wrote:

> Hi Nicolas,
> well one of that case study that i was trying to import is Adempiere:
>
> http://sourceforge.net/projects/adempiere/files/
>
> I will try again with the command line and than i will let you know. Regarding eclipse, well is it not straight import that mess into eclipse in such a way that the code compiles. Anyhow I will try also that way.
>
> Thanks for the quick answer.
>
> Cheers,
>
> Fabrizio
>
>
>
> On 18 Nov 2010, at 15:58, [hidden email] wrote:
>
>> Hi Fabrizio,
>>
>> Is your project big? I used VerveineJ to parse Eclipse 3.1 which has
>> about 4500 java classes and interfaces.
>>
>> For this what I did is a copy of the verveinej.sh shell script
>> specially tailored to eclipse: I put like you said 'java -Xmx2500m'
>> and the specific classpath required to parse successfully eclipse.
>>
>> If I can have access to your java project, I could try to understand
>> what is happening....
>>
>> Another thing that you can do is trying to import your project in
>> Eclipse. Since VerveineJ is based on JDT parser, if Eclipse accepts
>> it, then VerveineJ should accept it too ...
>>
>> nicolas
>>
>> On Thu, Nov 18, 2010 at 3:47 PM, Fabrizio Perin <[hidden email]> wrote:
>>> Hi,
>>> i just try to use VerveineJ to import Java code in moose and i'm not able to make it work: first i tried by command line to use VerveineJ to create the mse of LANModel and it worked. Than i tried to use it with one of my case study and i got: java.lang.OutOfMemoryError: Java heap space.
>>>
>>> I tried to modify the script verveinej.sh adding the -Xmx2048m option ( JOPT="-Xmx2048m" ) and it still doesn't work.
>>>
>>> Than i tried to use the Moose Wizard and again for the LANModel no problem, but when i tried to import one of my case study i get an error: a message box appear saying that the output.mse file doesn't exist and it ask me to point to an existing file. Apparently verveinej just does not create the file because not able to parse the project and the importer try to go ahead but it does not have any output file from verveinej.
>>>
>>> Someone has a similar problem? Am i doing something wrong?
>>>
>>> Cheers,
>>>
>>> Fabrizio
>>> _______________________________________________
>>> Moose-dev mailing list
>>> [hidden email]
>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>>
>>
>>
>>
>> --
>> Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>



--
Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: VerveineJ out of memory error

Fabrizio Perin
Hi Nicolas,
thanks really a lot for your time. I will try as you suggest, i will split the program and i will try to parse it one piece at time.

Cheers,

Fabrizio




On 18 Nov 2010, at 17:53, [hidden email] wrote:

> Fabrizio,
>
> I believe the project is too big.
>
> I have been downloading the source code for the past 90 minutes and
> it's still not done.
> I already have close to 20000 java source files.
>
> I am afraid it will not be possible to put all this in memory at the same time.
>
> The problem is:
> - the ASTs are all created in memory because to resolve bindings, the
> parser may need all the entities
> - on top of that, there is all the Famix Entities that represent the
> node in the ASTs and have relations one to the other ...
>
> So it is a lot of things to keep in memory and for a project this
> size, I am afraid the java VM will not allow you to have a big enough
> memory space (on my machine it is limited to about 2.5 G., not by the
> computer but by the JVM)
>
> Anyway, it is not even clear you could then load the resulting MSE in Moose ?!?
>
> One could think of doing some kind of "separate compilation" (what the
> java compiler actually does), but it would be way past my time
> resources.
>
> If it is a solution for you, II can only suggest to divide the whole
> project into subprojects (something that probably already exist in the
> source code, I doubt they manage such a big system in only one piece)
> and deal with the sub-projects separately.
>
> nicolas
>
> On Thu, Nov 18, 2010 at 4:17 PM, Fabrizio Perin <[hidden email]> wrote:
>> Hi Nicolas,
>> well one of that case study that i was trying to import is Adempiere:
>>
>> http://sourceforge.net/projects/adempiere/files/
>>
>> I will try again with the command line and than i will let you know. Regarding eclipse, well is it not straight import that mess into eclipse in such a way that the code compiles. Anyhow I will try also that way.
>>
>> Thanks for the quick answer.
>>
>> Cheers,
>>
>> Fabrizio
>>
>>
>>
>> On 18 Nov 2010, at 15:58, [hidden email] wrote:
>>
>>> Hi Fabrizio,
>>>
>>> Is your project big? I used VerveineJ to parse Eclipse 3.1 which has
>>> about 4500 java classes and interfaces.
>>>
>>> For this what I did is a copy of the verveinej.sh shell script
>>> specially tailored to eclipse: I put like you said 'java -Xmx2500m'
>>> and the specific classpath required to parse successfully eclipse.
>>>
>>> If I can have access to your java project, I could try to understand
>>> what is happening....
>>>
>>> Another thing that you can do is trying to import your project in
>>> Eclipse. Since VerveineJ is based on JDT parser, if Eclipse accepts
>>> it, then VerveineJ should accept it too ...
>>>
>>> nicolas
>>>
>>> On Thu, Nov 18, 2010 at 3:47 PM, Fabrizio Perin <[hidden email]> wrote:
>>>> Hi,
>>>> i just try to use VerveineJ to import Java code in moose and i'm not able to make it work: first i tried by command line to use VerveineJ to create the mse of LANModel and it worked. Than i tried to use it with one of my case study and i got: java.lang.OutOfMemoryError: Java heap space.
>>>>
>>>> I tried to modify the script verveinej.sh adding the -Xmx2048m option ( JOPT="-Xmx2048m" ) and it still doesn't work.
>>>>
>>>> Than i tried to use the Moose Wizard and again for the LANModel no problem, but when i tried to import one of my case study i get an error: a message box appear saying that the output.mse file doesn't exist and it ask me to point to an existing file. Apparently verveinej just does not create the file because not able to parse the project and the importer try to go ahead but it does not have any output file from verveinej.
>>>>
>>>> Someone has a similar problem? Am i doing something wrong?
>>>>
>>>> Cheers,
>>>>
>>>> Fabrizio
>>>> _______________________________________________
>>>> Moose-dev mailing list
>>>> [hidden email]
>>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>>>
>>>
>>>
>>>
>>> --
>>> Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod
>>>
>>> _______________________________________________
>>> Moose-dev mailing list
>>> [hidden email]
>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>>
>>
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>
>
>
> --
> Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: VerveineJ out of memory error

anquetil.nicolas
good luck.

If you look, at the main adempiere directory, there is the release and
the contributions.

The first one seems like the "core" package and should be doable for
VerveineJ (about 4500 java files ...

Then you have all the contributions and maybe be some of them are even
redundant between themselves, so they should be analysed on a case by
case basis.

Anyway. Any problem with VerveineJ, don't hesitate to report it back,
we will see what we can do.

nicolas

On Fri, Nov 19, 2010 at 10:58 AM, Fabrizio Perin <[hidden email]> wrote:

> Hi Nicolas,
> thanks really a lot for your time. I will try as you suggest, i will split the program and i will try to parse it one piece at time.
>
> Cheers,
>
> Fabrizio
>
>
>
>
> On 18 Nov 2010, at 17:53, [hidden email] wrote:
>
>> Fabrizio,
>>
>> I believe the project is too big.
>>
>> I have been downloading the source code for the past 90 minutes and
>> it's still not done.
>> I already have close to 20000 java source files.
>>
>> I am afraid it will not be possible to put all this in memory at the same time.
>>
>> The problem is:
>> - the ASTs are all created in memory because to resolve bindings, the
>> parser may need all the entities
>> - on top of that, there is all the Famix Entities that represent the
>> node in the ASTs and have relations one to the other ...
>>
>> So it is a lot of things to keep in memory and for a project this
>> size, I am afraid the java VM will not allow you to have a big enough
>> memory space (on my machine it is limited to about 2.5 G., not by the
>> computer but by the JVM)
>>
>> Anyway, it is not even clear you could then load the resulting MSE in Moose ?!?
>>
>> One could think of doing some kind of "separate compilation" (what the
>> java compiler actually does), but it would be way past my time
>> resources.
>>
>> If it is a solution for you, II can only suggest to divide the whole
>> project into subprojects (something that probably already exist in the
>> source code, I doubt they manage such a big system in only one piece)
>> and deal with the sub-projects separately.
>>
>> nicolas
>>
>> On Thu, Nov 18, 2010 at 4:17 PM, Fabrizio Perin <[hidden email]> wrote:
>>> Hi Nicolas,
>>> well one of that case study that i was trying to import is Adempiere:
>>>
>>> http://sourceforge.net/projects/adempiere/files/
>>>
>>> I will try again with the command line and than i will let you know. Regarding eclipse, well is it not straight import that mess into eclipse in such a way that the code compiles. Anyhow I will try also that way.
>>>
>>> Thanks for the quick answer.
>>>
>>> Cheers,
>>>
>>> Fabrizio
>>>
>>>
>>>
>>> On 18 Nov 2010, at 15:58, [hidden email] wrote:
>>>
>>>> Hi Fabrizio,
>>>>
>>>> Is your project big? I used VerveineJ to parse Eclipse 3.1 which has
>>>> about 4500 java classes and interfaces.
>>>>
>>>> For this what I did is a copy of the verveinej.sh shell script
>>>> specially tailored to eclipse: I put like you said 'java -Xmx2500m'
>>>> and the specific classpath required to parse successfully eclipse.
>>>>
>>>> If I can have access to your java project, I could try to understand
>>>> what is happening....
>>>>
>>>> Another thing that you can do is trying to import your project in
>>>> Eclipse. Since VerveineJ is based on JDT parser, if Eclipse accepts
>>>> it, then VerveineJ should accept it too ...
>>>>
>>>> nicolas
>>>>
>>>> On Thu, Nov 18, 2010 at 3:47 PM, Fabrizio Perin <[hidden email]> wrote:
>>>>> Hi,
>>>>> i just try to use VerveineJ to import Java code in moose and i'm not able to make it work: first i tried by command line to use VerveineJ to create the mse of LANModel and it worked. Than i tried to use it with one of my case study and i got: java.lang.OutOfMemoryError: Java heap space.
>>>>>
>>>>> I tried to modify the script verveinej.sh adding the -Xmx2048m option ( JOPT="-Xmx2048m" ) and it still doesn't work.
>>>>>
>>>>> Than i tried to use the Moose Wizard and again for the LANModel no problem, but when i tried to import one of my case study i get an error: a message box appear saying that the output.mse file doesn't exist and it ask me to point to an existing file. Apparently verveinej just does not create the file because not able to parse the project and the importer try to go ahead but it does not have any output file from verveinej.
>>>>>
>>>>> Someone has a similar problem? Am i doing something wrong?
>>>>>
>>>>> Cheers,
>>>>>
>>>>> Fabrizio
>>>>> _______________________________________________
>>>>> Moose-dev mailing list
>>>>> [hidden email]
>>>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod
>>>>
>>>> _______________________________________________
>>>> Moose-dev mailing list
>>>> [hidden email]
>>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>>>
>>>
>>>
>>> _______________________________________________
>>> Moose-dev mailing list
>>> [hidden email]
>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>>
>>
>>
>>
>> --
>> Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>



--
Nicolas Anquetil        Univ. Lille1 / INRIA-equipe RMod

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev