-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Problems with Hibern8 tools when asm-2.0.jar is in classpath
PostPosted: Fri Mar 31, 2006 8:32 am 
Beginner
Beginner

Joined: Thu Nov 25, 2004 7:07 am
Posts: 43
Location: Germany
Hi,

I use HibernateTools 3.0beta4 to create my POJOs with Hibernate Annotations 3.0beta8. In our project we also use Cobertura which depends on asm-2.0.jar. If I run my ant hibernatetool task to generate the POJOs I get a NoSuchMethodError because asm-2.0.jar doesn't seem to have this method. I think this method is in asm.jar or asm-attr.jar which came with Hibernate Tools 3.0beta4.

Code:
hibernatetool.base:
[hibernatetool] Executing Hibernate Tool with a JDBC Configuration (for reverse engineering)
[hibernatetool] 1. task: generic exporter

BUILD FAILED
java.lang.NoSuchMethodError: org.objectweb.asm.ClassVisitor.visit(IILjava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)V

Total time: 3 seconds


But with these jars (asm.jar and asm-attr.jar) Cobertura doesn't work any more. I tried to exlude asm-2.0.jar in my classpath definition for the hibernatetool task, but it seems to be in the classpath anyway.

Code:
<hibernatetool
  destdir="${hibernatetool.destdir}"
  templatepath="${hibernatetool.template.path}/base_pojo">
    <classpath>
      <pathelement path="${developer.working.directory.classes}" />
        <path refid="lib.external.class.path" />
          <fileset dir="${java.basedir}/lib/meta">
            <patternset>
              <include name="**/*.jar" unless="**/asm-2.0.jar" />
              <include name="**/*.zip" />
              <exclude name="**/Jindent.jar" />
            </patternset>
          </fileset>
    </classpath>
   ....


Is there something wrong in my unless-attribute or a asm-version available which fixes this issue? I already tried asm-2.2.1.jar and asm-3.0.beta.jar but had no success. :-(

Rgds,
Axel

_________________
You'll never get a second chance to make a first impression!


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 31, 2006 11:55 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
I guess you need to ask Cobertura to upgrade their dependencies, since we apparently need that newer methods.

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 03, 2006 2:57 am 
Beginner
Beginner

Joined: Thu Nov 25, 2004 7:07 am
Posts: 43
Location: Germany
max wrote:
I guess you need to ask Cobertura to upgrade their dependencies, since we apparently need that newer methods.


It seems that Cobertura relies on a newer version. I think I'll have to manually delete the asm-2.0.jar when I want to use Hibernate Tools.

_________________
You'll never get a second chance to make a first impression!


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 03, 2006 3:01 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
ah hmm, great asm incompability ;(

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.