Hadoop Jersey 1 x injection which is now not supported by Weblogic 12C

+2 votes

On J2EE project and weblogic 10.3.4 servers we are using Apache Hadoop e.g: Hadoop hdfs and Hadoop commons jar, these hadoop jars are injecting com.sun.jersey dependency. Now we are migrating from weblogic 10.3.4 to weblogic 12.2.1 servers which is deprecated in weblogic 12C, So I am getting below error while publishing(Deploying) my EAR on 12C servers :-

java.lang.Exception: Exception received from deployment driver. See Error Log view for more detail. at
oracle.eclipse.tools.weblogic.server.internal.DeploymentProgressListener.watch(DeploymentProgressListener.java:193)
at oracle.eclipse.tools.weblogic.server.internal.WlsJ2EEDeploymentHelper.redeploy(WlsJ2EEDeploymentHelper.java:686)
at oracle.eclipse.tools.weblogic.server.internal.WlsJ2EEDeploymentHelper.deploy(WlsJ2EEDeploymentHelper.java:495) at
oracle.eclipse.tools.weblogic.server.internal.WeblogicServerBehaviour.publishWeblogicModules(WeblogicServerBehaviour.java:1486) at
oracle.eclipse.tools.weblogic.server.internal.WeblogicServerBehaviour.publishToServer(WeblogicServerBehaviour.java:944) at
oracle.eclipse.tools.weblogic.server.internal.WeblogicServerBehaviour.publishOnce(WeblogicServerBehaviour.java:735) at oracle.eclipse.tools.weblogic.server.internal.WeblogicServerBehaviour.publish(WeblogicServerBehaviour.java:584)
at org.eclipse.wst.server.core.model.ServerBehaviourDelegate.publish(ServerBehaviourDelegate.java:774) at
org.eclipse.wst.server.core.internal.Server.publishImpl(Server.java:3172) at org.eclipse.wst.server.core.internal.Server$PublishJob.run(Server.java:345) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55) 
Caused by: weblogic.application.ModuleException: org.glassfish.jersey.server.model.ModelValidationException: Validation of the application resource model has failed
during application initialization. [[WARNING] The (sub)resource method getRoot in
org.apache.hadoop.hdfs.server.namenode.web.resources.NamenodeWebHdfsMethods contains empty path annotation.;
source='public javax.ws.rs.core.Response
org.apache.hadoop.hdfs.server.namenode.web.resources.NamenodeWebHdfsMethods.getRoot(org.apache.hadoop.security.UserGroupInformation,org.apache.hadoop.hdfs.web.resources.DelegationParam,org.apache.hadoop.hdfs.web.resources.UserParam,org.apache.hadoop.hdfs.web.resources.DoAsParam,org.apache.hadoop.hdfs.web.resources.GetOpParam,org.apache.hadoop.hdfs.web.resources.OffsetParam,org.apache.hadoop.hdfs.web.resources.LengthParam,org.apache.hadoop.hdfs.web.resources.RenewerParam,org.apache.hadoop.hdfs.web.resources.BufferSizeParam) throws
java.io.IOException,java.net.URISyntaxException,java.lang.InterruptedException', [WARNING] The (sub)resource method
putRoot in org.apache.hadoop.hdfs.server.namenode.web.resources.NamenodeWebHdfsMethods contains empty path
annotation.; source='public javax.ws.rs.core.Response

Few solutions which I have already tried and tested but failed to get desired result:-
1)I have searched for latest versions of these Apache Hadoop jars, but they all inject jersey dependency version 1.x.
2)Have added this to weblogic-application.xml
<prefer-application-packages>
<package-name>com.sun.jersey.*</package-name>
</prefer-application-packages>
3)Have added the Shared Libraries to weblogic domain with all required jersey 1.x jars.

Please help as we are not able to reach any conclusive solution.

Oct 31, 2018 in Big Data Hadoop by Aparna
• 140 points

edited Oct 31, 2018 by Omkar 1,128 views

1 answer to this question.

0 votes

Add these lines to your weblogic-application.xml file and see if it works:

<weblogic-application>
<prefer-application-packages>
<package-name>com.sun.jersey.*</package-name> 
<package-name>org.glassfish.jersey.*</package-name>
<package-name>jersey.repackaged.org.objectweb.asm.*</package-name>
<package-name>com.sun.research.ws.wadl.*</package-name>
<package-name>com.sun.ws.rs.ext.*</package-name>
</prefer-application-packages> 
</weblogic-application>
answered Oct 31, 2018 by Omkar
• 69,210 points

Related Questions In Big Data Hadoop

0 votes
1 answer

What is Shared Edit Logs in case of Stand By Name Node in Hadoop 2.x?

Yes, Shared Edit Logs exist in case ...READ MORE

answered Jun 19, 2019 in Big Data Hadoop by Hansini
2,577 views
0 votes
1 answer

Which of the following is not a hadoop output format?

The Hadoop Output Format checks the Output ...READ MORE

answered Dec 20, 2021 in Big Data Hadoop by Kavya
• 700 points
1,358 views
0 votes
1 answer

Which latest Hadoop version is stable?

Try Checking this website: http://hadoop.apache.org/releases.html. Here you will ...READ MORE

answered Mar 26, 2018 in Big Data Hadoop by nitinrawat895
• 11,380 points
4,915 views
0 votes
1 answer

Not able to start Job History Server in Hadoop 2.8.1

You have to start JobHistoryServer process specifically ...READ MORE

answered Mar 30, 2018 in Big Data Hadoop by Ashish
• 2,650 points
2,315 views
0 votes
1 answer

Moving files in Hadoop using the Java API?

I would recommend you to use FileSystem.rename(). ...READ MORE

answered Apr 15, 2018 in Big Data Hadoop by Shubham
• 13,490 points
2,470 views
0 votes
1 answer

What is the command to find the free space in HDFS?

You can use dfsadmin which runs a ...READ MORE

answered Apr 29, 2018 in Big Data Hadoop by Shubham
• 13,490 points
1,862 views
0 votes
1 answer

Hadoop giving java.io.IOException, in mkdir Java code.

I am not sure about the issue. ...READ MORE

answered May 3, 2018 in Big Data Hadoop by Shubham
• 13,490 points
2,230 views
0 votes
1 answer

How to find the used cache in HDFS

hdfs dfsadmin -report This command tells fs ...READ MORE

answered May 4, 2018 in Big Data Hadoop by Shubham
• 13,490 points
2,039 views
0 votes
1 answer

Hadoop: localhost: Error: JAVA_HOME is not set.

Seems like PATH problem in hadoop-env.sh file. Try ...READ MORE

answered Nov 6, 2018 in Big Data Hadoop by Omkar
• 69,210 points
4,694 views
0 votes
1 answer

Hadoop Oozie: E0902: Exception occured: [User: oozie is not allowed to impersonate oozie]

Seems like your version of Hadoop does ...READ MORE

answered Nov 12, 2018 in Big Data Hadoop by Omkar
• 69,210 points
898 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP