stand-alone server

2006-08-02 Thread Raffaele Viola
Hi all,Can I make a web services server stand-alone that works without any application server or web server?BRRaffo


Re: unsubscribe me

2005-12-08 Thread Raffaele Viola
Plz unsubscribe me

Raffo


Re: call web service from jsp

2005-11-04 Thread Raffaele Viola
I made my jar file but the jsp say that the can't import because the
package does not exist
Where I made a mistake???

Thanks a lot
RaFFo

2005/11/4, Guy Rixon [EMAIL PROTECTED]:
 We do this a lot in AstroGrid. We generate stub classes using WSDL2ava and add
 those classes to the web-application where they are consumed by the JSP.
 Generally, we pack the stub classes into a jar file and add that jar to the
 lib directory of the consuming web-app.

 You need to consider whether you generate the stubs as part of the
 construction of the consuming web-app or as part of the consruction of the
 service; both work but with different advanatages and penalties. If you make
 the stubs jar in the service build, then you get to reuse that jar across
 several consuming applications. However, you then force all those applications
 to use the same version of Axis. If you build the jar in the consuming
 application then you can use any Axis version but you do more building and
 packaging.


 On Thu, 3 Nov 2005, Raffaele Viola wrote:

  How can I call web service by a jsp page using the java classes created by 
  Axis
 
  Thanks Raffo
 

 Guy Rixon   [EMAIL PROTECTED]
 Institute of Astronomy  Tel: +44-1223-337542
 Madingley Road, Cambridge, UK, CB3 0HA  Fax: +44-1223-337523



Re: call web service from jsp

2005-11-03 Thread Raffaele Viola
For the jsp client I use this code:
%@ page contentType=text/html; charset=iso-8859-1 language=java
import=java.util.*  errorPage= %
html
head
meta name=GENERATOR content=Microsoft FrontPage 5.0
meta name=ProgId content=FrontPage.Editor.Document
meta http-equiv=Content-Type content=text/html; charset=windows-1252
titleinfo_mach/title
/head
body bgcolor=#00FF00
% String host = request.getParameter(host0);
String user = request.getParameter(user0);
String pass = request.getParameter(pass0);
String com=ps -ef;%

Queti sono i dati passati %= host % %= user % %= pass %
%  PerformWSServiceLocator l=new PerformWSServiceLocator();
 PerformWServiceSoapBindingStub stub
=(PerformWServiceSoapBindingStub) l.getPerformWService();
  StringTokenizer st=new 
StringTokenizer(stub.outputStr(host,user,pass,com));
while(st.hasMoreTokens())
{ %
%= st.nextToken() %
 %}%
/body
/html

but when I invoke the page, tomcat says that :

An error occurred at line: 18 in the jsp file: /PerformWeb/info_mach.jsp
Generated servlet error:
/opt/jakarta-tomcat-5.0.28/work/Catalina/localhost/_/org/apache/jsp/PerformWeb/info_005fmach_jsp.java:68:
cannot find symbol
symbol  : class PerformWSServiceLocator
location: class org.apache.jsp.PerformWeb.info_005fmach_jsp
PerformWSServiceLocator l=new PerformWSServiceLocator();
^


An error occurred at line: 18 in the jsp file: /PerformWeb/info_mach.jsp
Generated servlet error:
/opt/jakarta-tomcat-5.0.28/work/Catalina/localhost/_/org/apache/jsp/PerformWeb/info_005fmach_jsp.java:68:
cannot find symbol
symbol  : class PerformWSServiceLocator
location: class org.apache.jsp.PerformWeb.info_005fmach_jsp
PerformWSServiceLocator l=new PerformWSServiceLocator();
  ^


An error occurred at line: 18 in the jsp file: /PerformWeb/info_mach.jsp
Generated servlet error:
/opt/jakarta-tomcat-5.0.28/work/Catalina/localhost/_/org/apache/jsp/PerformWeb/info_005fmach_jsp.java:69:
cannot find symbol
symbol  : class PerformWServiceSoapBindingStub
location: class org.apache.jsp.PerformWeb.info_005fmach_jsp
 PerformWServiceSoapBindingStub stub
=(PerformWServiceSoapBindingStub) l.getPerformWService();
 ^


An error occurred at line: 18 in the jsp file: /PerformWeb/info_mach.jsp
Generated servlet error:
/opt/jakarta-tomcat-5.0.28/work/Catalina/localhost/_/org/apache/jsp/PerformWeb/info_005fmach_jsp.java:69:
cannot find symbol
symbol  : class PerformWServiceSoapBindingStub
location: class org.apache.jsp.PerformWeb.info_005fmach_jsp
 PerformWServiceSoapBindingStub stub
=(PerformWServiceSoapBindingStub) l.getPerformWService();
   ^
4 errors

Can you help me???

Thanks a lot
Raffo



2005/11/3, Jyotishman Pathak [EMAIL PROTECTED]:
 My guess would be importing the required stubs in your JSP code, using the
 stub classes inside your JSP code, and setting the classpath appropriately.

  Another way could be to use Java beans+JSP combination for invoking the
 service. Off course, that depends on what kind of application you are
 building.

  HTH,
  - Jyoti



 On 11/3/05, Raffaele Viola [EMAIL PROTECTED] wrote:
  How can I call web service by a jsp page using the java classes created by
 Axis
 
  Thanks Raffo
 




using ssh client with web service

2005-11-02 Thread Raffaele Viola
Hi,

I try to develop a web service that by an ssh client get any
information from a host.
For the ssh client I use a .jar named Ganymed SSH2

the client work perfectly if I use it from a normal standalone java
main, but cause any problems if I use it from a web service.

In each one program i use the same IP User and Password but under web
service tomcat made this log

_
143.225.250.102 viola wertCreato l'oggetto SshClient   1Creata
un'istanza di connessione
Questo รจ l'errore generato --- The connection could not be fully established.
java.io.IOException: The connection could not be fully established.
  at ch.ethz.ssh2.Connection.connect(Connection.java:464)
  at ch.ethz.ssh2.Connection.connect(Connection.java:418)
  at PerformWS_pkg.SshClient.getDataString(SshClient.java:41)
  at 
PerformWS_pkg.PerformWSSoapBindingImpl.outputStr(PerformWSSoapBindingImpl.java:22)
  at 
PerformWS_pkg.PerformWSSoapBindingSkeleton.outputStr(PerformWSSoapBindingSkeleton.java:58)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)
  at 
org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:388)
  at 
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:283)
  at 
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
  at 
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
  at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
  at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
  at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
  at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
  at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
  at 
org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
  at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
  at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
  at 
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
  at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
  at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
  at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
  at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
  at 
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
  at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
  at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
  at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
  at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
  at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
  at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
  at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
  at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
  at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
  at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
  at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
  at 
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
  at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
  at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: Cannot establish TCP connection to
143.225.250.102:22
  at 
ch.ethz.ssh2.transport.TransportManager.init(TransportManager.java:82)
  at