Okay.  I've got to the end of this, and it's one to raise
regarding Spring Roo (and with the developer that deleted the
tools dependency in our build).

Roo uses version 1.0 of the plugin.

In version 1.3 of the maven aspectj plugin, there is a fix ...
http://jira.codehaus.org/browse/MASPECTJ-74 "Critical failures
reported by ajc (e.g. reweaving already weaved code) are not
handled by the plugin"

This means that if I deliberately configure the plugin as
follows, it does fail.  So.  No fault on AJs part, but cannot see
why 1.0 plugin is used by Roo (including in 1.1.0.M1).

        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>aspectj-maven-plugin</artifactId>
          <version>1.3</version>
          <dependencies>
            <dependency>
              <groupId>org.aspectj</groupId>
              <artifactId>aspectjrt</artifactId>
              <version>1.6.8</version>
              <scope>compile</scope>
            </dependency>
            <dependency>
              <groupId>org.aspectj</groupId>
              <artifactId>aspectjtools</artifactId>
              <version>1.5.4</version>
              <scope>compile</scope>
            </dependency>
          </dependencies>
        </plugin>

Over to Ben on this one.

On Fri, 28 May 2010 09:26 +0100, "Neale Upstone"
<[email protected]> wrote:

Hi,

Just checked on where I originally saw this.  The ajcore
contains:

     warning bad version number found in
/home/systems/.m2/repository/org/aspectj/aspectjrt/1.6.8/aspectjr
t-1.6.8.jar expected 1.5.4 found 1.6.8
...
     abort ABORT -- (BCException) Unable to continue, this
version of AspectJ supports classes built with weaver version 3.0
but the class
org.springframework.beans.factory.aspectj.AbstractBeanConfigurerA
spect is version 6.0
when batch building BuildConfig[null] #Files=9

This certainly looks like it should fail, but doesn't.

Cheers,

Neale


On Thu, 27 May 2010 22:38 +0100, "Neale Upstone"
<[email protected]> wrote:

I note 'only', but at least I now know why the build was still
executing tests correctly.
I wonder if "ERROR] ABORT" is within the maven plugin and
should/could be fixed or clarified.
Cheers,
Neale
On 27/05/2010 21:18, Andy Clement wrote:

I think I've removed that check in recent AspectJs, so the warning
can't happen anymore.  But I can imagine it was still doing it in the
1.5.4 timeframe.  It is 'only' a warning so compilation should
continue - unfortunately it seems to be triggering the ajcore dumper.
If another case comes up of a warning triggering a dump, I'll look
into it.

Andy

On 27 May 2010 08:52, Neale Upstone [1]<[email protected]> wrote:

Ooops.. That would be useful wouldn't it!!

It's incompatible aspectj versions.  The following is logged when doing
a "mvn compile", and I would have thought ABORT would mean we are not
going to continue with the build, but instead the build is reported as
successful.

 [INFO] [aspectj:compile {execution: default}]
 [WARNING] bad version number found in aspectjrt-1.6.8.jar expected
 1.5.4
 found 1.6.8
 ERROR] ABORT
 27-May-2010 16:35:35 org.aspectj.weaver.tools.Jdk14Trace info
 INFO: Dumping to
 C:\Users\Neale\Documents\workspace-sts-2.3.2.RELEASE\tnt-sech-refactor\b
uild\.\ajcore.20100527.163535.991.txt



The cause of the issue is that the plugin is defaulting to the 1.5.4
tools, which is easily solved, by adding the aspectjtools:1.6.8.
        <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>aspectj-maven-plugin</artifactId>
            <version>1.0</version>
            <dependencies>
                <!-- NB: You must use Maven 2.0.9 or above or these
                are ignored (see MNG-2972) -->
                <dependency>
                    <groupId>org.aspectj</groupId>
                    <artifactId>aspectjrt</artifactId>
                    <version>1.6.8</version>
                </dependency>
            </dependencies>
            <executions>
                <execution>
                    <goals>
                        <goal>compile</goal>
                        <goal>test-compile</goal>
                    </goals>
                </execution>
            </executions>
            <configuration>
                <outxml>true</outxml>
                <aspectLibraries>
                    <aspectLibrary>
                        <groupId>org.springframework</groupId>
                        <artifactId>spring-aspects</artifactId>
                    </aspectLibrary>
                </aspectLibraries>
                <source>1.5</source>
                <target>1.5</target>
            </configuration>
        </plugin>



On Thu, 27 May 2010 07:54 -0700, "Andy Clement"
[2]<[email protected]> wrote:

What kind of failure is reported in the ajcore files?

Andy

On 27 May 2010 07:47, Neale Upstone [3]<[email protected]> wrote:

Hi,

Is anyone here familiar with this problem:
- I have a maven build using the Maven aspectJ plugin, which, when
configured correctly works.
- However, if misconfigured, the failure is reported in ajcore files,
but the build still completes (instead of giving a build error)

If anyone has come across this issue, I'd love to know why the build
isn't failing.  It's not that useful in a CI environment.

Cheers,

Neale
--
 Neale Upstone
 [4][email protected]

_______________________________________________
aspectj-users mailing list
[5][email protected]
[6]https://dev.eclipse.org/mailman/listinfo/aspectj-users


_______________________________________________
aspectj-users mailing list
[7][email protected]
[8]https://dev.eclipse.org/mailman/listinfo/aspectj-users


--
 Neale Upstone
 [9][email protected]

_______________________________________________
aspectj-users mailing list
[10][email protected]
[11]https://dev.eclipse.org/mailman/listinfo/aspectj-users


_______________________________________________
aspectj-users mailing list
[12][email protected]
[13]https://dev.eclipse.org/mailman/listinfo/aspectj-users

_______________________________________________
aspectj-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/aspectj-users


--
  Neale Upstone
  [email protected]

_______________________________________________
aspectj-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/aspectj-users

References

1. mailto:[email protected]
2. mailto:[email protected]
3. mailto:[email protected]
4. mailto:[email protected]
5. mailto:[email protected]
6. https://dev.eclipse.org/mailman/listinfo/aspectj-users
7. mailto:[email protected]
8. https://dev.eclipse.org/mailman/listinfo/aspectj-users
9. mailto:[email protected]
  10. mailto:[email protected]
  11. https://dev.eclipse.org/mailman/listinfo/aspectj-users
  12. mailto:[email protected]
  13. https://dev.eclipse.org/mailman/listinfo/aspectj-users
-- 
  Neale Upstone
  [email protected]

_______________________________________________
aspectj-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/aspectj-users

Reply via email to