-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml not working in unix / linux

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml not working in unix / linux

sridhar thiyagarajan
Hello,

I am using Load Time Weaving of AspectJ API 1.8.6 version in an EAR application. JDK version used is "1.8_51" and wildfly application server version is "8.2.0-Final". I have created a custom module "test.aop" containing META-INF/aop.xml under "$wildfly_home/modules" directory. I have all my aspects in a separate JAR and am maintaining aop.xml in a separate module to have it as configurable. I am referring the module "test.aop" in the EAR classpath.
$wildfly_home

    modules
           test
               aop
                  META-INF
                         aop.xml

-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Using the above VM argument in VM arguments section of application server of eclipse luna made AOP to work fine.

But, I am using the same VM argument in Unix / Linux and it is not working.

Have anyone faced this issue ? Please help me.


Many thanks.


Sridhar Thiyagarajan






_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev
Reply | Threaded
Open this post in threaded view
|

Re: -Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml not working in unix / linux

Andy Clement
-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Isn't your slash backwards for linux/unix usage?

Andy

On 30 July 2015 at 04:20, sridhar thiyagarajan <[hidden email]> wrote:
Hello,

I am using Load Time Weaving of AspectJ API 1.8.6 version in an EAR application. JDK version used is "1.8_51" and wildfly application server version is "8.2.0-Final". I have created a custom module "test.aop" containing META-INF/aop.xml under "$wildfly_home/modules" directory. I have all my aspects in a separate JAR and am maintaining aop.xml in a separate module to have it as configurable. I am referring the module "test.aop" in the EAR classpath.
$wildfly_home

    modules
           test
               aop
                  META-INF
                         aop.xml

-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Using the above VM argument in VM arguments section of application server of eclipse luna made AOP to work fine.

But, I am using the same VM argument in Unix / Linux and it is not working.

Have anyone faced this issue ? Please help me.


Many thanks.


Sridhar Thiyagarajan






_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev
Reply | Threaded
Open this post in threaded view
|

Re: -Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml not working in unix / linux

sridhar thiyagarajan
Many thanks.. Andy. I will verify the same.

Sridhar Thiyagarajan

On Fri, Jul 31, 2015 at 8:48 PM, Andy Clement <[hidden email]> wrote:
-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Isn't your slash backwards for linux/unix usage?

Andy

On 30 July 2015 at 04:20, sridhar thiyagarajan <[hidden email]> wrote:
Hello,

I am using Load Time Weaving of AspectJ API 1.8.6 version in an EAR application. JDK version used is "1.8_51" and wildfly application server version is "8.2.0-Final". I have created a custom module "test.aop" containing META-INF/aop.xml under "$wildfly_home/modules" directory. I have all my aspects in a separate JAR and am maintaining aop.xml in a separate module to have it as configurable. I am referring the module "test.aop" in the EAR classpath.
$wildfly_home

    modules
           test
               aop
                  META-INF
                         aop.xml

-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Using the above VM argument in VM arguments section of application server of eclipse luna made AOP to work fine.

But, I am using the same VM argument in Unix / Linux and it is not working.

Have anyone faced this issue ? Please help me.


Many thanks.


Sridhar Thiyagarajan






_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev
Reply | Threaded
Open this post in threaded view
|

Re: -Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml not working in unix / linux

sridhar thiyagarajan
Hi Andy,

In linux box, -Dorg.aspectj.weaver.loadtime.configuration=META-INF/aop.xml in linux box did not work. So, I added the path containing META-INF/aop.xml in the boot classpath -Xbootclasspath/a:$JBOSS_HOME/modules/com/test/aop/main. With this effect, the LTW agent picks the aop.xml but the corresponding AOP jar containing aspects is not picked (Even I tried adding the jar in boot classpath as well).

ERROR [stderr] (main) [MethodUtil@31c88ec8] error Cannot find parent aspect for: <concrete-aspect name='com.test.it.aop.aspect.DAOOpenAspectImpl' extends='com.test.it.aop.aspect.DAOOpenAspect' perclause='percflow(readDaoPC() || writeDaoPC())'/> in aop.xml
ERROR [stderr] (main) [MethodUtil@31c88ec8] error Concrete-aspect 'com.test.it.aop.aspect.DAOOpenAspectImpl' could not be registered
ERROR [stderr] (main) [MethodUtil@31c88ec8] warning failure(s) registering aspects. Disabling weaver for class loader sun.reflect.misc.MethodUtil@31c88ec8

Could you please let me know whether I am configuring wrong in linux as the same setup works in windows.

Many thanks.

Sridhar Thiyagarajan


On Wed, Aug 5, 2015 at 6:51 PM, sridhar thiyagarajan <[hidden email]> wrote:
Many thanks.. Andy. I will verify the same.

Sridhar Thiyagarajan

On Fri, Jul 31, 2015 at 8:48 PM, Andy Clement <[hidden email]> wrote:
-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Isn't your slash backwards for linux/unix usage?

Andy

On 30 July 2015 at 04:20, sridhar thiyagarajan <[hidden email]> wrote:
Hello,

I am using Load Time Weaving of AspectJ API 1.8.6 version in an EAR application. JDK version used is "1.8_51" and wildfly application server version is "8.2.0-Final". I have created a custom module "test.aop" containing META-INF/aop.xml under "$wildfly_home/modules" directory. I have all my aspects in a separate JAR and am maintaining aop.xml in a separate module to have it as configurable. I am referring the module "test.aop" in the EAR classpath.
$wildfly_home

    modules
           test
               aop
                  META-INF
                         aop.xml

-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Using the above VM argument in VM arguments section of application server of eclipse luna made AOP to work fine.

But, I am using the same VM argument in Unix / Linux and it is not working.

Have anyone faced this issue ? Please help me.


Many thanks.


Sridhar Thiyagarajan






_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev



_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev
Reply | Threaded
Open this post in threaded view
|

Re: -Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml not working in unix / linux

Andy Clement
If you are finding that -Dorg.aspectj.weaver.loadtime.configuration=META-INF/aop.xml  is not working, that suggests classloader delegation/lookup isn’t behaving the same for you on linux as on Windows (or that your packaging process for your apps isn’t the same…). This all kind of points to the same thing if your aspects can’t be found either.

Are you packing your aspect jar into your application jars or trying to reuse them as some common library? If class loader delegation is trying to be too clever then I can only imagine you can solve it by packaging the aspects alongside the app.  There is nothing especially ‘clever’ about aspects, do you find you have the same problem with general references from application code to shared library code? The model for packaging aspect jars could/should follow the same model as shared libraries on JBoss.

cheers,
Andy

On Aug 13, 2015, at 3:40 AM, sridhar thiyagarajan <[hidden email]> wrote:

Hi Andy,

In linux box, -Dorg.aspectj.weaver.loadtime.configuration=META-INF/aop.xml in linux box did not work. So, I added the path containing META-INF/aop.xml in the boot classpath -Xbootclasspath/a:$JBOSS_HOME/modules/com/test/aop/main. With this effect, the LTW agent picks the aop.xml but the corresponding AOP jar containing aspects is not picked (Even I tried adding the jar in boot classpath as well).

ERROR [stderr] (main) [MethodUtil@31c88ec8] error Cannot find parent aspect for: <concrete-aspect name='com.test.it.aop.aspect.DAOOpenAspectImpl' extends='com.test.it.aop.aspect.DAOOpenAspect' perclause='percflow(readDaoPC() || writeDaoPC())'/> in aop.xml
ERROR [stderr] (main) [MethodUtil@31c88ec8] error Concrete-aspect 'com.test.it.aop.aspect.DAOOpenAspectImpl' could not be registered
ERROR [stderr] (main) [MethodUtil@31c88ec8] warning failure(s) registering aspects. Disabling weaver for class loader sun.reflect.misc.MethodUtil@31c88ec8

Could you please let me know whether I am configuring wrong in linux as the same setup works in windows.

Many thanks.

Sridhar Thiyagarajan


On Wed, Aug 5, 2015 at 6:51 PM, sridhar thiyagarajan <[hidden email]> wrote:
Many thanks.. Andy. I will verify the same.

Sridhar Thiyagarajan

On Fri, Jul 31, 2015 at 8:48 PM, Andy Clement <[hidden email]> wrote:
-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Isn't your slash backwards for linux/unix usage?

Andy

On 30 July 2015 at 04:20, sridhar thiyagarajan <[hidden email]> wrote:
Hello,

I am using Load Time Weaving of AspectJ API 1.8.6 version in an EAR application. JDK version used is "1.8_51" and wildfly application server version is "8.2.0-Final". I have created a custom module "test.aop" containing META-INF/aop.xml under "$wildfly_home/modules" directory. I have all my aspects in a separate JAR and am maintaining aop.xml in a separate module to have it as configurable. I am referring the module "test.aop" in the EAR classpath.
$wildfly_home

    modules
           test
               aop
                  META-INF
                         aop.xml

-Dorg.aspectj.weaver.loadtime.configuration=META-INF\aop.xml

Using the above VM argument in VM arguments section of application server of eclipse luna made AOP to work fine.

But, I am using the same VM argument in Unix / Linux and it is not working.

Have anyone faced this issue ? Please help me.


Many thanks.


Sridhar Thiyagarajan






_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-dev