Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6327985
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T17:22:40+00:00 2026-05-24T17:22:40+00:00

I’m using some third party jar file, there are plenty of Jar files as

  • 0

I’m using some third party jar file, there are plenty of Jar files as well, and I have the code written by someone else.
While executing, I’m geting this error:

java.lang.ClassCastException : org.apache.axis.client.Service cannot be cast to org.apache.axis.client.Service

Can you suggest me what could be the problem?

Thanks for the reply.

But before getting this error, I was getting:

java.lang.LinkageError : loader constraint violation: when resolving method “org.onvif.www.ver10.device.wsdl.DeviceBindingStub.(Ljava/net/URL;Ljavax/xml/rpc/Service;)V” the class loader (instance of org/apache/catalina/loader/WebappClassLoader) of the current class, com/abcd/efgh/ijkl/device/onvif/DeviceHandlerClient, and the class loader (instance of org/apache/catalina/loader/StandardClassLoader) for resolved class, org/onvif/www/ver10/device/wsdl/DeviceBindingStub, have different Class objects for the type javax/xml/rpc/Service used in the signature.

The problem has not resolved yet. I’m not getting where the version mismatch of files/jar is happening from. I have included some Jars manually.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T17:22:41+00:00Added an answer on May 24, 2026 at 5:22 pm

    You likely have the Service class being sourced from two different class loaders. A classes identity is a combination of its name and the class loader that loaded the class.

    As a contrived example, you could have two web apps deployed in something like Tomcat. They each have a copy of the same jar, and each loads their own instance of a class. Since they’re in separate WARs, however, they each have different class loaders.

    Next, lets say that you have something global, like a caching library or something. This caching module has its jar not within an individual WAR, but on the system class path for the container, that way it’s visible to both WARs.

    Web app 1 stores an instance of the class in to the cache, and then web app 2 tries to load that instance and cast it to its local version of the class. But since it’s from the other web app, it has a different class loader than web app 2’s. Thus when it’s trying to cast the instance, it fails because it’s not web app 2’s version of that class.

    So, basically, you have some kind of class loader confusion happening here. Make sure you have a clear understanding of what jars you’re using, ensuring that there aren’t any unnecessary duplications, and what context is loading what classes.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just tried to save a simple *.rtf file with some websites and
I have thousands of HTML files to process using Groovy/Java and I need to
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I have this code to decode numeric html entities to the UTF8 equivalent character.
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
We are using XSLT to translate a RIXML file to XML. Our RIXML contains
I have a reasonable size flat file database of text documents mostly saved in
I have a bunch of posts stored in text files formatted in yaml/textile (from
I'm new to using the Perl treebuilder module for HTML parsing and can't figure

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.