Since commons-codec is an optional dependency of drools-core, it should
be in the classpath of drools-core when it compiles,
so the build error should not occur.
Optional just means that anything that depends on drools-core doesn't
get commons-codec on its classpath as a transitive dependency, except if
the explicitly declare a dependency on it themselves.
Strange that no longer declaring it optional fixes it, must be a maven
2.0.9 quirk. :/
Another strange this is that the version of commons-codec is declared in
drools-core pom.xml, not in depedencyManagement of drools pom.xml.
I 'll fix that.
The drools hudson build uses Maven version: 2.0.10,
but hudson can work with multiple versions of maven.
I believe we should force a minimum version of maven 2.2.1 ASAP,
starting with switching the hudson drools project config (takes about 20
secs if someone got the privileges).
By switching to maven 2.2.1, the transition to maven 3 will be a lot
easier because 2.2.1 warns if we do nonsense (like declare the same
dependency multiple times).
With kind regards,
Geoffrey De Smet
Esteban Aliverti schreef:
That is because commons-codec dependency is set as optional. You need
to
change your pom.xml to this:
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>1.4</version>
<!--scope>optional</scope-->
</dependency>
I had the same issue in core, and I solved it this way.
Best,
On Sat, Mar 27, 2010 at 4:41 AM, Geoffrey De Smet
<ge0ffrey.spam(a)gmail.com <mailto:ge0ffrey.spam@gmail.com>> wrote:
Hi guys
Locally I get compilation error in drools-core, but hudson is also
failing on drools-api.
[INFO]
------------------------------------------------------------------------
[INFO] Building Drools :: Core
[INFO] task-segment: [clean, install]
[INFO]
------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory
/home/ge0ffrey/projects/jboss/drools/drools-core/target
[INFO] [resources:resources]
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 9 resources
[INFO] [compiler:compile]
[INFO] Compiling 1050 source files to
/home/ge0ffrey/projects/jboss/drools/drools-core/target/classes
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Compilation failure
/home/ge0ffrey/projects/jboss/drools/drools-core/src/main/java/org/drools/io/impl/UrlResource.java:[29,38]
package org.apache.commons.codec.binary does not exist
/home/ge0ffrey/projects/jboss/drools/drools-core/src/main/java/org/drools/agent/HttpClientImpl.java:[12,38]
package org.apache.commons.codec.binary does not exist
/home/ge0ffrey/projects/jboss/drools/drools-core/src/main/java/org/drools/io/impl/UrlResource.java:[186,26]
cannot find symbol
symbol : variable Base64
location: class org.drools.io.impl.UrlResource
/home/ge0ffrey/projects/jboss/drools/drools-core/src/main/java/org/drools/agent/HttpClientImpl.java:[54,26]
cannot find symbol
symbol : variable Base64
location: class org.drools.agent.HttpClientImpl
https://hudson.jboss.org/hudson/job/drools/
--
With kind regards,
Geoffrey De Smet
_______________________________________________
rules-dev mailing list
rules-dev(a)lists.jboss.org <mailto:rules-dev@lists.jboss.org>
https://lists.jboss.org/mailman/listinfo/rules-dev
--
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Esteban Aliverti
------------------------------------------------------------------------
_______________________________________________
rules-dev mailing list
rules-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-dev