You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-user@jakarta.apache.org by Iwan Birrer <iw...@bluewin.ch> on 2002/11/23 20:12:59 UTC

webdavClient: proppatch - Bad Request( 400 )

Hello,

I used slide now for a few days and everything worked ok till I wanted to
use the proppatch methods. I alway get a Bad Request (400) from the Server.

Find and search Methods are working just fine.

My configuration: slide 1.0.16
Server: Exchange 2000

I tried the following command in the command line tool, and it went wrong as
well.

proppatch /public/contacts/myContact.EML urn:schemas:contacts:givenName
newName

What am I doing wrong?

Iwan



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Andreas Probst <an...@gmx.net>.
Hello Iwan,

I think Slide client command tool can't proppatch with a 
different namespace than DAV:, because DAV: is always added as 
namespace. If you write your own code or change the existing 
code you can use other namespaces, too. 
See src/webdav/client/src/org/apache/webdav/cmd/Slide.java

Andreas


On 23 Nov 2002 at 20:12, Iwan Birrer wrote:

> Hello,
> 
> I used slide now for a few days and everything worked ok till I
> wanted to use the proppatch methods. I alway get a Bad Request
> (400) from the Server.
> 
> Find and search Methods are working just fine.
> 
> My configuration: slide 1.0.16
> Server: Exchange 2000
> 
> I tried the following command in the command line tool, and it
> went wrong as well.
> 
> proppatch /public/contacts/myContact.EML
> urn:schemas:contacts:givenName newName
> 
> What am I doing wrong?
> 
> Iwan
> 
> 
> 
> --
> To unsubscribe, e-mail:  
> <ma...@jakarta.apache.org> For additional
> commands, e-mail: <ma...@jakarta.apache.org>
> 



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Iwan Birrer <ib...@hsr.ch>.
I don't think that this is possible with the implementation used. In
PropPatchMethod they used XMLPrinter from org.apache.util and not QName or
NSStack, but I will have a look at it.

Iwan
----- Original Message -----
From: "Sung-Gu" <je...@apache.org>
To: "Slide Users Mailing List" <sl...@jakarta.apache.org>
Sent: Monday, November 25, 2002 11:33 AM
Subject: Re: webdavClient: proppatch - Bad Request( 400 )


> > ----- Original Message -----
> > From: "Iwan Birrer" <ib...@hsr.ch>
> >
> > > I changed the generateQuery() method of the PropPatchMethod Class, so
> that
>
> By the way, do you try to have multiple namespaces with QName or NSStack?
> Then that will be so great!  ;)
>
> Sung-Gu
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Sung-Gu <je...@apache.org>.
> ----- Original Message -----
> From: "Iwan Birrer" <ib...@hsr.ch>
>
> > I changed the generateQuery() method of the PropPatchMethod Class, so
that

By the way, do you try to have multiple namespaces with QName or NSStack?
Then that will be so great!  ;)

Sung-Gu


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Sung-Gu <je...@apache.org>.
----- Original Message -----
From: "Iwan Birrer" <ib...@hsr.ch>


> I've solved the problem. It was, like you said, a problem with the xml
> namespace.
> I changed the generateQuery() method of the PropPatchMethod Class, so that
> the namespaces are declared in the root element. Now it works for the
> exchange Server, but I am not sure it it works with other webdav server..
>
> If somebody wants to have the code, just mail me.

We will be pleased to share your solution...  ;)
Please post your patch on the dev mailling-list.

Sung-Gu


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Iwan Birrer <ib...@hsr.ch>.
I've solved the problem. It was, like you said, a problem with the xml
namespace.
I changed the generateQuery() method of the PropPatchMethod Class, so that
the namespaces are declared in the root element. Now it works for the
exchange Server, but I am not sure it it works with other webdav server..

If somebody wants to have the code, just mail me.

Thanks everbody for helping !

Iwan
----- Original Message -----
From: "Sung-Gu" <je...@apache.org>
To: "Slide Users Mailing List" <sl...@jakarta.apache.org>
Sent: Sunday, November 24, 2002 8:13 PM
Subject: Re: webdavClient: proppatch - Bad Request( 400 )


>
> ----- Original Message -----
> From: "Iwan Birrer" <ib...@hsr.ch>
>
> > > I'm going to give you a hint that might be useful for you.
> > > To fix your problem, look into src\org\apache\util\QName
> > > and NSStack.java.
> > >
> > > The reason why they are related with this is the way to
> > > declare the new xml namespace.   I guess the xml parser
> > > on your servers couldn't parse colon signs not as a namespace.
> >
> > The strange thing is that it it works for propfind.
> >
> > Where is the best place in the code to set the query? So that I can try
> some
> > different queries easily.
>
> Hi,
> Please look into src/org.apache.webdav.lib.methods.PropPatchMethod.java
>
> Sung-Gu
>
> > > (What's ur web server and xml parser? Helpful to others to know it?)
> >
> > Webserver: IIS 5.0
> > XML Parser: MSXML Core Services 4.0 (SP1)
> >
> > > So it's needed to declare and use it, I guess.  And I hope.
> > > Whenever it's set a prop with a new namespace, it should
> > > be distinguished by the client.  I hope it's helpful to you.
> > > I may expect a patch from anyone and a solution to be fixed.
> > >
> > > Sung-Gu
> > >
> > > P.S.: If I get the problem wrong, please don't hesistate to point it.
> >
> > Thanks a lot for your help!
> >
> > > ----- Original Message -----
> > > From: "Kevin Moran" <gr...@yahoo.com>
> > > To: "Slide Users Mailing List" <sl...@jakarta.apache.org>
> > > Sent: Sunday, November 24, 2002 8:03 AM
> > > Subject: Re: webdavClient: proppatch - Bad Request( 400 )
> > >
> > >
> > > > Hi,
> > > >     I'm seeing the same thing.  I've tried to use
> > > > proppatch with two recent cuts of the code (10/01/2002
> > > > and 11/22/2002) and both exhibit the same behavior.
> > > > This is a critical bug for me as my app has to be able
> > > > to call proppatch on a document to set or reset its
> > > > content type.  Unfortunately, because I need
> > > > versioning support, I can't revert to 1.0.16 where I
> > > > know this works.  Anyone know how to fix this?  I'm
> > > > willing to wade into the code if I have an idea of
> > > > where the problem might be.
> > > >
> > > > Thanks,
> > > > -kevin
> > > >
> > > > P.S. I'm running JDK 1.4.0 under Red Hat 7.2.
> > > >
> > > > --- Iwan Birrer <iw...@bluewin.ch> wrote:
> > > > > Hello,
> > > > >
> > > > > I used slide now for a few days and everything
> > > > > worked ok till I wanted to
> > > > > use the proppatch methods. I alway get a Bad Request
> > > > > (400) from the Server.
> > > > >
> > > > > Find and search Methods are working just fine.
> > > > >
> > > > > My configuration: slide 1.0.16
> > > > > Server: Exchange 2000
> > > > >
> > > > > I tried the following command in the command line
> > > > > tool, and it went wrong as
> > > > > well.
> > > > >
> > > > > proppatch /public/contacts/myContact.EML
> > > > > urn:schemas:contacts:givenName
> > > > > newName
> > > > >
> > > > > What am I doing wrong?
> > > > >
> > > > > Iwan
> >
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Sung-Gu <je...@apache.org>.
----- Original Message -----
From: "Iwan Birrer" <ib...@hsr.ch>

> > I'm going to give you a hint that might be useful for you.
> > To fix your problem, look into src\org\apache\util\QName
> > and NSStack.java.
> >
> > The reason why they are related with this is the way to
> > declare the new xml namespace.   I guess the xml parser
> > on your servers couldn't parse colon signs not as a namespace.
>
> The strange thing is that it it works for propfind.
>
> Where is the best place in the code to set the query? So that I can try
some
> different queries easily.

Hi,
Please look into src/org.apache.webdav.lib.methods.PropPatchMethod.java

Sung-Gu

> > (What's ur web server and xml parser? Helpful to others to know it?)
>
> Webserver: IIS 5.0
> XML Parser: MSXML Core Services 4.0 (SP1)
>
> > So it's needed to declare and use it, I guess.  And I hope.
> > Whenever it's set a prop with a new namespace, it should
> > be distinguished by the client.  I hope it's helpful to you.
> > I may expect a patch from anyone and a solution to be fixed.
> >
> > Sung-Gu
> >
> > P.S.: If I get the problem wrong, please don't hesistate to point it.
>
> Thanks a lot for your help!
>
> > ----- Original Message -----
> > From: "Kevin Moran" <gr...@yahoo.com>
> > To: "Slide Users Mailing List" <sl...@jakarta.apache.org>
> > Sent: Sunday, November 24, 2002 8:03 AM
> > Subject: Re: webdavClient: proppatch - Bad Request( 400 )
> >
> >
> > > Hi,
> > >     I'm seeing the same thing.  I've tried to use
> > > proppatch with two recent cuts of the code (10/01/2002
> > > and 11/22/2002) and both exhibit the same behavior.
> > > This is a critical bug for me as my app has to be able
> > > to call proppatch on a document to set or reset its
> > > content type.  Unfortunately, because I need
> > > versioning support, I can't revert to 1.0.16 where I
> > > know this works.  Anyone know how to fix this?  I'm
> > > willing to wade into the code if I have an idea of
> > > where the problem might be.
> > >
> > > Thanks,
> > > -kevin
> > >
> > > P.S. I'm running JDK 1.4.0 under Red Hat 7.2.
> > >
> > > --- Iwan Birrer <iw...@bluewin.ch> wrote:
> > > > Hello,
> > > >
> > > > I used slide now for a few days and everything
> > > > worked ok till I wanted to
> > > > use the proppatch methods. I alway get a Bad Request
> > > > (400) from the Server.
> > > >
> > > > Find and search Methods are working just fine.
> > > >
> > > > My configuration: slide 1.0.16
> > > > Server: Exchange 2000
> > > >
> > > > I tried the following command in the command line
> > > > tool, and it went wrong as
> > > > well.
> > > >
> > > > proppatch /public/contacts/myContact.EML
> > > > urn:schemas:contacts:givenName
> > > > newName
> > > >
> > > > What am I doing wrong?
> > > >
> > > > Iwan
>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Iwan Birrer <ib...@hsr.ch>.
Hello,

> Hi,
>
> I'm going to give you a hint that might be useful for you.
> To fix your problem, look into src\org\apache\util\QName
> and NSStack.java.
>
> The reason why they are related with this is the way to
> declare the new xml namespace.   I guess the xml parser
> on your servers couldn't parse colon signs not as a namespace.

The strange thing is that it it works for propfind.

Where is the best place in the code to set the query? So that I can try some
different queries easily.
> (What's ur web server and xml parser? Helpful to others to know it?)

Webserver: IIS 5.0
XML Parser: MSXML Core Services 4.0 (SP1)

> So it's needed to declare and use it, I guess.  And I hope.
> Whenever it's set a prop with a new namespace, it should
> be distinguished by the client.  I hope it's helpful to you.
> I may expect a patch from anyone and a solution to be fixed.
>
> Sung-Gu
>
> P.S.: If I get the problem wrong, please don't hesistate to point it.

Thanks a lot for your help!

> ----- Original Message -----
> From: "Kevin Moran" <gr...@yahoo.com>
> To: "Slide Users Mailing List" <sl...@jakarta.apache.org>
> Sent: Sunday, November 24, 2002 8:03 AM
> Subject: Re: webdavClient: proppatch - Bad Request( 400 )
>
>
> > Hi,
> >     I'm seeing the same thing.  I've tried to use
> > proppatch with two recent cuts of the code (10/01/2002
> > and 11/22/2002) and both exhibit the same behavior.
> > This is a critical bug for me as my app has to be able
> > to call proppatch on a document to set or reset its
> > content type.  Unfortunately, because I need
> > versioning support, I can't revert to 1.0.16 where I
> > know this works.  Anyone know how to fix this?  I'm
> > willing to wade into the code if I have an idea of
> > where the problem might be.
> >
> > Thanks,
> > -kevin
> >
> > P.S. I'm running JDK 1.4.0 under Red Hat 7.2.
> >
> > --- Iwan Birrer <iw...@bluewin.ch> wrote:
> > > Hello,
> > >
> > > I used slide now for a few days and everything
> > > worked ok till I wanted to
> > > use the proppatch methods. I alway get a Bad Request
> > > (400) from the Server.
> > >
> > > Find and search Methods are working just fine.
> > >
> > > My configuration: slide 1.0.16
> > > Server: Exchange 2000
> > >
> > > I tried the following command in the command line
> > > tool, and it went wrong as
> > > well.
> > >
> > > proppatch /public/contacts/myContact.EML
> > > urn:schemas:contacts:givenName
> > > newName
> > >
> > > What am I doing wrong?
> > >
> > > Iwan
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Sung-Gu <je...@apache.org>.
Hi,

I'm going to give you a hint that might be useful for you.
To fix your problem, look into src\org\apache\util\QName
and NSStack.java.

The reason why they are related with this is the way to
declare the new xml namespace.   I guess the xml parser
on your servers couldn't parse colon signs not as a namespace.
(What's ur web server and xml parser? Helpful to others to know it?)
So it's needed to declare and use it, I guess.  And I hope.

Whenever it's set a prop with a new namespace, it should
be distinguished by the client.  I hope it's helpful to you.
I may expect a patch from anyone and a solution to be fixed.

Sung-Gu

P.S.: If I get the problem wrong, please don't hesistate to point it.

----- Original Message ----- 
From: "Kevin Moran" <gr...@yahoo.com>
To: "Slide Users Mailing List" <sl...@jakarta.apache.org>
Sent: Sunday, November 24, 2002 8:03 AM
Subject: Re: webdavClient: proppatch - Bad Request( 400 )


> Hi,
>     I'm seeing the same thing.  I've tried to use
> proppatch with two recent cuts of the code (10/01/2002
> and 11/22/2002) and both exhibit the same behavior. 
> This is a critical bug for me as my app has to be able
> to call proppatch on a document to set or reset its
> content type.  Unfortunately, because I need
> versioning support, I can't revert to 1.0.16 where I
> know this works.  Anyone know how to fix this?  I'm
> willing to wade into the code if I have an idea of
> where the problem might be.
> 
> Thanks,
> -kevin
> 
> P.S. I'm running JDK 1.4.0 under Red Hat 7.2.
> 
> --- Iwan Birrer <iw...@bluewin.ch> wrote:
> > Hello,
> > 
> > I used slide now for a few days and everything
> > worked ok till I wanted to
> > use the proppatch methods. I alway get a Bad Request
> > (400) from the Server.
> > 
> > Find and search Methods are working just fine.
> > 
> > My configuration: slide 1.0.16
> > Server: Exchange 2000
> > 
> > I tried the following command in the command line
> > tool, and it went wrong as
> > well.
> > 
> > proppatch /public/contacts/myContact.EML
> > urn:schemas:contacts:givenName
> > newName
> > 
> > What am I doing wrong?
> > 
> > Iwan


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: webdavClient: proppatch - Bad Request( 400 )

Posted by Kevin Moran <gr...@yahoo.com>.
Hi,
    I'm seeing the same thing.  I've tried to use
proppatch with two recent cuts of the code (10/01/2002
and 11/22/2002) and both exhibit the same behavior. 
This is a critical bug for me as my app has to be able
to call proppatch on a document to set or reset its
content type.  Unfortunately, because I need
versioning support, I can't revert to 1.0.16 where I
know this works.  Anyone know how to fix this?  I'm
willing to wade into the code if I have an idea of
where the problem might be.

Thanks,
-kevin

P.S. I'm running JDK 1.4.0 under Red Hat 7.2.

--- Iwan Birrer <iw...@bluewin.ch> wrote:
> Hello,
> 
> I used slide now for a few days and everything
> worked ok till I wanted to
> use the proppatch methods. I alway get a Bad Request
> (400) from the Server.
> 
> Find and search Methods are working just fine.
> 
> My configuration: slide 1.0.16
> Server: Exchange 2000
> 
> I tried the following command in the command line
> tool, and it went wrong as
> well.
> 
> proppatch /public/contacts/myContact.EML
> urn:schemas:contacts:givenName
> newName
> 
> What am I doing wrong?
> 
> Iwan


__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus � Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>