openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Dick <michael.d.d...@gmail.com>
Subject Re: Enhancer questions/problems
Date Mon, 02 Mar 2009 19:19:32 GMT
Maybe I missed the JIRA you opened, but I ran into this problem again over
the weekend.

FWIW I hit the problem with Ubuntu 8.10, 64 bit with either the IBM SDK or
Sun JDK. I didn't try openjdk.

The problem for me had nothing to do with ant, that was a complete red
herring. It turned out to be due to my own lack of *nix knowledge.

I ran ulimit which returned "unlimited" so I thought I was in good shape. It
turns out that I needed to run "ulimit -n" which returned 1024. This can be
increased by editing /etc/security/limits.conf. A newbie friendly reference
is available at [1].

Increasing the limit resolved the problem for me, YMMV.

[1] http://lj4newbies.blogspot.com/2007/04/too-many-open-files.html

Regards,

-mike

On Thu, Feb 5, 2009 at 6:30 PM, Tim McConnell <tim.mcconne@gmail.com> wrote:

> Hi Mike, thanks for the information. I'll open a JIRA and investigate.....
>
>
> Michael Dick wrote:
>
>> My guess, and it's only that, is that we're hitting an issue with ant. I
>> think it is or is related to this bug :
>> https://issues.apache.org/bugzilla/show_bug.cgi?id=38260.
>>
>> On Linux I've seen similar intermittent problems (mainly with trunk) that
>> show the "too many open files" symptom described in the bugzilla report.
>>
>> I have not seen the errors if I manually update pom.xml to use ant 1.7.0
>> but
>> that might just be luck.
>>
>> Regarding the enhancer there's information in the OpenJPA manual regarding
>> what enhancement does [1]. Regarding the enhancement process during the
>> build I'm not sure why the build doesn't fail after that exception. There
>> might be a bug in the way we're using the antrun maven plugin or a bug in
>> enhancer.xml.. I
>>
>> [1]
>>
>> http://openjpa.apache.org/builds/latest/docs/manual/ref_guide_pc_enhance.html
>>
>> -mike
>>
>> On Thu, Feb 5, 2009 at 4:40 PM, Tim McConnell <tim.mcconne@gmail.com>
>> wrote:
>>
>>  Hi, I notice that occasionally when I build various versions of OpenJPA
>>> (e.g., trunk, branches\1.2.x, tags\1.2.0) the enhance.all.entities ant
>>> step
>>> will getting many numerous ZipException's (see below). So I was just
>>> wondering if anyone knew what might be causing this ?? And why the build
>>> doesn't stop when it does happen ?? I guess I don't yet know enough about
>>> the "enhancer" to fully appreciate/understand what it does, but I would
>>> have
>>> expected the build to fail and stop immediately..... Thanks....
>>>
>>>
>>>
>>> [INFO] [jar:jar]
>>> [INFO] Building jar:
>>>
>>>
>>> C:\SVN\OPENJPA\tags\1.2.0\openjpa-persistence\target\openjpa-persistence-1.2.0.jar
>>> [INFO] [install:install]
>>> [INFO] Installing
>>>
>>>
>>> C:\SVN\OPENJPA\tags\1.2.0\openjpa-persistence\target\openjpa-persistence-1.2.0.jar
>>> to
>>>
>>> C:\M2\org\apache\openjpa\openjpa-persistence\1.2.0\openjpa-persistence-1.2.0.jar
>>> [INFO]
>>> ------------------------------------------------------------------------
>>> [INFO] Building OpenJPA JPA JDBC
>>> [INFO]    task-segment: [install]
>>> [INFO]
>>> ------------------------------------------------------------------------
>>> [INFO] [resources:resources]
>>> [INFO] Using default encoding to copy filtered resources.
>>> [INFO] [compiler:compile]
>>> [INFO] Compiling 65 source files to
>>> C:\SVN\OPENJPA\tags\1.2.0\openjpa-persistence-jdbc\target\classes
>>> [INFO] [resources:testResources]
>>> [INFO] Using default encoding to copy filtered resources.
>>> [INFO] [compiler:testCompile]
>>> [INFO] Compiling 1185 source files to
>>> C:\SVN\OPENJPA\tags\1.2.0\openjpa-persistence-jdbc\target\test-classes
>>> [INFO] [antrun:run {execution: default}]
>>> [INFO] Executing tasks
>>>
>>> enhance:
>>>
>>> enhance.all.entities:
>>>    [echo]  running enhancer
>>> java.util.zip.ZipException: error in opening zip file
>>>       at java.util.zip.ZipFile.open(Native Method)
>>>       at java.util.zip.ZipFile.<init>(ZipFile.java:203)
>>>       at java.util.zip.ZipFile.<init>(ZipFile.java:234)
>>>       at
>>>
>>> org.apache.tools.ant.AntClassLoader.getResourceURL(AntClassLoader.java:919)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.AntClassLoader$ResourceEnumeration.findNextResource(AntClassLoader.java:126)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.AntClassLoader$ResourceEnumeration.nextElement(AntClassLoader.java:109)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.util.CollectionUtils$CompoundEnumeration.nextElement(CollectionUtils.java:146)
>>>       at
>>> sun.misc.CompoundEnumeration.nextElement(CompoundEnumeration.java:43)
>>>       at
>>> org.apache.openjpa.lib.util.Services.getImplementors(Services.java:99)
>>>       at
>>> org.apache.openjpa.lib.util.Services.getImplementors(Services.java:71)
>>>       at
>>>
>>>
>>> org.apache.openjpa.lib.conf.ProductDerivations.<clinit>(ProductDerivations.java:57)
>>>       at
>>>
>>> org.apache.openjpa.conf.BrokerFactoryValue.<clinit>(BrokerFactoryValue.java:50)
>>>       at
>>>
>>>
>>> org.apache.openjpa.conf.OpenJPAConfigurationImpl.<init>(OpenJPAConfigurationImpl.java:188)
>>>       at
>>>
>>>
>>> org.apache.openjpa.conf.OpenJPAConfigurationImpl.<init>(OpenJPAConfigurationImpl.java:164)
>>>       at
>>>
>>>
>>> org.apache.openjpa.conf.OpenJPAConfigurationImpl.<init>(OpenJPAConfigurationImpl.java:155)
>>>       at
>>>
>>> org.apache.openjpa.ant.PCEnhancerTask.newConfiguration(PCEnhancerTask.java:80)
>>>       at
>>>
>>> org.apache.openjpa.lib.ant.AbstractTask.getConfiguration(AbstractTask.java:97)
>>>       at
>>>
>>> org.apache.openjpa.lib.ant.AbstractTask.createConfig(AbstractTask.java:151)
>>>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>>       at
>>>
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>       at
>>>
>>>
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>       at java.lang.reflect.Method.invoke(Method.java:585)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.IntrospectionHelper$CreateNestedCreator.create(IntrospectionHelper.java:1244)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.IntrospectionHelper$Creator.create(IntrospectionHelper.java:1145)
>>>       at
>>> org.apache.tools.ant.UnknownElement.handleChild(UnknownElement.java:549)
>>>       at
>>>
>>> org.apache.tools.ant.UnknownElement.handleChildren(UnknownElement.java:326)
>>>       at
>>> org.apache.tools.ant.UnknownElement.configure(UnknownElement.java:182)
>>>       at
>>>
>>> org.apache.tools.ant.UnknownElement.maybeConfigure(UnknownElement.java:158)
>>>       at org.apache.tools.ant.Task.perform(Task.java:363)
>>>       at org.apache.tools.ant.Target.execute(Target.java:341)
>>>       at org.apache.tools.ant.Target.performTasks(Target.java:369)
>>>       at
>>> org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:37)
>>>       at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
>>>       at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
>>>       at
>>> org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:107)
>>>       at
>>> org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
>>>       at org.apache.tools.ant.Task.perform(Task.java:364)
>>>       at org.apache.tools.ant.Target.execute(Target.java:341)
>>>       at org.apache.tools.ant.Target.performTasks(Target.java:369)
>>>       at
>>> org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
>>>       at
>>>
>>>
>>> org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:37)
>>>       at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
>>>       at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
>>>       at
>>> org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
>>>       at org.apache.tools.ant.Task.perform(Task.java:364)
>>>       at org.apache.tools.ant.Target.execute(Target.java:341)
>>>       at
>>>
>>>
>>> org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:108)
>>>       at
>>> org.apache.maven.plugin.antrun.AntRunMojo.execute(AntRunMojo.java:83)
>>>       at
>>>
>>>
>>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:451)
>>>       at
>>>
>>>
>>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
>>>       at
>>>
>>>
>>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:499)
>>>       at
>>>
>>>
>>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:478)
>>>       at
>>>
>>>
>>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
>>>       at
>>>
>>>
>>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:291)
>>>       at
>>>
>>>
>>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
>>>       at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
>>>       at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
>>>       at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
>>>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>>       at
>>>
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>       at
>>>
>>>
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>       at java.lang.reflect.Method.invoke(Method.java:585)
>>>       at
>>> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>>>       at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>>>       at
>>> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>>>       at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
>>>
>>>
>>> --
>>> Thanks,
>>> Tim McConnell
>>>
>>>
>>>
>>>
>>
> --
> Thanks,
> Tim McConnell
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message