Onisha
Onisha

Reputation: 122

When I run the Application, only "web" engine is running in GlassFish. "webservices" is not started

i tried a simple web service program for the first time. When I run the Application, only "web" engine is running in GlassFish. "webservices" engine is not started. i have installed java ee sdk 1.6

Upvotes: 4

Views: 3742

Answers (7)

Electroseela
Electroseela

Reputation: 111

There have two type version of Java EE on Oracle website.

i) Java EE 7 Platform SDK

ii) Java EE 7 Web Profile SDK

if you want to see "webservices" engine is start on GlassFish Applications then you have to work with "Java EE 7 Platform SDK" version...

Upvotes: -1

RAM_Sah
RAM_Sah

Reputation: 11

  1. Delete your glassfish4 server from current eclipse ide(eclipse must support jee).
  2. Go to Windows in eclipse menu bar select show console and choose server.
  3. click install new server link in the console.
  4. Select JDK1.8 not default jre. after that choose glassfish 4.0 to install.
  5. Browse directory where you want your glassfish to be install (better choose in C:/Program Files/glassfish).
  6. Click on install server button. Accept the licence and wait till your glassfish 4.0 get installed by eclipse ide.
  7. Finally deploy your application it'll show webservice and view EndPoint.

Upvotes: 0

Igor Zec
Igor Zec

Reputation: 21

I had similar problem. Actually project was working with NetBeans and local GlassFish, but when I deployed on GlassFish 4.1.1 (on amazon linux) "webservices" engine did not start. I followed previous answer (form mposadar) and just added in class initializer block:

 @WebService(endpointInterface = "service.ITranslate")

        public class Translate  implements ITranslate
        {
            {
                try {
                    URL url = new URL("http://MY_INSTANCE.us-west-2.compute.amazonaws.com:8080//Translate/TranslateService?wsdl");
                } catch (MalformedURLException ex) {
                    Logger.getLogger(Translate.class.getName()).log(Level.SEVERE, null, ex);
                }
            }
...

After build and deploy, "webservices" option works also on remote server, as well link to "View Endpoint" and wisdl is available.

Upvotes: 1

mposadar
mposadar

Reputation: 261

I do have the full profile of GlassFish server, so What i did was to manually execute the wsdl url of my java class. For example:

My Java class is "Test": url = http://localhost:8080/ProjectName/TestService?wsdl

then I reload the aplication tab of the glassfish admin. done problem resolve.

hope this helps anyone

Upvotes: 0

Natalie Pan
Natalie Pan

Reputation: 81

Make sure you're using Full Profile not Web version of Glassfish

in your glassfish bin folder check if the following command has webservices in it glassfish4\bin>asadmin list-containers if not you have the web version

goto https://glassfish.java.net/download.html and download, unzip and replace your files

Upvotes: 4

vinsinraw
vinsinraw

Reputation: 2125

I assume you have have created a dynamic web project with Webservices annotations on your classes. On deployment, and logging into Glassfish Admin console and then navigating to Applications and looking under Engines column against your deployed application, Glassfish showing only web and not showing webservices.

To enable the webservices, it appears your classes are not compiling under default build/classes directory.

Do either of the following: Right click on your project > Build Project. or Go to eclipse menu > Project > Build Automatically

Now redeploy your application again. webservices Engine should be visible along with web engine.

Upvotes: 5

Aksel Willgert
Aksel Willgert

Reputation: 11547

According to oracle page there are differences between webprofile and full profile glassfish

the option

Implementing Java Web Services 1.3

is only ticked for full profile, so wouldnt work if you have the web profile

You can look at the license file name to determine which Full profile or Web profile

<glassfish install dir>/glassfish/legal/3RD-PARTY-LICENSE.txt
<glassfish install dir>/glassfish/legal/3RD-PARTY-LICENSE-WEB-PROFILE

Glassfish documentation also states:

If you are using the web profile, you can also use Update Tool to obtain technologies that are included by default in the full platform, such as:

  • Enterprise Java Beans
  • Metro
  • Jersey

Upvotes: 0

Related Questions