Re: [aspectwerkz-user] JVM crash with prepared bootclasspath weaving (Modified by Kenji Nakamura)
Kenji Nakamura <[email protected]> Wed, 25 May 2005 08:57:34 -0700
| Newsgroups | gmane.comp.java.aspectwerkz.user |
|---|---|
| Message-ID | <[email protected]> |
Alex,
I'll consider switching to JRockit, but won't happen in short term so I
still need to explore the issue.
I tested your mocked preprocessor, and worked fine with/wo
System.arraycopy().
I don't understand why working fine with the mock leads to the
conclusion that the cause of the problem is not in preprocessor. I
guess something wrong happen in the difference between the mock
preprocessor and the real one since all of other environments are
identical...
Thanks,
-Kenji
On May 24, 2005, at 6:17 AM, Alexandre Vasseur wrote:
> I have 2 suggestions
>
> 1/ use JRockit and our JRockit agent instead of the prepared
> bootclasspath option. See docs.
>
> 2/ If you use the prepared bootclasspath and want to dig more when
> using the Sun VM, startup the app with:
> -Daspectwerkz.classloader.preprocessor=alex.Pre
>
> with the following class, and with it compiled and put in your
> bootclasspath/a
>
>
> This class won't weave anything but if everything runs fine with that
> (and with the System.arrayCopy version - see below), this means the
> problem is somewhere else)
>
>
> package alex;
>
> import org.codehaus.aspectwerkz.hook.ClassPreProcessor;
>
> public class Pre implements ClassPreProcessor {
> public void initialize() {
> return;
> }
>
> public byte[] preProcess(String klass, byte[] abyte, ClassLoader
> caller) {
> System.out.println(klass);//take care, klass can be null
>
> return abyte;
>
> // change to that to stress the VM some more perhaps
> // byte[] b = new byte[abyte.length];
> // System.arraycopy(abyte, 0, b, 0, abyte.length);
> // return b;
>
> }
> }
>
>
>
>
> On 5/23/05, Kenji Nakamura <[email protected]> wrote:
>> Mindstorm,
>>
>> Here is the launch parameters. It is taken from OS X, but parameters
>> are identical in Windows.
>> We use classworld to compose boot-up classpath, and our Main class
>> calls JBoss's main.
>>
>> I also noticed the problem keeps happening even after I switch back
>> JAVA_HOME to _08.
>> I was wondering if old version of DLLs were included in Path so that I
>> uninstalled 1.4.2_01, but the crash didn't go away.
>>
>>
>> + exec /System/Library/Frameworks/JavaVM.framework/Home/bin/java
>> -Xbootclasspath/p:/Users/kenjin/repository/companydepot/app/main/
>> assembly/app-dev/target/assembly/lib/aw_enhanced_tools.jar
>> -Xbootclasspath/a:/Users/kenjin/repository/companydepot/app/main/
>> assembly/app-dev/target/assembly/lib/aspectwerkz-core.jar
>> -server
>> -Xms256m -Xmx512m
>> -classpath
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/aspectwerkz.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/aspectwerkz-jdk14.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/dom4j.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/qdox.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/concurrent.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/trove.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/jrexx.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/lib/classworlds.jar:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly/jboss/bin/run.jar
>> -Dprogram.name=app
>> -Dclassworlds.conf=/Users/kenjin/repository/companydepot/app/main/
>> assembly/app-dev/target/assembly/etc/app-boot.conf
>> -Dapp.home=/Users/kenjin/repository/companydepot/app/main/assembly/
>> app-
>> dev/target/assembly
>> -Djava.endorsed.dirs=/Users/kenjin/repository/companydepot/app/main/
>> assembly/app-dev/target/assembly/lib/endorsed
>> -Dapp.jboss.config=app
>> -Daspectwerkz.transform.details=true
>> -Dapp.config=app.properties
>> -Dlog4j.configuration=log4j-boot.properties
>> -Daspectwerkz.transform.verbose=false
>> org.codehaus.classworlds.Launcher
>> AspectWerkz - INFO - Pre-processor
>> org.codehaus.aspectwerkz.transform.AspectWerkzPreProcessor loaded and
>> initialized
>> 08:06:48,361 INFO [AppMain] Booting Company App Server...
>> 08:06:48,362 INFO [AppMain] Version: @app.version@ (@app.timestamp@)
>> 08:06:48,370 INFO [AppMain] App Home Dir:
>> /Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/
>> assembly
>> 08:06:48,371 INFO [AppMain] App Home URL:
>> file:/Users/kenjin/repository/companydepot/app/main/assembly/app-dev/
>> target/assembly/
>> 08:06:48,372 INFO [AppMain] App JBoss Config: app
>> 08:06:48,372 INFO [AppMain] App Binding Config: app
>> 08:06:48,373 INFO [AppMain] Launching JBoss...
>> 08:06:48,373 INFO [AppMain] [0] --config=app
>> 08:06:48,754 INFO [Server] Starting JBoss (MX MicroKernel)...
>> 08:06:48,754 INFO [Server] Release ID: JBoss [WonderLand] 3.2.6
>> (build: CVSTag=JBoss_3_2_6 date=200410140106)
>>
>>
>> On May 20, 2005, at 4:04 PM, Alexandru Popescu wrote:
>>
>>> #: on behalf of Kenji Nakamura :: 5/20/2005 6:55 PM :#
>>>> Alex,
>>>>
>>>> I also turned on details flag in the server log, but since there is
>>>> no
>>>> aspect definition in aop.xml,
>>>> nothing displayed in the log. I removed the entry to narrow down the
>>>> cause of the problem.
>>>> Once I get rid of bootclasspath entries for enhanced jar and AW
>>>> jars,
>>>> the problem disappears so that
>>>> I think either enhanced jar or AW jar causes the issue.
>>>>
>>>> If it is not known issue, that's fine, and I can simply note our
>>>> system
>>>> requires Sun JDK1.4.2_05 or above.
>>>> However, this brings another concern regarding the fact that I also
>>>> need to support IBM JDK 1.4.2 for WebSphere.
>>>> So far I haven't had time to test on it, but has anyone tried
>>>> enhance
>>>> jar weaving with IBM JDK?
>>>>
>>>> Thanks,
>>>>
>>>> -Kenji
>>>>
>>>>
>>>> On May 20, 2005, at 9:47 AM, Alexandre Vasseur wrote:
>>>>
>>>>> Hi
>>>>>
>>>>> You may check how the memory is going perhaps
>>>>> The thing is that it is obvious that the server starts up to a
>>>>> point
>>>>> where it crash, which means that the enhanced.jar is not at all in
>>>>> cause. The jar you provided thru this link is fine.
>>>>> But there might be some other reasons
>>>>> Actually turning on the -Daspectwerkz.transform.details=true would
>>>>> help to see where the aspects are applied exactly.
>>>>>
>>>>> Alex
>>>>>
>>>>> On 5/20/05, Kenji Nakamura <[email protected]> wrote:
>>>>>> Alex,
>>>>>> I uploaded the screenshot, enhanced jar, server log with AW
>>>>>> verbose
>>>>>> option, and the text file that is supposed to be sent out to
>>>>>> Microsoft
>>>>>> with the crash report. You should be able to download them from
>>>>>> http://www.clazzsoft.com/aw/
>>>>>>
>>>>>> Error report contains the list of DLLs loaded into JVM process,
>>>>>> and
>>>>>> memory dump. That information is not selectable so I can't copy
>>>>>> and
>>>>>> paste.
>>>>>>
>>>>>> Please note that JBoss boot up process continued even after the
>>>>>> error
>>>>>> panel popped up. I also attach the server log with AW verbose
>>>>>> option
>>>>>> on.
>>>>>>
>>>>>> Thanks,
>>>>>>
>>>>>> -Kenji
>>>>>>
>>>>>> On May 20, 2005, at 8:49 AM, Alexandre Vasseur wrote:
>>>>>>
>>>>>>> could you send me the enhanced.jar you obtain when running those
>>>>>>> vm
>>>>>>> crash information (screenshot of the panel ?) would help a lot as
>>>>>>> well
>>>>>>> You can send those to me directly.
>>>>>>> Alex
>>>>>>>
>>>>>>> On 5/20/05, Kenji Nakamura <[email protected]> wrote:
>>>>>>>> Forgot to mention about AW version.
>>>>>>>> I use AW-2.0 with the patch to get rid of JDK dependency from
>>>>>>>> Plug
>>>>>>>> (MAIN:avasseur:20050513073502)
>>>>>>>>
>>>>>>>> Thanks,
>>>>>>>>
>>>>>>>> -kenji
>>>>>>>>
>>>>>>>> On May 20, 2005, at 8:28 AM, Kenji Nakamura wrote:
>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> My colleagues reported JVM crash on application startup with
>>>>>>>>> old
>>>>>>>>> revisions of Sun JDK1.4.2 on Windows XP pro.
>>>>>>>>> I use prepared bootclasspath weaving, and confirmed enhanced
>>>>>>>>> jar
>>>>>>>>> is
>>>>>>>>> generated with the same JDK.
>>>>>>>>> Our application uses Jboss3.2.6 as the platform. It crashes
>>>>>>>>> even
>>>>>>>>> when
>>>>>>>>> aop.xml doesn't have any aspect definition.
>>>>>>>>>
>>>>>>>>> I confirmed it crashes on Sun JDK1.4.2_01, 03 and 04 on
>>>>>>>>> Windows.
>>>>>>>>> 05,
>>>>>>>>> 07, and 08 are fine.
>>>>>>>>> Unfortunately, I cannot copy and paste the JVM crash details
>>>>>>>>> appeared
>>>>>>>>> in the crash panel.
>>>>>>>>>
>>>>>>>>> Is this a known issue?
>>>>>>>>>
>>>>>>>>> Thanks,
>>>>>>>>>
>>>>>>>>> -Kenji
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> What params do you use for starting JBoss JVM?
>>>
>>> :alex |.::the_mindstorm::.|
>>>
>>>
>>
>>
>
>