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 8127493
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T07:33:01+00:00 2026-06-06T07:33:01+00:00

I am currently developing a jsp web application that maintains two clients of two

  • 0

I am currently developing a jsp web application that maintains two clients of two other web services. I am using apache-tomcat 6.0.26, Oracle (Sun) java 1.6 and Netbeans 6.9 (IDE). My problem is that when a call the two web services from a standard Java SE application, everything works fine. However, If I attempt to call web service methods from the web service that consumes the two web services, I get a:

NoSuchMethodError: javax.xml.ws.WebFault.messageName()Ljava/lang/String;

I use a wrapper-class that handles the RPCs for the web service:

public class RecommenderEngineContainer {

    public ArrayList<Long> getRecommendationResults(long user_id, int nummOfRecs) {
        if(user_id < 0 || nummOfRecs < 0 || nummOfRecs > 100)
            return null;
        ArrayList<Long> recommendedProducts = (ArrayList<Long>) getRecommendation(user_id, nummOfRecs);
        return recommendedProducts;
    }

    private static java.util.List<java.lang.Long> getRecommendation(long arg0, int arg1) {
        ws.recommendationengine.RECOMMENDATIONENGINEWSService service = new ws.recommendationengine.RECOMMENDATIONENGINEWSService();
        ws.recommendationengine.RECOMMENDATIONENGINEWS port = service.getRECOMMENDATIONENGINEWSPort();
        return port.getRecommendation(arg0, arg1);
    }

}

And the code of the JAX-WS webservice is as follows:

public class RECOMMENDATION_ENGINE_WS {

    private MyConnector dbManager;
    private Connection dbCon = null;
    private String DIRECTORY_PATH;
    private String data_model_file;
    private String dbTableUserPrefs = "user_preferences";
    private String dbTableSimModel = "item_similarities";
    private static SingletonItemSimilarityModel myHModel;

    public RECOMMENDATION_ENGINE_WS() {
        Context context = null;
        try {
            context = (Context) new InitialContext().lookup("java:comp/env");
            this.DIRECTORY_PATH = (String) context.lookup("RECOM_ENGINE_DIR_PATH");
            this.data_model_file = (String) context.lookup("USER_HISTORY_FILE_NAME");
        }catch(NamingException e) {
            System.err.println(e.getMessage());
        }
    }

    public ArrayList<Long> getRecommendation(long userId, int NumOfRecommendations) {
        List<RecommendedItem> recommendations = this.myHModel.getRecommendations(userId, NumOfRecommendations);
        ArrayList<Long> result = new ArrayList<Long>();
        Iterator itr = recommendations.iterator();
        while(itr.hasNext()) {
            RecommendedItem recItem = (RecommendedItem) itr.next();
            result.add(new Long(recItem.getItemID()));
        }
        return result;
    }
}

The NoSuchMethod Exception stact trace starts from the call
ArrayList recommendedProducts = (ArrayList) getRecommendation(user_id, nummOfRecs);

Why is this happening? Since the code that the exception comes from is auto-generated, what can I do to overcome it? Why is this only happening in a web application and not in a java SE application? Does it have anything to do with my current setup?

Thank you for your time.

  • 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-06-06T07:33:02+00:00Added an answer on June 6, 2026 at 7:33 am

    Actually I figured out what went wrong. Apparently the JAX-WS framework didn’t work because of the return value ArrayList object. When I changed it as a String object, no problem appeared. Also, I have to mention that I upgraded from Oracle Java 1.6 to 1.7, though I do not think that this was the main reason.

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

Sidebar

Related Questions

Im currently developing av price list using SQL Reporting Services. In that report I
I'm currently developing a web application using Struts2 framework. This application requires to dynamically
I currently developing a web based application for a client. the requirement given that
I am currently developing a Rails application using a database that was designed before
I'm currently developing a PHP application that's using an Access database as a backend.
Currently developing an application using the newest version of symfony, obtained through PEAR. This
Im currently developing an In-House Enterprise application. I will publish the app using Apple
I am currently developing an application , that will be published on appstore. I
I´m currently developing a web site using Symfony2. On 'dev' environment everything works just
Im currently developing a Silverlight application that connects to an old webservice. Our old

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.