Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in: SoapSampler.setPostHeaders(PostMethod post) in the else branch #2323

Closed
asfimport opened this issue Dec 28, 2009 · 1 comment
Closed

Comments

@asfimport
Copy link
Collaborator

Carol Gagne (Bug 48451):
In class: org.apache.jmeter.protocol.http.sampler.SoapSampler
Method: setPostHeaders(PostMethod post)
Source file line: 143
....
} else {
// otherwise we use "text/xml" as the default
post.addParameter(HEADER_CONTENT_TYPE, DEFAULT_CONTENT_TYPE);
}...

I believe it should be something like

    } else {
        // otherwise we use "text/xml" as the default
        post.setRequestHeader(HEADER_CONTENT_TYPE, DEFAULT_CONTENT_TYPE);
    }

How to reproduce: Make sure no header manager is null (not set).
Capture the content of the call (with TCPMon for exemple). You will see the default content type does not appear in HTTP Header but in the content.

Regards

Severity: normal
OS: Windows XP

@asfimport
Copy link
Collaborator Author

Sebb (migrated from Bugzilla):
Thanks for the report and suggested fix.

This has been applied to SVN:

URL: http://svn.apache.org/viewvc?rev=894535&view=rev
Log:
#2323 - Error in: SoapSampler.setPostHeaders(PostMethod post) in the else branch

and will be in nightly builds after r894535

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant