Error while Passing French Characters from Controller to BPMN Process


#1

My request has some french characters. After calling a service, my controller reads all characters and passes to the process by following procedure. I am passing whole request in the form of Map<String, Object> in params field.

ProcessServicesClient processClient = KieServerUtil.getKieServicesClient().getServicesClient(ProcessServicesClient.class);
Long processInstanceId = processClient.startProcess(containerId, processId, params);

But inside process my request is being passed as null. In the logs I am getting below error. Below is the stacktrace

org.kie.remote.common.rest.KieRemoteHttpRequestException: Unable to add char sequence to request body
at org.kie.remote.common.rest.KieRemoteHttpRequest.initializeConnection(KieRemoteHttpRequest.java:927) ~[kie-remote-common-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at org.kie.remote.common.rest.KieRemoteHttpRequest.responseCode(KieRemoteHttpRequest.java:1326) ~[kie-remote-common-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at org.kie.remote.common.rest.KieRemoteHttpRequest.post(KieRemoteHttpRequest.java:719) ~[kie-remote-common-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at org.kie.server.client.impl.AbstractKieServicesClientImpl.makeHttpPostRequestAndCreateCustomResponse(AbstractKieServicesClientImpl.java:240) ~[kie-server-client-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at org.kie.server.client.impl.AbstractKieServicesClientImpl.makeHttpPostRequestAndCreateCustomResponse(AbstractKieServicesClientImpl.java:235) ~[kie-server-client-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at org.kie.server.client.impl.ProcessServicesClientImpl.startProcess(ProcessServicesClientImpl.java:232) ~[kie-server-client-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at com.td.cb.eso.brms.service.impl.KieServerProcessServiceImpl.startProcess(KieServerProcessServiceImpl.java:30) ~[td-eso-kie-rest-client-18.03.0026.jar:?]
at com.td.eso.ae.edb.service.SubmitN2BController.submitN2BProfile(SubmitN2BController.java:199) [classes:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_131]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_131]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_131]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_131]
at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:168) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:269) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:227) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:216) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:561) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:543) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:128) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50) [resteasy-jaxrs-2.3.13.Final-redhat-1.jar!/:?]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-2.jar!/:1.0.2.Final-redhat-2]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.eso.temporary.security.StripBackslashFilter.doFilter(StripBackslashFilter.java:36) [td-eso-appengine-filters-18.03.0034.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.eso.web.filter.CustomMDCInsertingServletFilter.doFilter(CustomMDCInsertingServletFilter.java:49) [td-eso-appengine-filters-18.03.0034.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.eso.web.filter.TestSetNeutralityFilter.doFilter(TestSetNeutralityFilter.java:117) [td-eso-appengine-filters-18.03.0034.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.eso.web.filter.MetaDataUpdateFilter.doFilter(MetaDataUpdateFilter.java:109) [td-eso-appengine-filters-18.03.0034.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.coreapi.common.sanitizevalidate.SanitizeValidateFilter.doFilter(SanitizeValidateFilter.java:318) [com.td.coreapi.common.sanitizevalidate-1.8.0.jar:1.8.0]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.eso.temporary.security.OAuth2Filter.doFilter(OAuth2Filter.java:222) [td-eso-appengine-filters-18.03.0034.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at com.td.eso.web.filter.ResponseHeaderFilter.doFilterInternal(ResponseHeaderFilter.java:38) [td-eso-appengine-filters-18.03.0034.jar:?]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.2.9.RELEASE.jar:4.2.9.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:121) [spring-web-4.2.9.RELEASE.jar:4.2.9.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.2.9.RELEASE.jar:4.2.9.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.5.7.Final-redhat-3.jar!/:7.5.7.Final-redhat-3]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:150) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:400) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:854) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:654) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926) [jbossweb-7.5.15.Final-redhat-1.jar!/:7.5.15.Final-redhat-1]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_131]
Caused by: java.io.IOException: too many bytes written
at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.write(HttpURLConnection.java:3505) ~[?:?]
at java.io.BufferedOutputStream.write(BufferedOutputStream.java:122) ~[?:1.8.0_131]
at org.kie.remote.common.rest.KieRemoteHttpRequest$RequestOutputStream.write(KieRemoteHttpRequest.java:425) ~[kie-remote-common-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
at org.kie.remote.common.rest.KieRemoteHttpRequest.initializeConnection(KieRemoteHttpRequest.java:925) ~[kie-remote-common-6.4.0.Final-redhat-3.jar:6.4.0.Final-redhat-3]
… 62 more

Can anyone solve this issue ?


#2

How is this related to any of our projects?