Support Article
HTTP 500 when invoking POST from Connect-REST to EMC Documentum
Summary
You invoke an EMC Documentum REST service from Connect-REST's POST method and receive a HTTP 500 response.
Error Messages
Documentum Logs:
[5/12/15 14:18:23:284 EDT] 000000c8 LoggingFilter I 2 * Server in-bound request
2 > POST /services/format/jsonp/appname/dms/repository/Default/servicename/loginticket/ticket/Default
2 > Content-Type: multipart/form-data
2 > Content-Length: 139
2 > Host:
2 > User-Agent: Apache-HttpClient/UNAVAILABLE (java 1.5)
2 > SM_TRANSACTIONID: 000000000000000000000000211559a9-57ab-555243ef-51bd5700-67b920b0f086
2 > SM_SDOMAIN: .abc.net
2 > SM_AUTHTYPE: Not Protected
2 > SM_USER:
2 > SM_USERDN:
2 > $WSIS: false
2 > $WSSC: http
2 > $WSPR: HTTP/1.1
2 > $WSSP: 8000
2 > Surrogate-Capability: WS-ESI="ESI/1.0+"
2 > _WS_HAPRT_WLMVERSION: -1
2 > Expect: 100-Continue
2 >
[5/12/15 14:18:23:286 EDT] 000000c8 ContainerResp E The RuntimeException could not be mapped to a response, re-throwing to the HTTP container
java.lang.NullPointerException
at com.sun.jersey.multipart.impl.MultiPartReaderClientSide.unquoteMediaTypeParameters(MultiPartReaderClientSide.java:227)
at com.sun.jersey.multipart.impl.MultiPartReaderClientSide.readMultiPart(MultiPartReaderClientSide.java:154)
at com.sun.jersey.multipart.impl.MultiPartReaderServerSide.readMultiPart(MultiPartReaderServerSide.java:80)
.
.
.
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:175)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture$1.run(AsyncChannelFuture.java:205)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1881)
PegaRULES log snippet after enabling DEBUG on pyInvokeRestConnector:
------------------HTTP REQUEST CONTENTS------------------POST /services/format/jsonp/appname/dms/repository/Default/servicename/loginticket/ticket/Default HTTP/1.1
Request Headers: {content-type=multipart/form-data}
Request Message Data:
{"parameterList":[{"parameterName":"username","parameterValue":"Test"},{"parameterName":"password","parameterValue":"Test"}]}
----------------END HTTP REQUEST CONTENTS----------------
2015-05-07 14:13:19,106 [ WebContainer : 13] [ STANDARD] [ ] (ector.Rule_Connect_REST.Action) INFO F099026 - Response code: 500
2015-05-07 14:13:19,106 [ WebContainer : 13] [ STANDARD] [ ] (ector.Rule_Connect_REST.Action) DEBUG F099026 -
------------------HTTP RESPONSE CONTENTS------------------
Response Headers:
Date: Thu, 07 May 2015 18:13:19 GMT X-Powered-By: Servlet/3.0 $WSEP: Content-Length: 42 Connection: close Content-Type: text/html;charset=ISO-8859-1 Content-Language: en-US
Response Message Data:
Error 500: java.lang.NullPointerException
Steps to Reproduce
Invoke REST service from Connect-REST rule.
Root Cause
Documentum log indicates that it is receiving the correct Content-Type from Pega. The issue is at the Application server container level, Websphere, that uses Jersey (JAX-RS) API for REST. The error occurs because Jersey Server expects the “boundary” parameter be set as a part of the content-type header, which is not being set by HTTP Client. Jersey does not check the "boundary" parameter value for null, before dereferencing it. Local-change is to parse “boundary” parameter in the header from Connect-REST.
Resolution
This issue is resolved through the following Local-change:
Parse the "boundary" parameter to the request header.
Published June 12, 2015 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.