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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T21:46:39+00:00 2026-05-13T21:46:39+00:00

I have a web service and I was deploying it on GlassFish. I accessed

  • 0

I have a web service and I was deploying it on GlassFish. I accessed its wsdl through http://localhost:10697/APIService/APIServiceService?wsdl.

Now I ported the WAR file to a Tomcat 6.0.24 and it is deployed. However I am trying to access its wsdl using http://localhost:8080/APIService/APIServiceService?wsdl but I’m getting a 404 error. I tried various combinations but none seem to work.

How can I access the wsdl file plz?

Thanks and regards,

Update: Here you are: web.xml:

<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
    <session-config>
        <session-timeout>
            30
        </session-timeout>
    </session-config>
    <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
</web-app>

I can’t find sun-jaxws.xml however… Thanks a lot! Regards

  • 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-13T21:46:40+00:00Added an answer on May 13, 2026 at 9:46 pm

    The way to access a WSDL is not really container specific, it’s more WS-stack specific. The WS-stack in GlassFish is Metro (Metro = JAX-WS RI + WSIT). Did you install/deploy Metro or JAX-WS RI on Tomcat? See Metro on Tomcat 6.x or Running JAX-WS Samples with Tomcat 6.x (JAX-WS RI might be enough in your case) for the steps.

    Update: You need to declare the WSServlet in the web.xml (see Deploying Metro endpoint):

    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
      <listener>
        <listener-class>
        com.sun.xml.ws.transport.http.servlet.WSServletContextListener
        </listener-class>
      </listener>
      <servlet>
        <servlet-name>WebServicePort</servlet-name>
        <servlet-class>
        com.sun.xml.ws.transport.http.servlet.WSServlet
        </servlet-class>
        <load-on-startup>1</load-on-startup>
      </servlet>
      <servlet-mapping>
        <servlet-name>WebServicePort</servlet-name>
        <url-pattern>/services/*</url-pattern>
      </servlet-mapping>
      <session-config>
        <session-timeout>60</session-timeout>
      </session-config>
    </web-app>
    

    And then in the sun-jaxws.xml (also packaged in WEB-INF), declare your Service Endpoint Interface (SEI):

    <?xml version="1.0" encoding="UTF-8"?>
    <endpoints xmlns="http://java.sun.com/xml/ns/jax-ws/ri/runtime" version="2.0">
      <endpoint
      name="MyHello"
      implementation="hello.HelloImpl"
      url-pattern="/hello"
      />
    </endpoints>
    

    And you access the WSDL at:

    http://localhost:8080/<mycontext>/services/hello?wsdl
               A               B         C       D
    
    • A is the host and port of the servlet container.
    • B is the name of the war file.
    • C comes from the url-pattern element in the web.xml file.
    • D comes from the ending stem of the url-pattern attribute in the sun-jaxws.xml file.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have web service urls that were working fine and are now returning the
I have web service, which use integrated security in IIS. Now, I want to
I'm creating a web service, which run in GlassFish, and I want to have
I have a web-service that I will be deploying to dev, staging and production.
I have developed a simple Apache-Axis java web service using Eclipse IDE and now
I have web service which i want to use to upload image to the
I have web service which return json string like : d={main0ID:abc.es/main,main1ID:ah/main} I wanna append
I have web-service which give list of property at a particular area My problem
I have web service used by about a dozen C# projects and sites. The
When I call, the service's method, I have Web Service Exception happening which I

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.