You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by contactreji <co...@gmail.com> on 2013/08/29 06:39:02 UTC

Camel maven build error - External jar dependency

Hi 

I am trying to make a camel project which checks a failover database and
sends a alert email every night.

I am using a java bean class to send the email. I have added all the Java
Mail APIs to the buildpath->Add External Archives.

I have unit tested the Java email sending class.

But when I build the camel project, the error occurs as follows

[INFO] 16 errors 
[INFO] -------------------------------------------------------------
[INFO]
------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 4.848s
[INFO] Finished at: Thu Aug 29 07:34:30 EEST 2013
[INFO] Final Memory: 10M/77M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-compiler-plugin:2.5.1:compile
(default-compile) on project fuse-reporting: Compilation failure:
Compilation failure:
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[4,0]
package javax.mail does not exist
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[5,0]
package javax.mail.internet does not exist
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[37,2]
cannot find symbol
[ERROR] symbol  : class Session
[ERROR] location: class com.outotec.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\outotec\fuse\reporting\SendEmail.java:[38,8]
cannot find symbol
[ERROR] symbol  : class Authenticator
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[37,20]
cannot find symbol
[ERROR] symbol  : variable Session
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[49,3]
cannot find symbol
[ERROR] symbol  : class MimeMessage
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[49,29]
cannot find symbol
[ERROR] symbol  : class MimeMessage
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[52,23]
cannot find symbol
[ERROR] symbol  : class InternetAddress
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\outotec\fuse\reporting\SendEmail.java:[55,31]
package Message does not exist
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\outotec\fuse\reporting\SendEmail.java:[55,54]
cannot find symbol
[ERROR] symbol  : class InternetAddress
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\outotec\fuse\reporting\SendEmail.java:[65,3]
cannot find symbol
[ERROR] symbol  : class BodyPart
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[65,34]
cannot find symbol
[ERROR] symbol  : class MimeBodyPart
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\company\fuse\reporting\SendEmail.java:[73,3]
cannot find symbol
[ERROR] symbol  : class Multipart
[ERROR] location: class com.company.fuse.reporting.SendEmail
[ERROR]
D:\Project\Reji\fuse-reporting\src\main\java\com\outotec\fuse\reporting\SendEmail.java:[73,29]
cannot find symbol
[ERROR] symbol  : class MimeMultipart
[ERROR] location: class com.company.fuse.reporting.SendEmail



Do we have to add the external JAVA APIS in some other way into the project? 
Any ideas will be helpful for me

Reji




--
View this message in context: http://camel.465427.n5.nabble.com/Camel-maven-build-error-External-jar-dependency-tp5738185.html
Sent from the Camel - Users mailing list archive at Nabble.com.

AW: Camel maven build error - External jar dependency

Posted by "Jan Matèrne (jhm)" <ap...@materne.de>.
> I am using a java bean class to send the email. I have added all the
> Java Mail APIs to the buildpath->Add External Archives.

This make me think you are using Eclipse.


> [INFO] 16 errors

This make me think you are building with Maven.

So add the jars as dependencies in your pom.xml and run Maven with
additional goal eclipse:eclipse. So you "add your jars" to Maven and Maven
"adds the jars" to Eclipse.


Jan