Tomcat can not open sjsxp-1.0.2.jar - maven

I have a maven project. And i am compiling intellij idea 13 without problems but i want to build in jenkins /home/tomcat/.m2/repository/com/sun/xml/stream/sjsxp/1.0.2/sjsxp-1.0.2.jar; error in opening zip file
this exception occur jenkins console. Anybody can help me ?
Thank you.
My maven dependency
<dependency>
<groupId>com.sun.xml.stream</groupId>
<artifactId>sjsxp</artifactId>
<version>1.0.2</version>
</dependency>
Thank you so much.

That typically means that the jar file has somehow been corrupt. Try deleting /home/tomcat/.m2/repository/com/sun/xml/stream/sjsxp/1.0.2/sjsxp-1.0.2.jar on the Jenkins-server and rerun the build.

Related

How to incorporate BIRT 4.9.0 into POM?

Scenario:
I am refactoring my application to work under java 17. Birt runtime 3.7.x is embedded in my application.
In updating to point to birt 4.9.0, I have updated my pom as follows:
<dependency>
<groupId>org.eclipse.birt</groupId>
<artifactId>birt-runtime</artifactId>
<version>4.9.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.eclipse.birt/birt-runtime-osgi -->
<dependency>
<groupId>org.eclipse.birt</groupId>
<artifactId>birt-runtime-osgi</artifactId>
<version>4.9.0</version>
</dependency>
When I build, I get the exception
org.eclipse.birt:birt-runtime:jar:4.9.0 was not found in https://repo1.maven.org/maven2 during a previous attempt
I have deleted and rebuilt my local .m2 directory.
When I dig around the maven repository I find the file at https://repo1.maven.org/maven2/org/eclipse/birt/birt-runtime/4.9.0/
This link (BiRT latest Runtime as one Maven Dependency for Eclipse) was resolved by manually downloading the file and pointing to a local copy. I'd prefer to avoid that, since Maven is all about avoiding that kind of scenario.
I suspect there's something in the maven path I am missing.
Thank you in advance.

How to resolve lombok error "log cannot be resolved"?

I have errors in the project (springboot) with all code "log." I have followed the advise from the link below (in my case using eclipse with spring tools):
enter link description here
I spent 2 hours delete the project and reopen, clean, build everything and nothing working. I also did mvn compile from command line and this seem to work fine, so it's clearly eclipse problem.
code from pom:
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<optional>true</optional>
</dependency>
Eclipse ini file:
I run the jar (java application) and specify the ini file. The jar is added
to the eclispe directory but it has no version on it.
Also lombok should appeared in the eclipse about screen and it's not.
Thanks.
In order to solve this problem I had to use STS4 and the same indtallation
for eclpise is work for STS.
lombok is added to the about screen, all good now.

Failed to add RXjava dependency from pom file in intellij

I tried to open a maven project with Intellij. The project was originally created on eclipse and worked fine.
However I receive an error
Dependency 'io.reactivex.rxjava2:rxjava:2.2.19' not found
(I get the same error if I try to start a new project in Intellij with the rxjava dependency)
Here is my dependencies section in the POM file:
<dependencies>
<dependency>
<groupId>io.reactivex.rxjava2</groupId>
<artifactId>rxjava</artifactId>
<version>2.2.19</version>
</dependency>
</dependencies>
What am I doing wrong?
running
mvn clean install
from command line, solved the issue

ReflectionToStringBuilder errors in Maven Project

Some of my Roo generated .aj files seem to be generating errors as below. I can see commons-lang3-3.1.jar in my Maven Dependencies. I have added this to my pom.xml
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.1</version>
</dependency>
Failed to execute goal
org.codehaus.mojo:aspectj-maven-plugin:1.2:compile (default) on
project AdminDirect-Model: Compiler errors : [ERROR] error at return
ReflectionToStringBuilder.toString(this,
ToStringStyle.SHORT_PREFIX_STYLE);
I have a multi-module project, and when in STS I try to do a right click and Update Project, I get another annoying error saying "Problems Encountered while setting project description"...although this is probably a separate issue.
As an aside if anyone knows of the correct workflow to create a multi-module spring roo, JSF, JPA application (Model and Web tier under a parent module) that would be greatly appreciated.
I deleted the .m2/repository folder contents and forced a fresh download using Maven Update Project and then forced a refresh of snapshots. Seems to work, jars must have been corrupt?
tomcat server fails to start the server and application in STS

How to run Spring Samples?

I check out mvc-ajax project into eclipse from this svn address
https://src.springframework.org/svn/spring-samples
and run it on server,but got the following error:
org.apache.jasper.JasperException: Unable to read TLD "META-INF/c.tld" from JAR file "file:/home/tom/source/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/mvc-ajax/WEB-INF/lib/jstl-1.2.jar": org.apache.jasper.JasperException: Failed to load or instantiate TagLibraryValidator class: org.apache.taglibs.standard.tlv.JstlCoreTLV
at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51)
at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409)
at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:181)
at org.apache.jasper.compiler.TagLibraryInfoImpl.(TagLibraryInfoImpl.java:182)
at org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:383)
at org.apache.jasper.compiler.Parser.parseDirective(Parser.java:446)
Eclipse: Build Path -> Configure Build Path -> Libraries -> Add Library -> Server Runtime.
Then choose your server.
You are missing the c.tld taglib. Make sure you deploy it.
I was unable to reproduce this problem so this is a shot in the dark, but I often find I can fix unexpected deployment issues by cleaning my tomcat instance in Eclipse. Right click tomcat in your Servers view, and select Clean...
I can fix this issue by remove jsp-api.jar.
Not sure this is the best solution
I think I found a solution to the problem you were facing, while trying to solve mine.
This post proposes to comment the following dependences (due to problems with eclipse):
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.5</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet.jsp</groupId>
<artifactId>jsp-api</artifactId>
<version>2.1</version>
<scope>provided</scope>
</dependency>
Kind Regards,
Despot
Even I too was facing the same problem while deploying into tomcat 6 server. I solved it by copying the jstl-1.2.jar into tomcat lib folder and solved.

Resources