jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deepak Shetty <>
Subject Re: Uploading File to WebDAV Server
Date Tue, 08 Feb 2011 19:18:52 GMT
are you giving a value for the parameter name (i think you shouldnt) with
the file?

see the doc from

* Parameter Handling: *
For the POST and PUT method, if there is no file to send, and the name(s) of
the parameter(s) are omitted, then the body is created by concatenating all
the value(s) of the parameters. This allows arbitrary bodies to be sent. The
values are encoded if the encoding flag is set (versions of JMeter after
2.3). See also the MIME Type above how you can control the content-type
request header that is sent.
For other methods, if the name of the parameter is missing, then the
parameter is ignored. This allows the use of optional parameters defined by
variables. (versions of JMeter after 2.3)

* Method Handling: *
The POST and PUT request methods work similarly, except that the PUT method
does not support multipart requests. The PUT method body must be provided as
one of the following:

   - define the body as a file
   - define the body as parameter value(s) with no name

If you define any parameters with a name in either the sampler or Http
defaults then nothing is sent. The GET and DELETE request methods work
similarly to each other.

On Tue, Feb 8, 2011 at 1:36 AM, TomZ <> wrote:

> Hi,
> I have looked in Bugzilla and this forum/mailinglist, but couldn't find an
> answer. Sorry if this is a known
> issue. In that case, it would be nice, if you just point me to the
> respective resource.
> I am using jmeter v2.4. I am trying to upload a (simple text) file to my
> local webdav server.
> I have tested the HTTP request sampler _and_ HTTP Request HTTPClient
> sampler. Both create a file
> on my webdav server. But in both cases this file is empty (file size 0
> bytes).
> When I do the same with an unamed argument (without the file) it works in
> both cases.
> I inspected the sources for a while and discovered that around (have added
> some debug code) line 1100
> in (which is HTTP Request HTTPClient) the
> putBody.toString() returns an empty string.
> That looks like this is the reason for the zero byte sized file on my
> webdav
> server.
> Is this an known behavior? Can I do something to work around it?
> tia, tom
> --
> View this message in context:
> Sent from the JMeter - User mailing list archive at
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message