[aspectwerkz-user] RE: Hot Undeployment on Windows - UnsatisfiedLinkError
"Subhrajyoti Bose (subose)" <[email protected]> Wed, 26 Sep 2007 18:34:53 +0530
| Newsgroups | gmane.comp.java.aspectwerkz.user |
|---|---|
| Message-ID | <14F212591546FF4AB98EBFB4D189F06103B233CF@xmb-blr-411.apac.cisco.com> |
------_=_NextPart_001_01C8003D.C3AA75DC Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi Alex =20 Thanks for the pointer. In my first try I was placing the .dll file in PATH. Now I have tried with the folder in PATH. The results remain unchanged. I am still getting the same exception as mentioned below. If I remove it from PATH, the aspectwerkz system fails even before initialization. BTW the exception below says at org.codehaus.aspectwerkz.extension.hotswap.HotSwapClient.hotswap(Native Method). Could it possibly mean that the call to the native method is failing. Am I missing a dependency required for hotswap.=20 =20 I appreciate your time and consideration in this matter. =20 =20 Thanks Subhrajyoti ________________________________ From: Alexandre Vasseur [mailto:[email protected]]=20 Sent: Tuesday, September 25, 2007 2:35 PM To: Subhrajyoti Bose (subose) Cc: [email protected]; [email protected] Subject: Re: Hot Undeployment on Windows - UnsatisfiedLinkError a UnsatisfiedLinkError usually means a .dll or .so is not in the path / classpath (please check but I believe the folder has to be in PATH, possibli LD_PRELOAD and not the .dll/.so itself ie this is NOT like jar files in classpath)=20 Alex On 9/25/07, Subhrajyoti Bose (subose) <[email protected]> wrote:=20 Second Try. Please help. =09 =09 ________________________________ From: Subhrajyoti Bose (subose)=20 Sent: Monday, September 10, 2007 10:29 AM To: '[email protected]' Cc: ' [email protected] <mailto:[email protected]> '; '[email protected]' Subject: Hot Undeployment on Windows - UnsatisfiedLinkError =09 =09 Hi =20 I am using Aspectwerkz-2.0 on Windows. The development environment I am using is java sdk 1.4.2_15. I have a single aspect in my application which I have verified is getting deployed and functioning as desired. I have also verified that aspectwerkz.dll is in the PATH. If I remove it from PATH, the system cribs. I am running a batch file containing the following: =20 @ECHO OFF set ASPECTWERKZ_VERSION=3D2.0 set JAVA_HOME=3DC:\Java\j2sdk1.4.2_15 set ASPECTWERKZ_HOME=3DC:\MySpace\tools\aspectwerkz-2.0 =20 set CP=3D%CLASSPATH% IF "%CP%"=3D=3D"" set CP=3D. =20 @REM Note: you can avoid declaring this since aspectwerkz-x.y.jar comes with a Manifest.mf Class-Path entry set ASPECTWERKZ_LIBS=3D%ASPECTWERKZ_HOME%\lib\dom4j-1.4.jar;%ASPECTWERKZ_HOME= % \lib\qdox-1.4.jar;%ASPECTWERKZ_HOME%\lib\concurrent-1.3.1.jar;%ASPECTWER KZ_HOME%\lib\trove-1.0.2.jar;%ASPECTWERKZ_HOME%\lib\jrexx-1.1.1.jar=20 =20 @REM -cp "%JAVA_HOME%\lib\tools.jar;%ASPECTWERKZ_HOME%\lib\aspectwerkz-core-%ASPE CTWERKZ_VERSION%.jar" org.codehaus.aspectwerkz.hook.ProcessStarter=20 @REM -- Use for Sun HotSpot and IBM JRE -- "%JAVA_COMMAND%" -Xdebug -Xrunaspectwerkz -Xbootclasspath/a:"%ASPECTWERKZ_HOME%\lib\aspectwerkz-core-%ASPECTWERKZ_ VERSION%.jar;%JAVA_HOME%\lib\tools.jar" -cp "%CP%;%ASPECTWERKZ_HOME%\lib\aspectwerkz-extensions-%ASPECTWERKZ_VERSION %.jar;%ASPECTWERKZ_HOME%\lib\aspectwerkz-%ASPECTWERKZ_VERSION%.jar;%ASPE CTWERKZ_HOME%\lib\aspectwerkz-jdk14-%ASPECTWERKZ_VERSION%.jar;%ASPECTWER KZ_LIBS%" %* =20 =09 Hot undeploy of this aspect is failing with exception. The trace is as follows: =20 C:\MySpace\work\monitor\aw-demo\bin>run exec.ProbeManager AspectWerkz> initializing ..... AspectWerkz> ..... done. AspectWerkz - INFO - Pre-processor org.codehaus.aspectwerkz.transform.AspectWerkzPreProcessor loaded and initialized aspect.Aspect Deployer::INFO - undeploying aspect [aspect.Aspect] from class loader [sun.misc.Launcher$AppClassLoader@53ba3d] Exception in thread "main" java.lang.UnsatisfiedLinkError: hotswap at org.codehaus.aspectwerkz.extension.hotswap.HotSwapClient.hotswap(Native Method) at org.codehaus.aspectwerkz.extension.hotswap.HotSwapClient.hotswap(HotSwap Client.java:43) at org.codehaus.aspectwerkz.extension.hotswap.HotSwapRedefiner.redefine(Hot SwapRedefiner.java:32) at org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.redefineIn itialJoinPoints(Deployer.java:464) at org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.doRedefine (Deployer.java:428) at org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.redefine(D eployer.java:416) at org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.undeploy(D eployer.java:368) =20 I am not able to trace the reason for the exception. Could it be due to an old dll file? Or am I missing something in my configuration? If anybody has faced and resolved such problem, please do reply. Any help would be appreciated. =20 =09 =09 Thanks Subhrajyoti ------_=_NextPart_001_01C8003D.C3AA75DC Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=3DContent-Type content=3D"text/html; = charset=3Dus-ascii"> <META content=3D"MSHTML 6.00.2900.3157" name=3DGENERATOR></HEAD> <BODY> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007>Hi Alex</SPAN></FONT></DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007></SPAN></FONT> </DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007>Thanks for the pointer. In my first try I was = placing=20 the .dll file in PATH. Now I have tried with the folder in PATH. The = results=20 remain unchanged. I am still getting the same exception as mentioned = below. If I=20 remove it from PATH, the aspectwerkz system fails even=20 before initialization. BTW the exception below says <FONT = color=3D#ff0000>at=20 org.codehaus.aspectwerkz.extension.hotswap.HotSwapClient.hotswap(Native=20 Method)</FONT>. Could it possibly mean that the call to the = native method=20 is failing. </SPAN></FONT><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007>Am I missing a dependency required for = hotswap.=20 </SPAN></FONT></DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007></SPAN></FONT> </DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007>I appreciate your time and consideration in = this=20 matter.</SPAN></FONT></DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007></SPAN></FONT> </DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007></SPAN></FONT> </DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007>Thanks</SPAN></FONT></DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN=20 class=3D015245812-26092007>Subhrajyoti</SPAN></FONT></DIV><BR> <DIV class=3DOutlookMessageHeader lang=3Den-us dir=3Dltr align=3Dleft> <HR tabIndex=3D-1> <FONT face=3DTahoma size=3D2><B>From:</B> Alexandre Vasseur=20 [mailto:[email protected]] <BR><B>Sent:</B> Tuesday, September 25, 2007 = 2:35=20 PM<BR><B>To:</B> Subhrajyoti Bose (subose)<BR><B>Cc:</B>=20 [email protected]; [email protected]<BR><B>Subject:</B> Re: = Hot=20 Undeployment on Windows - UnsatisfiedLinkError<BR></FONT><BR></DIV> <DIV></DIV>a <FONT face=3DArial><FONT color=3D#ff0000=20 size=3D2><SPAN>UnsatisfiedLinkError </SPAN></FONT></FONT>usually means a = .dll or=20 .so is not in the path / classpath<BR>(please check but I believe the = folder has=20 to be in PATH, possibli LD_PRELOAD and not the .dll/.so itself ie this = is NOT=20 like jar files in classpath) <BR>Alex<BR><BR> <DIV><SPAN class=3Dgmail_quote>On 9/25/07, <B = class=3Dgmail_sendername>Subhrajyoti=20 Bose (subose)</B> <<A = href=3D"mailto:[email protected]">[email protected]</A>>=20 wrote:</SPAN> <BLOCKQUOTE class=3Dgmail_quote=20 style=3D"PADDING-LEFT: 1ex; MARGIN: 0pt 0pt 0pt 0.8ex; BORDER-LEFT: = rgb(204,204,204) 1px solid"> <DIV> <DIV dir=3Dltr align=3Dleft><FONT face=3DArial color=3D#0000ff = size=3D2><SPAN>Second=20 Try. Please help.</SPAN></FONT></DIV><FONT face=3DArial = color=3D#0000ff=20 size=3D2></FONT><BR> <DIV lang=3Den-us dir=3Dltr align=3Dleft> <HR> <FONT face=3DTahoma size=3D2><B>From:</B> Subhrajyoti Bose (subose)=20 <BR><B>Sent:</B> Monday, September 10, 2007 10:29 AM<BR><B>To:</B> '<A = onclick=3D"return top.js.OpenExtLink(window,event,this)"=20 href=3D"mailto:[email protected]"=20 target=3D_blank>[email protected]</A>'<BR><B>Cc:</B> '<A=20 onclick=3D"return top.js.OpenExtLink(window,event,this)"=20 href=3D"mailto:[email protected]" target=3D_blank> = [email protected]</A>'; '<A=20 onclick=3D"return top.js.OpenExtLink(window,event,this)"=20 href=3D"mailto:[email protected]"=20 target=3D_blank>[email protected]</A>'<BR><B>Subject:</B> Hot = Undeployment on=20 Windows - UnsatisfiedLinkError<BR></FONT><BR></DIV> <DIV></DIV> <DIV><SPAN><FONT face=3DArial size=3D2>Hi</FONT></SPAN></DIV> <DIV><SPAN><FONT face=3DArial size=3D2></FONT></SPAN> </DIV> <DIV><SPAN><FONT face=3DArial size=3D2>I am using Aspectwerkz-2.0 on = Windows. The=20 development environment I am using is </FONT></SPAN><SPAN><FONT = face=3DArial=20 size=3D2>java sdk 1.4.2_15. I have a single aspect in my application = which I=20 have verified is getting deployed and functioning as desired. I have = also=20 verified that</FONT></SPAN><FONT face=3DArial><FONT = size=3D2><SPAN>=20 aspectwerkz.dll is in the PATH. If I remove it from PATH, the system = cribs. I=20 am running a batch file containing the = following:</SPAN></FONT></FONT></DIV> <DIV><FONT face=3DArial><FONT = size=3D2><SPAN></SPAN></FONT></FONT> </DIV> <DIV><FONT face=3DArial><FONT color=3D#0000ff size=3D2><SPAN>@ECHO = OFF<BR>set=20 ASPECTWERKZ_VERSION=3D2.0<BR>set = JAVA_HOME=3DC:\Java\j2sdk1.4.2_15<BR>set=20 = ASPECTWERKZ_HOME=3DC:\MySpace\tools\aspectwerkz-2.0</SPAN></FONT></FONT><= /DIV> <DIV><FONT color=3D#0000ff></FONT> </DIV> <DIV><FONT face=3DArial><FONT color=3D#0000ff size=3D2><SPAN>set=20 CP=3D%CLASSPATH%<BR>IF "%CP%"=3D=3D"" set = CP=3D.</SPAN></FONT></FONT></DIV> <DIV><FONT color=3D#0000ff></FONT> </DIV> <DIV><FONT face=3DArial><FONT color=3D#0000ff size=3D2><SPAN>@REM = Note: you can=20 avoid declaring this since aspectwerkz-x.y.jar comes with a = Manifest.mf=20 Class-Path entry<BR>set=20 = ASPECTWERKZ_LIBS=3D%ASPECTWERKZ_HOME%\lib\dom4j-1.4.jar;%ASPECTWERKZ_HOME= %\lib\qdox-1.4.jar;%ASPECTWERKZ_HOME%\lib\concurrent-1.3.1.jar;%ASPECTWER= KZ_HOME%\lib\trove-1.0.2.jar;%ASPECTWERKZ_HOME%\lib\jrexx-1.1.1.jar</SPAN= ></FONT>=20 </FONT></DIV> <DIV><FONT color=3D#0000ff></FONT> </DIV> <DIV><FONT face=3DArial><FONT size=3D2><SPAN><FONT = color=3D#0000ff>@REM -cp=20 = "%JAVA_HOME%\lib\tools.jar;%ASPECTWERKZ_HOME%\lib\aspectwerkz-core-%ASPEC= TWERKZ_VERSION%.jar"=20 org.codehaus.aspectwerkz.hook.ProcessStarter <BR>@REM -- Use for Sun = HotSpot=20 and IBM JRE --<BR>"%JAVA_COMMAND%" -Xdebug -Xrunaspectwerkz=20 = -Xbootclasspath/a:"%ASPECTWERKZ_HOME%\lib\aspectwerkz-core-%ASPECTWERKZ_V= ERSION%.jar;%JAVA_HOME%\lib\tools.jar"=20 -cp=20 = "%CP%;%ASPECTWERKZ_HOME%\lib\aspectwerkz-extensions-%ASPECTWERKZ_VERSION%= .jar;%ASPECTWERKZ_HOME%\lib\aspectwerkz-%ASPECTWERKZ_VERSION%.jar;%ASPECT= WERKZ_HOME%\lib\aspectwerkz-jdk14-%ASPECTWERKZ_VERSION%.jar;%ASPECTWERKZ_= LIBS%"=20 %*</FONT> <BR></SPAN></FONT></FONT></DIV> <DIV><FONT face=3DArial><FONT size=3D2><SPAN>Hot undeploy of this = aspect is=20 failing with exception. The trace is as=20 follows:</SPAN></FONT></FONT></DIV> <DIV><FONT face=3DArial><FONT = size=3D2><SPAN></SPAN></FONT></FONT> </DIV> <DIV><FONT face=3DArial><FONT color=3D#ff0000=20 size=3D2><SPAN>C:\MySpace\work\monitor\aw-demo\bin>run=20 exec.ProbeManager<BR>AspectWerkz> initializing = .....<BR>AspectWerkz>=20 ..... done.<BR>AspectWerkz - INFO - Pre-processor=20 org.codehaus.aspectwerkz.transform.AspectWerkzPreProcessor loaded and=20 initialized<BR>aspect.Aspect<BR>Deployer::INFO - undeploying aspect=20 [aspect.Aspect] from class loader=20 [sun.misc.Launcher$AppClassLoader@53ba3d]<BR>Exception in thread = "main"=20 java.lang.UnsatisfiedLinkError:=20 hotswap<BR> at=20 = org.codehaus.aspectwerkz.extension.hotswap.HotSwapClient.hotswap(Native=20 Method)<BR> at=20 = org.codehaus.aspectwerkz.extension.hotswap.HotSwapClient.hotswap(HotSwapC= lient.java:43)<BR> =20 at=20 = org.codehaus.aspectwerkz.extension.hotswap.HotSwapRedefiner.redefine(HotS= wapRedefiner.java:32)<BR> =20 at=20 = org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.redefineIni= tialJoinPoints(Deployer.java:464)<BR> = =20 at=20 = org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.doRedefine(= Deployer.java:428)<BR> =20 at=20 = org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.redefine(De= ployer.java:416)<BR> =20 at=20 = org.codehaus.aspectwerkz.transform.inlining.deployer.Deployer.undeploy(De= ployer.java:368)</SPAN></FONT></FONT></DIV> <DIV><SPAN><FONT face=3DArial color=3D#ff0000 = size=3D2></FONT></SPAN> </DIV> <DIV><SPAN><FONT face=3DArial size=3D2>I am not able to trace the = reason for the=20 exception. Could it be due to an old dll file? Or am I missing = something=20 in my configuration? If anybody has faced and resolved such = problem,=20 please do reply. Any help would be appreciated.</FONT></SPAN></DIV> <DIV><SPAN><FONT face=3DArial = size=3D2></FONT></SPAN> </DIV><SPAN> <DIV><FONT face=3DArial size=3D2></FONT><BR><FONT face=3DArial=20 size=3D2>Thanks</FONT></DIV> <DIV><SPAN><FONT face=3DArial=20 size=3D2>Subhrajyoti</FONT></SPAN></DIV></SPAN></DIV></BLOCKQUOTE></DIV><= BR></BODY></HTML> ------_=_NextPart_001_01C8003D.C3AA75DC--