Serializer + deployment descriptor

2002-11-13 Thread Mattias Jiderhamn
I am really, really tired of the fact that I can not get any type mappings
to work in the deployment desriptor.

If I have the file:
http://xml.apache.org/xml-soap/deployment";
  id="urn:ApiTest">
  

  
  
org.apache.soap.server.DOMFaultListener
  

  
http://schemas.xmlsoap.org/soap/encoding";
 xmlns:x="urn:ApiTest" qname="x:IntPair"
 javaType="se.exder.api.IntPair"
 java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
 xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
  


and try to deploy it with
  java -classpath $CLASSPATH org.apache.soap.server.ServiceManagerClient
http://localhost/servlet/rpcrouter deploy filename.wsdd
The mapping is never working (client says
"java.lang.IllegalArgumentException: No Serializer found to serialize a
'se.exder.api.IntPair' using encoding style
'http://schemas.xmlsoap.org/soap/encoding/'")

But if I input the exact same information in the admin page
(/soap/deploy.jsp) everything works just fine. (See attached sceenshots).

I always undeploy the service before re-deploying. I have tried the latest
build (2002-10-27) and I am still having the same problem.
Why is this???
What can I do about it?

<><>--
To unsubscribe, e-mail:   
For additional commands, e-mail: 


Using mime parts - huge drawbacks

2002-11-13 Thread Pavel Ausianik
Hello,

thinking more on the current code I have found interesting thing. Most
requests we have a simple, straight SOAP envelopes, without any attachments.
Looking how it is processed I have found following (traced from
httpconnection):

In SOAPHTTPConnection.send() we call TransportMessage.save().
Let's look into it (see my comment how I understand it:

String rootContentType = null;

// Root Part is Not set for Simple Envelope !

if (ctx.isRootPartSet()) {
//... Not in use for simple case
}

if (rootContentType == null)
rootContentType = Constants.HEADERVAL_CONTENT_TYPE_UTF8;
if (getEnvelope() != null) {

// Now really create root part - how important it is if we now how to write
this Envelope without involving Mime !!!

ctx.setRootPart(envelope, rootContentType);
} else {
//... Not in use for simple case
}

// Print the whole response to a byte array.
// Tracing into this code we'll found that all it will do it add
unnecessary header to envelope 
// The headers include Content-Type - we know which is,
// Content-id  - do we need it? Even if yes we can create any id
// Content-Transfer-Encoding - not for HTTp, anyway we force it to 8 bit
// Content-Lenght - easy to calculate

ByteArrayOutputStream payload =
new ByteArrayOutputStream(1024);
ctx.writeTo(payload);
bytes = payload.toByteArray();

// Now strip off the headers. (Grmbl, get rid of JavaMail
// for MIME support). Just intercept the Content-Type
// Remove headers which created right now



// TODO: should not send for HTTP response
headers.put("Accept-Encoding", "x-gzip");
if (Boolean.TRUE.equals(ctx.getGzip())) {
// Deflate
ByteArrayOutputStream baos =
   new ByteArrayOutputStream(bytes.length * 2);
GZIPOutputStream gzos = new GZIPOutputStream(baos);
gzos.write(bytes, offset, bytes.length - offset);
gzos.close();
baos.close();
bytes = baos.toByteArray();
offset = 0;

headers.put("Content-Encoding", "x-gzip");
}

Seems like we are doing wonderful job of running a lot unnecessary
operations,  involving a lot of memory allocations... It could be most
advanced improvement we ever done!

Best regards,
Pavel



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Using mime parts - huge drawbacks

2002-11-13 Thread Scott Nichol
Pavel,

Yes, this is a good observation.  In the case where there are no
attachments, the process could be streamlined by serializing directly.
I am still actively working on this part of the code (TransportMessage,
SOAPContext, Call) and will look at sidestepping some of the activity
where there are no attachments, just a SOAP envelope, which as you point
out is the typical scenario.

Scott Nichol

- Original Message -
From: "Pavel Ausianik" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 9:04 AM
Subject: Using mime parts - huge drawbacks


> Hello,
>
> thinking more on the current code I have found interesting thing. Most
> requests we have a simple, straight SOAP envelopes, without any
attachments.
> Looking how it is processed I have found following (traced from
> httpconnection):
>
> In SOAPHTTPConnection.send() we call TransportMessage.save().
> Let's look into it (see my comment how I understand it:
>
> String rootContentType = null;
>
> // Root Part is Not set for Simple Envelope !
>
> if (ctx.isRootPartSet()) {
> //... Not in use for simple case
> }
>
> if (rootContentType == null)
> rootContentType = Constants.HEADERVAL_CONTENT_TYPE_UTF8;
> if (getEnvelope() != null) {
>
> // Now really create root part - how important it is if we now how to
write
> this Envelope without involving Mime !!!
>
> ctx.setRootPart(envelope, rootContentType);
> } else {
> //... Not in use for simple case
> }
>
> // Print the whole response to a byte array.
> // Tracing into this code we'll found that all it will do it add
> unnecessary header to envelope
> // The headers include Content-Type - we know which is,
> // Content-id  - do we need it? Even if yes we can create any id
> // Content-Transfer-Encoding - not for HTTp, anyway we force it to 8
bit
> // Content-Lenght - easy to calculate
>
> ByteArrayOutputStream payload =
> new ByteArrayOutputStream(1024);
> ctx.writeTo(payload);
> bytes = payload.toByteArray();
>
> // Now strip off the headers. (Grmbl, get rid of JavaMail
> // for MIME support). Just intercept the Content-Type
> // Remove headers which created right now
>
> 
>
> // TODO: should not send for HTTP response
> headers.put("Accept-Encoding", "x-gzip");
> if (Boolean.TRUE.equals(ctx.getGzip())) {
> // Deflate
> ByteArrayOutputStream baos =
>new ByteArrayOutputStream(bytes.length
* 2);
> GZIPOutputStream gzos = new GZIPOutputStream(baos);
> gzos.write(bytes, offset, bytes.length - offset);
> gzos.close();
> baos.close();
> bytes = baos.toByteArray();
> offset = 0;
>
> headers.put("Content-Encoding", "x-gzip");
> }
>
> Seems like we are doing wonderful job of running a lot unnecessary
> operations,  involving a lot of memory allocations... It could be most
> advanced improvement we ever done!
>
> Best regards,
> Pavel
>
>
>
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
>
>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Serializer + deployment descriptor

2002-11-13 Thread Scott Nichol
Try putting a trailing / on the encoding:

http://schemas.xmlsoap.org/soap/encoding/

instead of

http://schemas.xmlsoap.org/soap/encoding

Scott Nichol

- Original Message -
From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 4:12 AM
Subject: Serializer + deployment descriptor


> I am really, really tired of the fact that I can not get any type
mappings
> to work in the deployment desriptor.
>
> If I have the file:
> http://xml.apache.org/xml-soap/deployment";
>   id="urn:ApiTest">
>scope="Application"
> methods="isOk getIntPair getIntArray getIntPairArray getNullObject
> getNullArray">
> 
>   
>   
> org.apache.soap.server.DOMFaultListener
>   
>
>   
> http://schemas.xmlsoap.org/soap/encoding";
>  xmlns:x="urn:ApiTest" qname="x:IntPair"
>  javaType="se.exder.api.IntPair"
>
java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
>
xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
>   
> 
>
> and try to deploy it with
>   java -classpath $CLASSPATH
org.apache.soap.server.ServiceManagerClient
> http://localhost/servlet/rpcrouter deploy filename.wsdd
> The mapping is never working (client says
> "java.lang.IllegalArgumentException: No Serializer found to serialize
a
> 'se.exder.api.IntPair' using encoding style
> 'http://schemas.xmlsoap.org/soap/encoding/'")
>
> But if I input the exact same information in the admin page
> (/soap/deploy.jsp) everything works just fine. (See attached
sceenshots).
>
> I always undeploy the service before re-deploying. I have tried the
latest
> build (2002-10-27) and I am still having the same problem.
> Why is this???
> What can I do about it?
>






> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Serializer + deployment descriptor

2002-11-13 Thread Mattias Jiderhamn
It's always the simple ones that frustrate you the most...

Anyway, a HUGE thank you!

> -Original Message-
> From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> Sent: Wednesday, November 13, 2002 6:26 PM
> To: [EMAIL PROTECTED]
> Subject: Re: Serializer + deployment descriptor
> 
> 
> Try putting a trailing / on the encoding:
> 
> http://schemas.xmlsoap.org/soap/encoding/
> 
> instead of
> 
> http://schemas.xmlsoap.org/soap/encoding
> 
> Scott Nichol
> 
> - Original Message -
> From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, November 13, 2002 4:12 AM
> Subject: Serializer + deployment descriptor
> 
> 
> > I am really, really tired of the fact that I can not get any type
> mappings
> > to work in the deployment desriptor.
> >
> > If I have the file:
> > http://xml.apache.org/xml-soap/deployment";
> >   id="urn:ApiTest">
> >> scope="Application"
> > methods="isOk getIntPair getIntArray getIntPairArray getNullObject
> > getNullArray">
> > 
> >   
> >   
> > org.apache.soap.server.DOMFaultListener
> >   
> >
> >   
> > http://schemas.xmlsoap.org/soap/encoding";
> >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> >  javaType="se.exder.api.IntPair"
> >
> java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> >
> xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> >   
> > 
> >
> > and try to deploy it with
> >   java -classpath $CLASSPATH
> org.apache.soap.server.ServiceManagerClient
> > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > The mapping is never working (client says
> > "java.lang.IllegalArgumentException: No Serializer found to serialize
> a
> > 'se.exder.api.IntPair' using encoding style
> > 'http://schemas.xmlsoap.org/soap/encoding/'")
> >
> > But if I input the exact same information in the admin page
> > (/soap/deploy.jsp) everything works just fine. (See attached
> sceenshots).
> >
> > I always undeploy the service before re-deploying. I have tried the
> latest
> > build (2002-10-27) and I am still having the same problem.
> > Why is this???
> > What can I do about it?
> >
> 
> 
> 
> 
> 
> 
> > --
> > To unsubscribe, e-mail:   
> > For additional commands, e-mail: 
> 
> 
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
> 
> 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Parameter javadocs

2002-11-13 Thread Shannon Lal
I have noticed a couple of javadocs improvements that I don´t mind making.  
What is the processes?  Shouldn´t we be submitting bugs, SCRs?




_
MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. 
http://join.msn.com/?page=features/virus


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 



Re: Serializer + deployment descriptor

2002-11-13 Thread Scott Nichol
The URI spec is at http://www.ietf.org/rfc/rfc2396.txt.

FWIW, trailing '/' is significant in the URL subset of URI.  For
example, when I point Internet Explorer to http://xml.apache.org/soap,
the response it gets is

HTTP/1.1 301 Moved Permanently
Date: Wed, 13 Nov 2002 18:53:18 GMT
Server: Apache/2.0.43 (Unix)
Location: http://xml.apache.org/soap/
Content-Length: 308
Connection: close
Content-Type: text/html; charset=iso-8859-1



301 Moved Permanently

Moved Permanently
The document has moved http://xml.apache.org/soap/";>here.

Apache/2.0.43 Server at xml.apache.org Port 80


IE magically follows the redirection to show me a page, but I am
actually seeing http://xml.apache.org/soap/, not the exact URL I
originally requested.

Scott Nichol
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 1:20 PM
Subject: RE: Serializer + deployment descriptor


> I would like to get an explannation why putting a trailing
> '/' matter so much? From a semantic point of view, the following
> two namespace names
>
> http://schemas.xmlsoap.org/soap/encoding/
> http://schemas.xmlsoap.org/soap/encoding
>
> looks the same and it is no fault of user
> that he could not get type mapping to work.
>
> Why should "simple ones that frustrate you the most"
> happen, with any software specification or implementation?
>
> Is this not a bug in some specification or implementation?
>
> Soumen Sarkar.
>
> -Original Message-
> From: Mattias Jiderhamn [mailto:mattias@;expertsystem.se]
> Sent: Wednesday, November 13, 2002 9:32 AM
> To: [EMAIL PROTECTED]
> Subject: RE: Serializer + deployment descriptor
>
>
> It's always the simple ones that frustrate you the most...
>
> Anyway, a HUGE thank you!
>
> > -Original Message-
> > From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> > Sent: Wednesday, November 13, 2002 6:26 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: Serializer + deployment descriptor
> >
> >
> > Try putting a trailing / on the encoding:
> >
> > http://schemas.xmlsoap.org/soap/encoding/
> >
> > instead of
> >
> > http://schemas.xmlsoap.org/soap/encoding
> >
> > Scott Nichol
> >
> > - Original Message -
> > From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Wednesday, November 13, 2002 4:12 AM
> > Subject: Serializer + deployment descriptor
> >
> >
> > > I am really, really tired of the fact that I can not get any type
> > mappings
> > > to work in the deployment desriptor.
> > >
> > > If I have the file:
> > > http://xml.apache.org/xml-soap/deployment";
> > >   id="urn:ApiTest">
> > >> > scope="Application"
> > > methods="isOk getIntPair getIntArray getIntPairArray
getNullObject
> > > getNullArray">
> > > 
> > >   
> > >   
> > > org.apache.soap.server.DOMFaultListener
> > >   
> > >
> > >   
> > > http://schemas.xmlsoap.org/soap/encoding";
> > >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> > >  javaType="se.exder.api.IntPair"
> > >
> > java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> > >
> >
xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> > >   
> > > 
> > >
> > > and try to deploy it with
> > >   java -classpath $CLASSPATH
> > org.apache.soap.server.ServiceManagerClient
> > > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > > The mapping is never working (client says
> > > "java.lang.IllegalArgumentException: No Serializer found to
serialize
> > a
> > > 'se.exder.api.IntPair' using encoding style
> > > 'http://schemas.xmlsoap.org/soap/encoding/'")
> > >
> > > But if I input the exact same information in the admin page
> > > (/soap/deploy.jsp) everything works just fine. (See attached
> > sceenshots).
> > >
> > > I always undeploy the service before re-deploying. I have tried
the
> > latest
> > > build (2002-10-27) and I am still having the same problem.
> > > Why is this???
> > > What can I do about it?
> > >
> >
> >
>
> --
--
> > 
> >
> >
> > > --
> > > To unsubscribe, e-mail:

> > > For additional commands, e-mail:

> >
> >
> > --
> > To unsubscribe, e-mail:

> > For additional commands, e-mail:

> >
> >
>
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
>
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
>
>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




SOAP- ENV :Fault = Protocol ???

2002-11-13 Thread Enquire
Hi All,

I have a problem with a SOAP invocation of an ATL COM
object which I have deployed (I feel imperfectly on
the Apache SOAP Server.
I however, do not have any problems with my other
deployed SOAP WebServices at the same SOAP RPCRouter
URL...

The SOAP Response returns a text/html format error as
the Apache Xerces DOMWriter/DOMFaultListener is not
happy with the format of the SOAP ENV– more
importantly both the Java SOAP Client and the Apache
SOAP Server complain about a ‘NullPointerReference’.
This leads me more to believe that it basically is a
problem with the way I have registered the SOAP
WebService using the XML deployment Descriptor.

I could not find anyone better source than here to
follow this line of enquiry to possible programmatic
success.

In the meantime, I have sparingly tried something with
the ATL COM DLL which I thought I may report to you:

i) First up, I don’t think that I have registered the
ATL COM DLL properly with the SOAP Server. I need a
proper way of naming the Object (preferably a fully
qualified name); this can be noted in the XML file
which is used as a deployment descriptor for the SOAP
WebService . To extrapolate an earlier experience with
Microsoft based COM DLLs { what I had done with the
Visual Basic COM DLL } -> I had to register the
Project Name and the Class Module name in the VB COM
DLL SOAP WebService Deployment Descriptor(XML file
again) .I need the ‘progid’ value (please note the
relevant portions under). Could you guide me in this
regard??

 

Visual Basic COM DLL




http://xml.apache.org/xml-soap/deployment";

 id="urn:demo:hello">

  





  

 
org.apache.soap.server.DOMFaultListener



 

 
**
Visual C++ ATL Com DLL
**
 



http://xml.apache.org/xml-soap/deployment";
id="urn:demo:ATL">

  











  



org.apache.soap.server.DOMFaultListener





 

 

ii) Next, I was able to register an ATL COM DLL which
is not using a BSTR (tried int*, char*…successfully
with minor though ‘telling’ code tweaking), but the
STL Registration process requires that a pointer be
used due to the constraints imposed by the ‘atl.h’
header file (standard) – btw can we change this header
so that it accepts non-pointer based datatypes? (I
foresee that there might be more code other than the
header which we may need to update in the ‘Microsoft’
implementation of ATL).

 

 

iii) Further, I was considering the reverse approach
-> ATL COM Client to non-Microsoft SOAP WebService,
say, Java.

 

iv) As of time=now, I haven’t tried testing a separate
box(computer)->>[ Client on one box and server on
another box ] scenario (memory heap allocation problem
possibly??)

 

v) Also, Java handles BSTR; it refers to it as
BinaryString!


To conclude, IMHO, I feel that the Java
NullPointerException is being thrown mainly due to the
fact that the fully qualified object name is not
available.


Please respond ASAP.

Sincerely,
<->{ R2D2 }<->

 

 

 

 

 

 



 



__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: SOAP- ENV :Fault = Protocol ???

2002-11-13 Thread Scott Nichol
A couple of things.

1. I notice you list DllMain as the method in the deployment descriptor.
DllMain is the statically linked entry point into your DLL code.  The
methods in the deployment descriptor should be COM methods.

2. The progid for an ATL COM DLL is in the .rgs file in the project.
There's probably some way to view it in the IDE, too, but I don't
remember.

3. The COM provider makes calls through IDispatch.  Your COM object
should thus have dual interface.  This can be verified in the .idl file.
Again, the IDE probably makes this available as well.

Scott Nichol

- Original Message -
From: "Enquire" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 2:46 PM
Subject: SOAP- ENV :Fault = Protocol ???


> Hi All,
>
> I have a problem with a SOAP invocation of an ATL COM
> object which I have deployed (I feel imperfectly on
> the Apache SOAP Server.
> I however, do not have any problems with my other
> deployed SOAP WebServices at the same SOAP RPCRouter
> URL...
>
> The SOAP Response returns a text/html format error as
> the Apache Xerces DOMWriter/DOMFaultListener is not
> happy with the format of the SOAP ENV- more
> importantly both the Java SOAP Client and the Apache
> SOAP Server complain about a 'NullPointerReference'.
> This leads me more to believe that it basically is a
> problem with the way I have registered the SOAP
> WebService using the XML deployment Descriptor.
>
> I could not find anyone better source than here to
> follow this line of enquiry to possible programmatic
> success.
>
> In the meantime, I have sparingly tried something with
> the ATL COM DLL which I thought I may report to you:
>
> i) First up, I don't think that I have registered the
> ATL COM DLL properly with the SOAP Server. I need a
> proper way of naming the Object (preferably a fully
> qualified name); this can be noted in the XML file
> which is used as a deployment descriptor for the SOAP
> WebService . To extrapolate an earlier experience with
> Microsoft based COM DLLs { what I had done with the
> Visual Basic COM DLL } -> I had to register the
> Project Name and the Class Module name in the VB COM
> DLL SOAP WebService Deployment Descriptor(XML file
> again) .I need the 'progid' value (please note the
> relevant portions under). Could you guide me in this
> regard??
>
>
> 
> Visual Basic COM DLL
> 
>
> 
>
>  xmlns:isd="http://xml.apache.org/xml-soap/deployment";
>
>  id="urn:demo:hello">
>
>type="org.apache.soap.providers.com.RPCProvider"
>
> scope="Application"
>
> methods="Hello">
>
> 
>
>  />
>
>   
>
>
>
org.apache.soap.server.DOMFaultListener
>
> 
>
>
>
>
> **
> Visual C++ ATL Com DLL
> **
>
>
> 
>
>  xmlns:isd="http://xml.apache.org/xml-soap/deployment";
> id="urn:demo:ATL">
>
>type="org.apache.soap.providers.com.RPCProvider"
>
>   scope="Application" methods="DllMain">
>
> 
>
>  value="Day1Server.MyFirstATLObject" />
>
> 
>
>
>
>  value="APARTMENTTHREADED" />
>
>   
>
> 
>
> org.apache.soap.server.DOMFaultListener
>
> 
>
> 
>
>
>
>
>
> ii) Next, I was able to register an ATL COM DLL which
> is not using a BSTR (tried int*, char*.successfully
> with minor though 'telling' code tweaking), but the
> STL Registration process requires that a pointer be
> used due to the constraints imposed by the 'atl.h'
> header file (standard) - btw can we change this header
> so that it accepts non-pointer based datatypes? (I
> foresee that there might be more code other than the
> header which we may need to update in the 'Microsoft'
> implementation of ATL).
>
>
>
>
>
> iii) Further, I was considering the reverse approach
> -> ATL COM Client to non-Microsoft SOAP WebService,
> say, Java.
>
>
>
> iv) As of time=now, I haven't tried testing a separate
> box(computer)->>[ Client on one box and server on
> another box ] scenario (memory heap allocation problem
> possibly??)
>
>
>
> v) Also, Java handles BSTR; it refers to it as
> BinaryString!
>
>
> To conclude, IMHO, I feel that the Java
> NullPointerException is being thrown mainly due to the
> fact that the fully qualified object name is not
> available.
>
>
> Please respond ASAP.
>
> Sincerely,
> <->{ R2D2 }<->
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> __
> Do You Yahoo!?
> Everything you'll ever need on one web page
> from News and Sport to Email and Music Charts
> http://uk.my.yahoo.com
>
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
>
>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Serializer + deployment descriptor

2002-11-13 Thread SoumenS
Scott,

In the example you have given, the web service handles
http://xml.apache.org/soap gracefully by ridirecting
to http://xml.apache.org/soap/. I beleive similar graceful
handling should be implemented for finding type mapping.
In other words the trailing / should not cause finding
type mapping to fail -- since we know what the software
developer intended to do. From a user point of view
why should the trailing '/' be significant -- I am looking
for rationale behind the spec. If we find the rationale,
it may become apparent that the rationale may not apply
in type mapping situation.

Soumen Sarkar.

-Original Message-
From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
Sent: Wednesday, November 13, 2002 11:00 AM
To: [EMAIL PROTECTED]
Subject: Re: Serializer + deployment descriptor


The URI spec is at http://www.ietf.org/rfc/rfc2396.txt.

FWIW, trailing '/' is significant in the URL subset of URI.  For
example, when I point Internet Explorer to http://xml.apache.org/soap,
the response it gets is

HTTP/1.1 301 Moved Permanently
Date: Wed, 13 Nov 2002 18:53:18 GMT
Server: Apache/2.0.43 (Unix)
Location: http://xml.apache.org/soap/
Content-Length: 308
Connection: close
Content-Type: text/html; charset=iso-8859-1



301 Moved Permanently

Moved Permanently
The document has moved http://xml.apache.org/soap/";>here.

Apache/2.0.43 Server at xml.apache.org Port 80


IE magically follows the redirection to show me a page, but I am
actually seeing http://xml.apache.org/soap/, not the exact URL I
originally requested.

Scott Nichol
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 1:20 PM
Subject: RE: Serializer + deployment descriptor


> I would like to get an explannation why putting a trailing
> '/' matter so much? From a semantic point of view, the following
> two namespace names
>
> http://schemas.xmlsoap.org/soap/encoding/
> http://schemas.xmlsoap.org/soap/encoding
>
> looks the same and it is no fault of user
> that he could not get type mapping to work.
>
> Why should "simple ones that frustrate you the most"
> happen, with any software specification or implementation?
>
> Is this not a bug in some specification or implementation?
>
> Soumen Sarkar.
>
> -Original Message-
> From: Mattias Jiderhamn [mailto:mattias@;expertsystem.se]
> Sent: Wednesday, November 13, 2002 9:32 AM
> To: [EMAIL PROTECTED]
> Subject: RE: Serializer + deployment descriptor
>
>
> It's always the simple ones that frustrate you the most...
>
> Anyway, a HUGE thank you!
>
> > -Original Message-
> > From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> > Sent: Wednesday, November 13, 2002 6:26 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: Serializer + deployment descriptor
> >
> >
> > Try putting a trailing / on the encoding:
> >
> > http://schemas.xmlsoap.org/soap/encoding/
> >
> > instead of
> >
> > http://schemas.xmlsoap.org/soap/encoding
> >
> > Scott Nichol
> >
> > - Original Message -
> > From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Wednesday, November 13, 2002 4:12 AM
> > Subject: Serializer + deployment descriptor
> >
> >
> > > I am really, really tired of the fact that I can not get any type
> > mappings
> > > to work in the deployment desriptor.
> > >
> > > If I have the file:
> > > http://xml.apache.org/xml-soap/deployment";
> > >   id="urn:ApiTest">
> > >> > scope="Application"
> > > methods="isOk getIntPair getIntArray getIntPairArray
getNullObject
> > > getNullArray">
> > > 
> > >   
> > >   
> > > org.apache.soap.server.DOMFaultListener
> > >   
> > >
> > >   
> > > http://schemas.xmlsoap.org/soap/encoding";
> > >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> > >  javaType="se.exder.api.IntPair"
> > >
> > java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> > >
> >
xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> > >   
> > > 
> > >
> > > and try to deploy it with
> > >   java -classpath $CLASSPATH
> > org.apache.soap.server.ServiceManagerClient
> > > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > > The mapping is never working (client says
> > > "java.lang.IllegalArgumentException: No Serializer found to
serialize
> > a
> > > 'se.exder.api.IntPair' using encoding style
> > > 'http://schemas.xmlsoap.org/soap/encoding/'")
> > >
> > > But if I input the exact same information in the admin page
> > > (/soap/deploy.jsp) everything works just fine. (See attached
> > sceenshots).
> > >
> > > I always undeploy the service before re-deploying. I have tried
the
> > latest
> > > build (2002-10-27) and I am still having the same problem.
> > > Why is this???
> > > What can I do about it?
> > >
> >
> >
>
> --
--
> > 
> >
> >
> > > --
> > > To unsubscribe, e-mail:

> > > For addition

RE: Serializer + deployment descriptor

2002-11-13 Thread Ran.Zfoni
Hi,

Do you have any idea/ code sample how can I write client to Apache
Tomcat configures to work over HTTPS?

Thanks.

-Original Message-
From: [EMAIL PROTECTED] [mailto:SoumenS@;Atoga.com] 
Sent: Wednesday, November 13, 2002 4:58 PM
To: [EMAIL PROTECTED]
Subject: RE: Serializer + deployment descriptor

Scott,

In the example you have given, the web service handles
http://xml.apache.org/soap gracefully by ridirecting
to http://xml.apache.org/soap/. I beleive similar graceful
handling should be implemented for finding type mapping.
In other words the trailing / should not cause finding
type mapping to fail -- since we know what the software
developer intended to do. From a user point of view
why should the trailing '/' be significant -- I am looking
for rationale behind the spec. If we find the rationale,
it may become apparent that the rationale may not apply
in type mapping situation.

Soumen Sarkar.

-Original Message-
From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
Sent: Wednesday, November 13, 2002 11:00 AM
To: [EMAIL PROTECTED]
Subject: Re: Serializer + deployment descriptor


The URI spec is at http://www.ietf.org/rfc/rfc2396.txt.

FWIW, trailing '/' is significant in the URL subset of URI.  For
example, when I point Internet Explorer to http://xml.apache.org/soap,
the response it gets is

HTTP/1.1 301 Moved Permanently
Date: Wed, 13 Nov 2002 18:53:18 GMT
Server: Apache/2.0.43 (Unix)
Location: http://xml.apache.org/soap/
Content-Length: 308
Connection: close
Content-Type: text/html; charset=iso-8859-1



301 Moved Permanently

Moved Permanently
The document has moved http://xml.apache.org/soap/";>here.

Apache/2.0.43 Server at xml.apache.org Port 80


IE magically follows the redirection to show me a page, but I am
actually seeing http://xml.apache.org/soap/, not the exact URL I
originally requested.

Scott Nichol
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 1:20 PM
Subject: RE: Serializer + deployment descriptor


> I would like to get an explannation why putting a trailing
> '/' matter so much? From a semantic point of view, the following
> two namespace names
>
> http://schemas.xmlsoap.org/soap/encoding/
> http://schemas.xmlsoap.org/soap/encoding
>
> looks the same and it is no fault of user
> that he could not get type mapping to work.
>
> Why should "simple ones that frustrate you the most"
> happen, with any software specification or implementation?
>
> Is this not a bug in some specification or implementation?
>
> Soumen Sarkar.
>
> -Original Message-
> From: Mattias Jiderhamn [mailto:mattias@;expertsystem.se]
> Sent: Wednesday, November 13, 2002 9:32 AM
> To: [EMAIL PROTECTED]
> Subject: RE: Serializer + deployment descriptor
>
>
> It's always the simple ones that frustrate you the most...
>
> Anyway, a HUGE thank you!
>
> > -Original Message-
> > From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> > Sent: Wednesday, November 13, 2002 6:26 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: Serializer + deployment descriptor
> >
> >
> > Try putting a trailing / on the encoding:
> >
> > http://schemas.xmlsoap.org/soap/encoding/
> >
> > instead of
> >
> > http://schemas.xmlsoap.org/soap/encoding
> >
> > Scott Nichol
> >
> > - Original Message -
> > From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Wednesday, November 13, 2002 4:12 AM
> > Subject: Serializer + deployment descriptor
> >
> >
> > > I am really, really tired of the fact that I can not get any type
> > mappings
> > > to work in the deployment desriptor.
> > >
> > > If I have the file:
> > > http://xml.apache.org/xml-soap/deployment";
> > >   id="urn:ApiTest">
> > >> > scope="Application"
> > > methods="isOk getIntPair getIntArray getIntPairArray
getNullObject
> > > getNullArray">
> > > 
> > >   
> > >   
> > > org.apache.soap.server.DOMFaultListener
> > >   
> > >
> > >   
> > > http://schemas.xmlsoap.org/soap/encoding";
> > >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> > >  javaType="se.exder.api.IntPair"
> > >
> > java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> > >
> >
xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> > >   
> > > 
> > >
> > > and try to deploy it with
> > >   java -classpath $CLASSPATH
> > org.apache.soap.server.ServiceManagerClient
> > > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > > The mapping is never working (client says
> > > "java.lang.IllegalArgumentException: No Serializer found to
serialize
> > a
> > > 'se.exder.api.IntPair' using encoding style
> > > 'http://schemas.xmlsoap.org/soap/encoding/'")
> > >
> > > But if I input the exact same information in the admin page
> > > (/soap/deploy.jsp) everything works just fine. (See attached
> > sceenshots).
> > >
> > > I always undeploy the service before re-deploying. I have tried
the
> > latest
> > > build (2002-

writing java client to Apache Tomcat over HTTPS

2002-11-13 Thread Ran.Zfoni








Can anyone explain/ send me code sample of how should I work
to establish connection to deployed services on Apache Tomcat server?

 








Re: Serializer + deployment descriptor

2002-11-13 Thread Scott Nichol
The client just uses the https scheme in the endpoint URL for the
service.

Scott Nichol

- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 5:03 PM
Subject: RE: Serializer + deployment descriptor


Hi,

Do you have any idea/ code sample how can I write client to Apache
Tomcat configures to work over HTTPS?

Thanks.

-Original Message-
From: [EMAIL PROTECTED] [mailto:SoumenS@;Atoga.com]
Sent: Wednesday, November 13, 2002 4:58 PM
To: [EMAIL PROTECTED]
Subject: RE: Serializer + deployment descriptor

Scott,

In the example you have given, the web service handles
http://xml.apache.org/soap gracefully by ridirecting
to http://xml.apache.org/soap/. I beleive similar graceful
handling should be implemented for finding type mapping.
In other words the trailing / should not cause finding
type mapping to fail -- since we know what the software
developer intended to do. From a user point of view
why should the trailing '/' be significant -- I am looking
for rationale behind the spec. If we find the rationale,
it may become apparent that the rationale may not apply
in type mapping situation.

Soumen Sarkar.

-Original Message-
From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
Sent: Wednesday, November 13, 2002 11:00 AM
To: [EMAIL PROTECTED]
Subject: Re: Serializer + deployment descriptor


The URI spec is at http://www.ietf.org/rfc/rfc2396.txt.

FWIW, trailing '/' is significant in the URL subset of URI.  For
example, when I point Internet Explorer to http://xml.apache.org/soap,
the response it gets is

HTTP/1.1 301 Moved Permanently
Date: Wed, 13 Nov 2002 18:53:18 GMT
Server: Apache/2.0.43 (Unix)
Location: http://xml.apache.org/soap/
Content-Length: 308
Connection: close
Content-Type: text/html; charset=iso-8859-1



301 Moved Permanently

Moved Permanently
The document has moved http://xml.apache.org/soap/";>here.

Apache/2.0.43 Server at xml.apache.org Port 80


IE magically follows the redirection to show me a page, but I am
actually seeing http://xml.apache.org/soap/, not the exact URL I
originally requested.

Scott Nichol
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 1:20 PM
Subject: RE: Serializer + deployment descriptor


> I would like to get an explannation why putting a trailing
> '/' matter so much? From a semantic point of view, the following
> two namespace names
>
> http://schemas.xmlsoap.org/soap/encoding/
> http://schemas.xmlsoap.org/soap/encoding
>
> looks the same and it is no fault of user
> that he could not get type mapping to work.
>
> Why should "simple ones that frustrate you the most"
> happen, with any software specification or implementation?
>
> Is this not a bug in some specification or implementation?
>
> Soumen Sarkar.
>
> -Original Message-
> From: Mattias Jiderhamn [mailto:mattias@;expertsystem.se]
> Sent: Wednesday, November 13, 2002 9:32 AM
> To: [EMAIL PROTECTED]
> Subject: RE: Serializer + deployment descriptor
>
>
> It's always the simple ones that frustrate you the most...
>
> Anyway, a HUGE thank you!
>
> > -Original Message-
> > From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> > Sent: Wednesday, November 13, 2002 6:26 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: Serializer + deployment descriptor
> >
> >
> > Try putting a trailing / on the encoding:
> >
> > http://schemas.xmlsoap.org/soap/encoding/
> >
> > instead of
> >
> > http://schemas.xmlsoap.org/soap/encoding
> >
> > Scott Nichol
> >
> > - Original Message -
> > From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Wednesday, November 13, 2002 4:12 AM
> > Subject: Serializer + deployment descriptor
> >
> >
> > > I am really, really tired of the fact that I can not get any type
> > mappings
> > > to work in the deployment desriptor.
> > >
> > > If I have the file:
> > > http://xml.apache.org/xml-soap/deployment";
> > >   id="urn:ApiTest">
> > >> > scope="Application"
> > > methods="isOk getIntPair getIntArray getIntPairArray
getNullObject
> > > getNullArray">
> > > 
> > >   
> > >   
> > > org.apache.soap.server.DOMFaultListener
> > >   
> > >
> > >   
> > > http://schemas.xmlsoap.org/soap/encoding";
> > >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> > >  javaType="se.exder.api.IntPair"
> > >
> > java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> > >
> >
xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> > >   
> > > 
> > >
> > > and try to deploy it with
> > >   java -classpath $CLASSPATH
> > org.apache.soap.server.ServiceManagerClient
> > > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > > The mapping is never working (client says
> > > "java.lang.IllegalArgumentException: No Serializer found to
serialize
> > a
> > > 'se.exder.api.IntPair' using encoding style
> > > 'http://schemas.xmlsoap.org/soap/encoding/'")
> > 

Re: Serializer + deployment descriptor

2002-11-13 Thread Scott Nichol
The SOAP spec defines two namespace URIs in Section 3
(http://www.w3.org/TR/SOAP/#_Toc478383492).  These are the exact
namespace URIs that must be used.  For example, using any variation,
such as not having the trailing '/', in an XML document would cause that
document to fail validation against a schema.

Scott Nichol

- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 4:57 PM
Subject: RE: Serializer + deployment descriptor


> Scott,
>
> In the example you have given, the web service handles
> http://xml.apache.org/soap gracefully by ridirecting
> to http://xml.apache.org/soap/. I beleive similar graceful
> handling should be implemented for finding type mapping.
> In other words the trailing / should not cause finding
> type mapping to fail -- since we know what the software
> developer intended to do. From a user point of view
> why should the trailing '/' be significant -- I am looking
> for rationale behind the spec. If we find the rationale,
> it may become apparent that the rationale may not apply
> in type mapping situation.
>
> Soumen Sarkar.
>
> -Original Message-
> From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> Sent: Wednesday, November 13, 2002 11:00 AM
> To: [EMAIL PROTECTED]
> Subject: Re: Serializer + deployment descriptor
>
>
> The URI spec is at http://www.ietf.org/rfc/rfc2396.txt.
>
> FWIW, trailing '/' is significant in the URL subset of URI.  For
> example, when I point Internet Explorer to http://xml.apache.org/soap,
> the response it gets is
>
> HTTP/1.1 301 Moved Permanently
> Date: Wed, 13 Nov 2002 18:53:18 GMT
> Server: Apache/2.0.43 (Unix)
> Location: http://xml.apache.org/soap/
> Content-Length: 308
> Connection: close
> Content-Type: text/html; charset=iso-8859-1
>
> 
> 
> 301 Moved Permanently
> 
> Moved Permanently
> The document has moved  href="http://xml.apache.org/soap/";>here.
> 
> Apache/2.0.43 Server at xml.apache.org Port 80
> 
>
> IE magically follows the redirection to show me a page, but I am
> actually seeing http://xml.apache.org/soap/, not the exact URL I
> originally requested.
>
> Scott Nichol
> - Original Message -
> From: <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, November 13, 2002 1:20 PM
> Subject: RE: Serializer + deployment descriptor
>
>
> > I would like to get an explannation why putting a trailing
> > '/' matter so much? From a semantic point of view, the following
> > two namespace names
> >
> > http://schemas.xmlsoap.org/soap/encoding/
> > http://schemas.xmlsoap.org/soap/encoding
> >
> > looks the same and it is no fault of user
> > that he could not get type mapping to work.
> >
> > Why should "simple ones that frustrate you the most"
> > happen, with any software specification or implementation?
> >
> > Is this not a bug in some specification or implementation?
> >
> > Soumen Sarkar.
> >
> > -Original Message-
> > From: Mattias Jiderhamn [mailto:mattias@;expertsystem.se]
> > Sent: Wednesday, November 13, 2002 9:32 AM
> > To: [EMAIL PROTECTED]
> > Subject: RE: Serializer + deployment descriptor
> >
> >
> > It's always the simple ones that frustrate you the most...
> >
> > Anyway, a HUGE thank you!
> >
> > > -Original Message-
> > > From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> > > Sent: Wednesday, November 13, 2002 6:26 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: Re: Serializer + deployment descriptor
> > >
> > >
> > > Try putting a trailing / on the encoding:
> > >
> > > http://schemas.xmlsoap.org/soap/encoding/
> > >
> > > instead of
> > >
> > > http://schemas.xmlsoap.org/soap/encoding
> > >
> > > Scott Nichol
> > >
> > > - Original Message -
> > > From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Wednesday, November 13, 2002 4:12 AM
> > > Subject: Serializer + deployment descriptor
> > >
> > >
> > > > I am really, really tired of the fact that I can not get any
type
> > > mappings
> > > > to work in the deployment desriptor.
> > > >
> > > > If I have the file:
> > > > http://xml.apache.org/xml-soap/deployment";
> > > >   id="urn:ApiTest">
> > > >> > > scope="Application"
> > > > methods="isOk getIntPair getIntArray getIntPairArray
> getNullObject
> > > > getNullArray">
> > > > 
> > > >   
> > > >   
> > > > org.apache.soap.server.DOMFaultListener
> > > >   
> > > >
> > > >   
> > > >  encodingStyle="http://schemas.xmlsoap.org/soap/encoding";
> > > >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> > > >  javaType="se.exder.api.IntPair"
> > > >
> > >
java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> > > >
> > >
> xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> > > >   
> > > > 
> > > >
> > > > and try to deploy it with
> > > >   java -classpath $CLASSPATH
> > > org.apache.soap.server.ServiceManagerClient
> > > > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > > > The mapp

RE: Serializer + deployment descriptor

2002-11-13 Thread SoumenS
I knew that it would go to namespace schema comparison
where it has to match character by character. Seperators
like '/' does not carry special significance in
namespace names (i.e do not imply any structure). From
a structural point of view presence of trailing '/' does
not matter but as I said '/' is namespace does not imply
any structure.

So help could be in the form of documentation or error
messages.

-Original Message-
From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
Sent: Wednesday, November 13, 2002 3:11 PM
To: [EMAIL PROTECTED]
Subject: Re: Serializer + deployment descriptor


The SOAP spec defines two namespace URIs in Section 3
(http://www.w3.org/TR/SOAP/#_Toc478383492).  These are the exact
namespace URIs that must be used.  For example, using any variation,
such as not having the trailing '/', in an XML document would cause that
document to fail validation against a schema.

Scott Nichol

- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 4:57 PM
Subject: RE: Serializer + deployment descriptor


> Scott,
>
> In the example you have given, the web service handles
> http://xml.apache.org/soap gracefully by ridirecting
> to http://xml.apache.org/soap/. I beleive similar graceful
> handling should be implemented for finding type mapping.
> In other words the trailing / should not cause finding
> type mapping to fail -- since we know what the software
> developer intended to do. From a user point of view
> why should the trailing '/' be significant -- I am looking
> for rationale behind the spec. If we find the rationale,
> it may become apparent that the rationale may not apply
> in type mapping situation.
>
> Soumen Sarkar.
>
> -Original Message-
> From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> Sent: Wednesday, November 13, 2002 11:00 AM
> To: [EMAIL PROTECTED]
> Subject: Re: Serializer + deployment descriptor
>
>
> The URI spec is at http://www.ietf.org/rfc/rfc2396.txt.
>
> FWIW, trailing '/' is significant in the URL subset of URI.  For
> example, when I point Internet Explorer to http://xml.apache.org/soap,
> the response it gets is
>
> HTTP/1.1 301 Moved Permanently
> Date: Wed, 13 Nov 2002 18:53:18 GMT
> Server: Apache/2.0.43 (Unix)
> Location: http://xml.apache.org/soap/
> Content-Length: 308
> Connection: close
> Content-Type: text/html; charset=iso-8859-1
>
> 
> 
> 301 Moved Permanently
> 
> Moved Permanently
> The document has moved  href="http://xml.apache.org/soap/";>here.
> 
> Apache/2.0.43 Server at xml.apache.org Port 80
> 
>
> IE magically follows the redirection to show me a page, but I am
> actually seeing http://xml.apache.org/soap/, not the exact URL I
> originally requested.
>
> Scott Nichol
> - Original Message -
> From: <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, November 13, 2002 1:20 PM
> Subject: RE: Serializer + deployment descriptor
>
>
> > I would like to get an explannation why putting a trailing
> > '/' matter so much? From a semantic point of view, the following
> > two namespace names
> >
> > http://schemas.xmlsoap.org/soap/encoding/
> > http://schemas.xmlsoap.org/soap/encoding
> >
> > looks the same and it is no fault of user
> > that he could not get type mapping to work.
> >
> > Why should "simple ones that frustrate you the most"
> > happen, with any software specification or implementation?
> >
> > Is this not a bug in some specification or implementation?
> >
> > Soumen Sarkar.
> >
> > -Original Message-
> > From: Mattias Jiderhamn [mailto:mattias@;expertsystem.se]
> > Sent: Wednesday, November 13, 2002 9:32 AM
> > To: [EMAIL PROTECTED]
> > Subject: RE: Serializer + deployment descriptor
> >
> >
> > It's always the simple ones that frustrate you the most...
> >
> > Anyway, a HUGE thank you!
> >
> > > -Original Message-
> > > From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> > > Sent: Wednesday, November 13, 2002 6:26 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: Re: Serializer + deployment descriptor
> > >
> > >
> > > Try putting a trailing / on the encoding:
> > >
> > > http://schemas.xmlsoap.org/soap/encoding/
> > >
> > > instead of
> > >
> > > http://schemas.xmlsoap.org/soap/encoding
> > >
> > > Scott Nichol
> > >
> > > - Original Message -
> > > From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Wednesday, November 13, 2002 4:12 AM
> > > Subject: Serializer + deployment descriptor
> > >
> > >
> > > > I am really, really tired of the fact that I can not get any
type
> > > mappings
> > > > to work in the deployment desriptor.
> > > >
> > > > If I have the file:
> > > > http://xml.apache.org/xml-soap/deployment";
> > > >   id="urn:ApiTest">
> > > >> > > scope="Application"
> > > > methods="isOk getIntPair getIntArray getIntPairArray
> getNullObject
> > > > getNullArray">
> > > > 
> > > >   
> > > >   
> > > > org.apache.soap.server.DOM

cvs commit: xml-soap/java/src/org/apache/soap Constants.java

2002-11-13 Thread snichol
snichol 2002/11/13 21:00:42

  Modified:java/src/org/apache/soap/transport TransportMessage.java
   java/src/org/apache/soap Constants.java
  Log:
  Fix a bug introduced in previous changes when their is an envelope editor
  and no envelope was explitictly specified (just a rootPart in SOAPContext).
  Prevent duplicate assignment of rootPart when original envelope is empty.
  Side-step MIME serialization when the message is only a SOAP envelope.
  Improve MIME serialization by starting with a larger byte output stream.
  Move some constants.
  
  Revision  ChangesPath
  1.19  +207 -112  
xml-soap/java/src/org/apache/soap/transport/TransportMessage.java
  
  Index: TransportMessage.java
  ===
  RCS file: 
/home/cvs/xml-soap/java/src/org/apache/soap/transport/TransportMessage.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- TransportMessage.java 12 Nov 2002 14:34:56 -  1.18
  +++ TransportMessage.java 14 Nov 2002 05:00:42 -  1.19
  @@ -89,6 +89,19 @@
   protected String envelope = null;
   protected Hashtable headers = null;
   protected SOAPContext ctx = null;
  +/**
  + * Tracks whether the SOAPContext rootPart is the same as the Envelope.
  + * Used for outgoing messages to avoid multiple assignment of the rootPart.
  + */
  +protected boolean rootPartIsEnvelope;
  +/**
  + * The envelope in DOM form (for incoming messages).
  + */
  +protected Document envelopeDocument = null;
  +/**
  + * The envelope in SOAP form (for incoming messages).
  + */
  +protected Envelope soapEnvelope = null;
   
   /**
* No-argument constructor.
  @@ -97,13 +110,22 @@
   }
   
   /**
  - * Create a message from an already built envelope and/or
  + * Creates a message from an already built envelope and/or
* SOAPContext. The envelope argument may be null.
  - * Call save() to generate the byte array.
  + * 
  + * Call editOutgoing() to filter/transform the string SOAP envelope.
  + * Call save() to generate the byte array.
  + * 
  + *
  + * @param envelope The SOAP envelope.  Can be null.
  + * @param ctx The SOAP context.  Can contain the SOAP envelope if the
  + *envelope parameter is null.
  + * @param headers The transport headers.
*/
   public TransportMessage(String envelope, SOAPContext ctx,
   Hashtable headers) {
   this.envelope = envelope;
  +rootPartIsEnvelope = false;
   this.ctx = ctx;
   if (headers != null)
   this.headers = headers;
  @@ -112,10 +134,25 @@
   }
   
   /**
  - * Create a message from an InputStream. This reads the InputStream and
  + * Creates a message from an InputStream. This reads the InputStream and
* stores it in a byte array.
  - * Call read() to extract the SOAPContext and SOAP
  - * envelope from the byte array.
  + * 
  + * Call read() to extract the SOAPContext and SOAP
  + * envelope (as a String) from the byte array.
  + * Call editIncoming() to filter/transform the string SOAP envelope.
  + * Call unmarshall() to extract the DOM and SOAP envelope
  + * from the string SOAP envelope.
  + * 
  + *
  + * @param is The stream from which to read.  Use a buffered stream if that
  + *   would help performance.
  + * @param contentLength The number of bytes to read.  Negative values
  + *  mean read to end of stream.
  + * @param contentType The content type (MIME format, e.g. text/xml).
  + * @param ctx The SOAP context.
  + * @param headers The transport headers, e.g. HTTP headers.
  + * @exception IOException For errors reading the stream.
  + * @exception SOAPException If fewer than contentLength bytes can be read.
*/
   public TransportMessage(InputStream is, int contentLength,
   String contentType, SOAPContext ctx,
  @@ -197,15 +234,22 @@
   editor.editOutgoing(getEnvelopeReader(), tout);
   tout.flush();
   envelope = tout.toString();
  +rootPartIsEnvelope = false;
   }
   }
   
   /**
  - * Interpret byte array and extract SOAPContext and SOAP envelope (as
  - * a String). Make sure content type is set before calling this.
  + * Extracts the SOAPContext and SOAP envelope (as a String) from the
  + * byte array read in the constructor.
  + * Make sure content type is set before calling this.
* Note that in the Messaging scenario, the root type is not necessarily
  - * a SOAP envelope, or even text. If it is text, the text is returned and
  - * it is up to the invoker to check the root part's Content-Type
  + * a SOAP enve

RE: Serializer + deployment descriptor

2002-11-13 Thread Mattias Jiderhamn
Now I also found *why* I made the misstake.
In the /docs/guide/deploy.html#typemapping you can find
"Where encoding-uri is the URI for the encoding method (i.e.
http://schemas.xmlsoap.org/soap/encoding for the standard SOAP encoding,)"
Without the trailing /!

May I suggest a fix?

> -Original Message-
> From: Scott Nichol [mailto:snicholnews@;scottnichol.com]
> Sent: Wednesday, November 13, 2002 6:26 PM
> To: [EMAIL PROTECTED]
> Subject: Re: Serializer + deployment descriptor
>
>
> Try putting a trailing / on the encoding:
>
> http://schemas.xmlsoap.org/soap/encoding/
>
> instead of
>
> http://schemas.xmlsoap.org/soap/encoding
>
> Scott Nichol
>
> - Original Message -
> From: "Mattias Jiderhamn" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, November 13, 2002 4:12 AM
> Subject: Serializer + deployment descriptor
>
>
> > I am really, really tired of the fact that I can not get any type
> mappings
> > to work in the deployment desriptor.
> >
> > If I have the file:
> > http://xml.apache.org/xml-soap/deployment";
> >   id="urn:ApiTest">
> >> scope="Application"
> > methods="isOk getIntPair getIntArray getIntPairArray getNullObject
> > getNullArray">
> > 
> >   
> >   
> > org.apache.soap.server.DOMFaultListener
> >   
> >
> >   
> > http://schemas.xmlsoap.org/soap/encoding";
> >  xmlns:x="urn:ApiTest" qname="x:IntPair"
> >  javaType="se.exder.api.IntPair"
> >
> java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
> >
> xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
> >   
> > 
> >
> > and try to deploy it with
> >   java -classpath $CLASSPATH
> org.apache.soap.server.ServiceManagerClient
> > http://localhost/servlet/rpcrouter deploy filename.wsdd
> > The mapping is never working (client says
> > "java.lang.IllegalArgumentException: No Serializer found to serialize
> a
> > 'se.exder.api.IntPair' using encoding style
> > 'http://schemas.xmlsoap.org/soap/encoding/'")
> >
> > But if I input the exact same information in the admin page
> > (/soap/deploy.jsp) everything works just fine. (See attached
> sceenshots).
> >
> > I always undeploy the service before re-deploying. I have tried the
> latest
> > build (2002-10-27) and I am still having the same problem.
> > Why is this???
> > What can I do about it?
> >
>
>
> 
> 
>
>
> > --
> > To unsubscribe, e-mail:   
> > For additional commands, e-mail: 
>
>
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
>
>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: