Chris Stabler

+ Follow
since Oct 22, 2009
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Chris Stabler

Matthew Brown wrote:outerRing != outRing

Is it as straightforward as that, or is that a mistake in your posting?

mistake in posting - i will correct
10 years ago
I have an abstract class that has a few classes and variables but i am having issues with these variables being "seen" by the implentation class.

**Implementation Class**

java.lang.NoSuchFieldError: outerRing

so my question is is that how come the implementation class cannot see a member of a class that is inside my base class? Area is just a class from the java.awt.geom class.

thanks for your help in advance.

10 years ago
I have been running some tests with the java.awt.geom API and i have a question about the Shape Class and i need to work with specifically the Area implementation.

I create 2 shapes, both Path2D types, then convert both to an Area. One shape in completely inside the other. When i do an intersect between the two i get some peculiar results.

If i say shape1.intersect(shape2), where shape2 is inside of shape1 completely, i get only the points for shape2. If i say shape2.intersect(shape1), then i get the original set of points for shape1...but regardless of which i do, the intersection test passes. I have read the API docs and i know that it says intersect checks for any polygon/rectangle that is inside of the area.

My issue is is that there is not a contains functions that works against areas..only against bounding boxes or 4 points. the getBounds2D() function talks of better precision but what if i had to check for contains with a triangle and one point of the triangle directly lies at the same x,y coordinate of the surrounding area? does the creation of the bounding box work with contains returning true?

thanks all for your help!
10 years ago

Ivan Krizsan wrote:Hi!

Chris Stabler wrote:When you say "- Develop your web service endpoint implementation class (annotated with @WebService etc)." does that mean just create my java class?


i have multiple jar files that contains classes, and other various dependency classes.

Treat those as you would treat JAR files to be included in a dynamic web project, that is, place them in the designated web application library folder.

3. Export the project to Glassfish.

If you mean "Deploy to GlassFish", then you are correct.

Should i import that project by loading up the actual glassfish IDE? or does eclipse offer an export to a glassfish project? does it even matter?

Eclipse does not offer a specific GlassFish project. As before, you can use a regular Dynamic Web Application project and deploy it to GlassFish. You should have the latest GlassFish plugin installed in Eclipse and configured an instance of a GlassFish server, also in Eclipse.
As you may already know, the procedure to deploy a web application in Eclipse is:
- Right-click on the project node in the Package Browser window.
- Select "Run As" and select "Run on Server".
- Select the configured GlassFish server.

Hope this helps!


thanks so much for the tips and help. i got everything to work as you said and after i figured a few other problems that i was having on my own. I still get some weird ADB, sub element errors (without glassfish) and some element errors even using glassfish. I am wondering if eclipse is just not ready for primetime when it comes to pushing some complex types(home grown or 3rd party) into a wsdl correctly so other non-java clients can properly communicate with the web service.

After trying out netbeans 6.8 for a day yesterday and getting everything working with no errors(save putting the war file on another machine), i would say netbeans is the better way to go. netbeans comes automatically with glassfish and apache derby which is a nice plus up. The wsdl that it creates also that you connect to doesnt require you to have to set up variables for each request and response just to be able to call a web service method. Netbeans just seems to be cleaner and easier.
10 years ago

Ivan Krizsan wrote:Hi!
Do NOT do the following when developing your web service:

right click on the java file -> Web Services -> Create Web Service.

The tools in Eclipse uses Axis or Apache CXF, not GlassFish (Metro).

What you need to do to develop the simplest form of web service in Eclipse and deploy it to GlassFish is:
- Create a dynamic web project.
- Develop your web service endpoint implementation class (annotated with @WebService etc).
- Deploy the project to GlassFish.

GlassFish will automatically generate the WSDL and other artifacts, as needed.
Best wishes!

Thanks for the tip Ivan. When you say "- Develop your web service endpoint implementation class (annotated with @WebService etc)." does that mean just create my java class?

I really don't have a simple web service that i need to test. i have multiple jar files that contains classes, and other various dependency classes. what would be the standard to to annotate all of these or is it necessary? ive got 40 or 50 classes combined, most of them exported out into a jar file.

In effect, what i picture in my mind is that i should:

1. Create a dynamic web service project in eclipse.

2. create the java class that contains the methods that i want to be accessible by a web service client.

3. Export the project to Glassfish.

Should i import that project by loading up the actual glassfish IDE? or does eclipse offer an export to a glassfish project? does it even matter?

I also have a couple of 3rd party libraries that i depend on and some .jar files that are customized that i have written. i assume that this is also not a problem.

Look to hear back from you and thanks for the tips and information.!
10 years ago

Prateek Parekh wrote:

cannot Deploy DssGlassServiceEAR
java.util.concurrent.ExecutionException: java.lang.IllegalArgumentException: port out of range:1114848

You should configure your Glassfish server to use a valid port i.e. somewhere in the range 1023 - 65535.
The axis runtime and application server have 2 different objectives. Check out the following article. It will help clear things up.

i have eclipse open now after having installed the glassfish plugin but i see no where to change the port number. can you give me a lead on this?

also currently i just want to create the webservice on localhost. i dont see why there is even a port issue to begin with...

thanks --
10 years ago
I have a post below about boolean variables and i seem to have had other problems with Eclipse and web services. I am currently using Eclipse Galileo.

I am going to give Glassfish a try - maybe things are a bit easier and straightforward.

I create a Dynamic Web Project -> Target Runtime: Glassfish v3 Java EE 6.

I create a package name then a java source file with some methods that i want to turn into a web service.

right click on the java file -> Web Services -> Create Web Service.


Server: Glassfish v3 Java EE 6
Web Service Runtime: Apache Axis 2. <--- why does it have to be Axis 2? i thought glassfish was going to replace axis 2 altogether? even if i make another selection(Glassfish) it still chooses Axis 2 for some reason.
Service Project: WebService
Service EAR Project: WebServiceEAR.

Click Finish.


cannot Deploy DssGlassServiceEAR
java.util.concurrent.ExecutionException: java.lang.IllegalArgumentException: port out of range:1114848
at java.util.concurrent.FutureTask$Sync.innerGet(
at java.util.concurrent.FutureTask.get(
at com.sun.enterprise.jst.server.sunappsrv.SunAppServerBehaviour.publishDeployedDirectory(
at com.sun.enterprise.jst.server.sunappsrv.SunAppServerBehaviour.publishModuleForGlassFishV3(
at com.sun.enterprise.jst.server.sunappsrv.SunAppServerBehaviour.publishModule(
at org.eclipse.wst.server.core.model.ServerBehaviourDelegate.publishModule(
at org.eclipse.wst.server.core.model.ServerBehaviourDelegate.publishModules(
at org.eclipse.wst.server.core.model.ServerBehaviourDelegate.publish(
at org.eclipse.wst.server.core.model.ServerBehaviourDelegate.publish(
at org.eclipse.wst.server.core.internal.Server.publishImpl(
at org.eclipse.wst.server.core.internal.Server.publish(
at org.eclipse.jface.operation.ModalContext$
Caused by: java.lang.IllegalArgumentException: port out of range:1114848

Any ideas on what i could be doing wrong? thanks!
10 years ago
Ive created a web service with one of the methods requiring a boolean parameter type. i am using Axis2 and Eclipse with Tomcat/Apache as the service backend.

I have a standalone application that uses the method and there seems to be no problem. Someone else tries to create a C# main app when building the stub from the WSDL and for some reason there is an error on the server side:

Caused by: java.lang.NumberFormatException: For input string: "false"
at java.lang.NumberFormatException.forInputString(
at java.lang.Long.parseLong(
at java.lang.Long.<init>(
at org.apache.axis2.databinding.typemapping.SimpleTypeMapper.getSimpleTypeObject(
at org.apache.axis2.databinding.utils.BeanUtil.processObject(
at org.apache.axis2.databinding.utils.BeanUtil.ProcessElement(
at org.apache.axis2.databinding.utils.BeanUtil.deserialize(
at org.apache.axis2.rpc.receivers.RPCUtil.processRequest(
at org.apache.axis2.rpc.receivers.RPCUtil.invokeServiceClass(
at org.apache.axis2.rpc.receivers.RPCMessageReceiver.invokeBusinessLogic(
... 19 more

At first the parameter type was Boolean(the object) then i changed it to the primitive type and still got the same error.

Was wondering at first glance, if someone has had experience with SOAP protocols being incompatible with C# using boolean parameters? what should i check for? If you want to see the WSDL XML i can furnish that for you if that would help.

Thanks a lot in advance. (meant to post this earlier but somehow it didnt take for some reason).
10 years ago
I have a problem with Axis 2 that I have been unable to resolve.

I am using Eclipse Galileo, Apache/Tomcat 6.0, Mac OSX 10.6.2, and deploying the web service as Axis 2.

Basically I have a java file with a simple set of functions that i want to make a web service out of.

I create a dynamic web project in eclipse, create a java package, then create the java class file. then i do Web Service->Create Web Service and select bottom down web service. Then i export the project out as a .WAR file.

I then move the WAR file into my webapps folder in my apache/tomcat directory and start up the server. I can access the wsdl in a brower(and i am able to look at the wsdl in XML format which is expected).

As a side note, when i try to run the non-web service functionality as a standalone everything works fine.

Anyway, i create a Web Service Client now based on the wsdl that is in the WAR file which creates for me a Server Stub. Then i create a java main class file.

//generic piece of code that i perform in main class.

all my types are complex types that i want to return, Arrays, etc etc.

anyway i get the following error:

Exception in thread "main" org.apache.axis2.AxisFault: org.apache.axis2.databinding.ADBException: Unexpected subelement description
at org.apache.axis2.AxisFault.makeFault(
at com.server.DssServerStub.fromOM(
at com.server.DssServerStub.getScenariosForEngine(
at com.client.Dss5Client.main(
Caused by: java.lang.Exception: org.apache.axis2.databinding.ADBException: Unexpected subelement description
at com.server.DssServerStub$InputParameter$Factory.parse(
at com.server.DssServerStub$ScenarioInfo$Factory.parse(
at com.server.DssServerStub$GetScenariosForEngineResponse$Factory.parse(
at com.server.DssServerStub.fromOM(
... 2 more
Caused by: org.apache.axis2.databinding.ADBException: Unexpected subelement description
at com.server.DssServerStub$InputParameter$Factory.parse(
... 5 more

I can post the WSDL XML output i suppose but wanted to get any idea of what causes this error. How can i not get any compile errors or run time errors and then somehow it doesnt know what an element is when i deploy the service? Is there something going on with Axis2 and ADB with Eclipse? I read people suggesting to use XMLBeans but i am unfamiliar with it. Let me know your thoughts and any help is appreciated. THANKS!
10 years ago
I have a java noob question regarding class casting.

A few schemas were created in eclipse to define certain types. One of the types i will talk about is Address. A WSDL was created from these schemas and built into a package. From this, the main IMPL class was created which are the WSDL stub calls that the client will use to retrieve information. I have no control over the client other than the fact that it knows what functions are available and thats all the client knows about. It doesnt know nor is it supposed to know anything about the server side.

the WSDL Address class is something like:

An example of one of the functions created from the WSDL would be a certain function:

where the com.general.client.Address is what it expects to be returned back.

My Converter class is supposed to act as a bridge between client and server so that the server code never changes in the future, if any new functions are added to the schemas or if new schemas are created, thus new wsdl's. Converter, in this case, will use the argument 'id' and use that number to do whatever it needs to do to get the correct data that i need, in this case, it is an Address..that represents my own Address class( that i created with a different package name).

Because its my own definition of Address(with the same attributes) its going to have a different package name. Remember though that the IMPL class expects to be returned its own Address type(com.general.client.Address) and my Address class type is in the form of something like com.general.server.Address. So now I have address information based on the ID that i passed to my Converter constructor but that information is stored in my own Address class type. I need to use my converter class to take my own internal Address Class type and convert this back to the original IMPL class address type, because that's what it expects.

So in my converter class how, would i make the appropriate java method calls or casting class to convert my Address class type to the correct IMPL Address class type that it expects?

thanks everyone for your input in advance.

11 years ago
I need help in my next move with Web Services. I have very little experience with Web Services, rules, lingo etc etc and trying to learn on the fly.

Let me explain what i have accomplished so far in Steps:

0a. Installed Apache Tomcat 6, using Java 1.6. Also using Eclipse Galileo.
0b. Using the Java keytool, i created a keystore in my home directory(default this is stored in the .keystore file)
0c. I edited the Tomcat Server.xml file and changed the port number to 8443 in the <Connector>...</Connector> tag and added a password that matches the password in the keystore that i created; keyPass="mypassword" for example. This should allow me to do https over localhost.

1. I wrote a function that takes a string and echoes it out to the console.

2. In Eclipse, i converted this .java file into a WSDL.

3. I then created a new java project called SampleClientEcho using the WSDL which created for me some files:

- StringEchoProxy
- StringEchoService
- StringEchoServiceLocator
- StringEchoServiceBindingStub

4. I created a Client file within this new project to use the Proxy to access the WSDL via https for testing:

5. I run the client via http via port 8080 and it works successfully. Evidently you dont manually need to run tomcat from command line as Eclipse seems to start it on its own. When i try to run it via https i get a bunch of runtime errors related to SSL handshaking and what not.

Going back to my first step how do i edit the original web service code(the one that accepts a string and echoes it out) so that i can assure that it is secure so that i can do the SSL handshaking?? What do i need to change in my client to assure of the handshaking? doing this is essential for me moving forward with web services.
11 years ago
i noticed that that Stub constructor actually needs a URL and a Service so it can gather an endpoint for the service.

i was able to change the code to get the URL, which is just, "http://localhost:8080/Converter/services/Converter" but i find no where to actually get the service so i am stuck for now.

Updated Code:

11 years ago
hi all,

i am using Eclipse Galileo to create w WSDL from a simple java piece of code. i am using Axis/Tomcat 6.0. File name is

once the WSDL is created, everything looks fine. now i need to create the client which i do from eclipse.

I get the following java files in my Converter/src now in my project:


i now want to write a simple client to retrieve information if i passed in a Celsius or F value.

i get no errors but when i run the client i get the following error messages:

faultCode: {}Server.NoEndpoint
faultString: No endpoint
{}stackTrace:No endpoint
at wtp.ConverterSoapBindingStub.celsiusToFarenheit(
at wtp.ConverterClient.main(


No endpoint
at wtp.ConverterSoapBindingStub.celsiusToFarenheit(
at wtp.ConverterClient.main(

I am totally new to web services and have no idea what i am doing. just trying something in the dark. If anyone could offer some help it would be appreciated.

I also noticed that my file with the actual code has been changed to:

So i am trying to figure out how it is going to know what functionality is in each of those functions now. Sorry for the noob questions. thanks much in advance.
11 years ago