Re: SOAP: Unable to resolve target object

2002-11-22 Thread jattwood
Hi Phil,

Exception in thread main java.lang.NoClassDefFoundError: my client class

I put this TOMCAT_HOME/webapps/soap/WEB-INF/classes in the CLASSPATH (in
case).

Your client will rely on the CLASSPATH to find its classes (unlike the
server which uses TomCat's class loader hierarchy). Whenever I've had problems
like this they've always turned out to be typos in my CLASSPATH (missing
semicolon or colon instead of semicolon) which invalidate the part which points
to the class which can't be found. These can be very hard to spot, and even
harder for the person who knows what should be there. I have a Perl script
which breaks my classpath into pieces on semicolons and display each on a 
separate line. This helps to show up errors, but still doesn't help when the
problem is a typo inside one of the path components rather than the 
separators.

Hopefully a second pair of eyes will resolve your problem,
Regards,

John.


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: SOAP: Unable to resolve target object

2002-11-19 Thread jattwood
Hi Phil,

I tried to install a SOAP service on an Apache server with Tomcat 4.1 webapp module.

I deployed the SOAP service with no problem. The SOAP client is well compiled.
But when I run the client, i have the following message:

Unable to resolve target object : my soapService

CLASSPATH seems well.

As no-one else has replied to this I thought I'd have a go (I have SOAP
working with TomCat here).

Firstly, TomCat ignores your CLASSPATH. The SOAP libraries and your client
classes have to be in TomCat's common/lib directory and your webapp's 
WEB-INF/classes directory in order to be found when servicing a request.

Secondly, when you say you deployed the SOAP service with no problems, do
you mean that you deployed your webapp within TomCat, or that you deployed
your SOAP service within the SOAP server? You need to do both of these for
the service to be functional. Since my TomCat is often restarted (it's
part of an application and controlled by JBoss) I had to reconfigure SOAP
to use a fixed-path XML deployment file and to read it every time it
starts up. This took the best part of a day to get right, but now works
well. I can supply details if you need it, but you probably don't.

Can yu get the SOAP administration page to come up?

Regards,

John Attwood,
MRC HGMP.

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: SOAP: Unable to resolve target object

2002-11-19 Thread jattwood
Hi Phil,

Why put the client classes in TomCat's common/lib directory ???

Sorry, this was bad English on my part. Obviously the client classes go
in the (soap webapp's) WEB-INF/classes; whether you put the soap jarfile
there or in the common/lib directory depends on whether you want it to
be available to multiple webapps or just the one.

As I said, TomCat ignores your CLASSPATH, and will construct its own
based on the contents of the webapp's lib and classes directories and
the the various common directories (note that classes have to be in
a classes directory and jarfiles in a lib directory, and both have to
be inside their package heirarchy).

If you are sure that you have the classes where TomCat can locate them,
then it is possible that your soap deployment is failing. My understanding
of deployment in this sense is that it is persistent, so you should be
able to start TomCat, deploy a service, shutdown and restart TomCAt and
still see your service as deployed. If this isn't happening then you
aren't deploying your service and that is why you get the error message.

Another possibility is that you haven't specified the method(s) in your
class that you want to expose, or have mis-spelled or mis-capitalised 
them in the deployment descriptor (I do the latter all the time and
now copy and paste the method names from the java source to be sure of
getting it right. Alternatively you may have mis-spelled or mis-capitalised
them in your client and are trying to call something other than what you
have exposed. Or you may not have specified your service's urn correctly
(again, this has to match between the client call and the server's
deployment descriptor.

My situation is complicated because JBoss deploys my webapp afresh every
time TomCat is started and there is no fixed path to my webapp directory,
so any persistent soap deployment info there is lost when the server
is restarted. To counteract this, I put the following in my web.xml:-

context-param
param-nameConfigFile/param-name
param-value/WEB-INF/soap.xml/param-value
/context-param

This only worked as a context-param, I couldn't make it an init-param in
the rpcrouter servlet.

Then in /WEB-INF/soap.xml I have:-

soapServer
configManager value=org.apache.soap.server.XMLConfigManager 
option name=filename value=/WEB-INF/DeployedServices.xml 
/configManager
/soapServer

Then my /WEB-INF/DeployedServices.xml contains my isd:service deployment
descriptors inside a root/root tag.

All of these files live in my soap app's WEB-INF directory so get unpackaged
every time JBoss deploys it, and the XMLConfigManager reads them in at
startup time, thereby ensuring that they are deployed. All paths are 
relative to the movable webapp directory and so can be found without needing
to know where it lives.

It's only necessary to resort to such extremes if you are using a container
manager like JBoss, and it could also be done by telling the default
config manager to store its persistent information somewhere permanent, but
the latter wasn't an option for me.

Hope this is some help. I found that it often helped to look at the stack
traces output by TOmCat when the SOAP service failed, as these often
gave clues as to what the problem really was (but only if you have a twisted
mind and view them from the program's standpoint).

Regards,

John.

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: SOAP: Unable to resolve target object

2002-11-19 Thread jattwood
Hi Phil,

I've also had a problem using SOAP within tomcat. I haven't been able to
find a way to share the service class files across contexts.

I did it backwards and put the soap servlet into my context. I can use the
same supporting beans to provide html output for humans and soap rpc for
machines. I didn't realise that it wasn't possible to share them across
contexts, though - this just seemed the easiest way to get what I wanted.

Regards,

John.

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Shutting down and restarting Tomcat

2002-11-08 Thread jattwood
Hi,

What is the command for setting the delay in a Windows batch file?

I downloaded something called UnxUtils.zip from the web (can't find where
from at the moment). Amongst other Unix goodies this includes sleep.exe.
It is a package of standalone binaries and you need install/use only
those you need, unlike Cygwin or Perl which are pretty massive.

With sleep.exe on your path you could then put a line like sleep 2 in
your batchfile to wait 2 seconds before proceeding.

Regards,

John.
MRC HGMP-RC

--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org




Re: A simple doubt

2002-11-01 Thread jattwood
Hi Raphael,

This message is very clear, but how I'm a beginner, I'll posting this problem 
you help me. Please, just response me: How can I configure a CONTEXT to it. When 
I install Tomcat alone, I don't receive this error, but when I install 
integrated with JBOSS, i get this error. Please, if you can help me, please send 
me the solution.

When running under JBOSS, TomCat ignores its own configuration files and
expects to have webapps deployed for it by JBOSS. There are threads on the
JBOSS website explaining how to do this, but essentially you need to make
a WAR containing your webapp and all its support (especially web.xml)
and include that in an EAR, along with an application.xml which names the
.war file, and drop the latter in JBOSS' deploy directory. JBOSS will 
deploy the EAR and send the WAR it contains to TomCat which will deploy it
in a temporary directory named after the EAR file. 

Using the information on the JBOSS website I was able to automate this
with ant, so that I can compile my code, build a WAR and EAR, and deploy
the latter with just two commands. The nice part about all of this is
that if there is already a webapp by this name running when you drop the
EAR in JBOSS' deploy directory, it is undeployed before the new one is
opened and deployed, so there is no need to stop TomCat, remove the
deployed WAR and restart with the new one. It's hard work getting it all
set up, but really easy to use once you succeed.

I got my ant build.xml and example application.xml from a post on the
JBOSS website - I think they came from a Sun example application somewhere -
and hacked them to work with my code and libraries.

Regards,

John.
MRC HGMP

--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org




JspC problems

2002-10-28 Thread jattwood
Hi,

I'm using TomCat v4.0.1, as I'm running inside someone else's JBoss
2.4.4 setup, and having problems precompiling some JSP files. I have
set up my build.bat like those described in recent posts on this subject
and all was fine until Saturday, when the JspC step started failing
silently and giving up on the remaining JSP source files. The new JSP
works fine if put directly into the WEB-INF directory and called directly,
so it isn't that the file won't compile. I've seen some messages on this
list suggesting that early versions of Jasper were buggy, and my question
is: can I use the latest version of Jasper with TomCat 4.0.1?

As a side issue, I would also appreciate it if someone could tell me how
to stop Jasper complaining that it can't find a web.xml file, as I've
tried everything I can think of to tell it where to find a local copy
but it continues to complain. I'm having to manually add each new 
compiled JSP to the web.xml.

I can post the offending JSP code (only 5 lines) and the relevant parts
of build.xml if required, but I'm sending this from another computer at
a different site, so it's a bit complicated to include them.

Thanks in advance for any help with this,
Regards,

John Attwood,
MRC HGMP-RC

--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org




re: JspC problems

2002-10-28 Thread jattwood
Hi,

I've solved my compilation problem - I'd inadvertently trashed my
build classpath and jasper couldn't find the JavaBeans used by the
JSPs.

I still have the Internal Error: File /WEB-INFO/web.xml not found
problem though. The arguments to JspC are -d dest dir -v4 -p JspServ
and -webapp src dir and I'm using an ant java task as I couldn't
get the jspc task to work (always died with signal 9). I can't find
any docs for JspC which say what its command-line options are, so
I don't know how to tell it where to find web.xml at compile time.

Any insights appreciated.

John.


--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org




RE: Digested Passwords and Oracle 8.1.7

2002-10-23 Thread jattwood
Hi Graham,

You could get Oracle to do the work for you by trying to connect
to your database with the user's login name and password. If yu
succeed then the password was valid, otherwise it isn't. That way
you don't need to know the encryption algorithm.

John.

--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org