[
https://issues.jboss.org/browse/TEIIDDES-3030?page=com.atlassian.jira.plu...
]
Hiroki Daicho commented on TEIIDDES-3030:
-----------------------------------------
Hi,
The following class uses ByteArrayOutputStream#toString().
-- WEB-INF/classes/org/teiid/soap/provider/TeiidWSProvider.java
ByteArrayOutputStream bos = new ByteArrayOutputStream();
StreamResult sr = new StreamResult(bos);
Transformer trans = TransformerFactory.newInstance()
.newTransformer();
trans.transform(request, sr);
inputMessage = bos.toString(); // here
bos.close();
The API uses platform's default charactor set.
"Converts the buffer's contents into a string decoding bytes using the
platform's default character set."
https://docs.oracle.com/javase/7/docs/api/java/io/ByteArrayOutputStream.h...
Soap message with the encoding specification as follows.
<?xml version="1.0" encoding="UTF-8"?>
It seems that the soap message's encoding should be used for getting String value in
the class.
inputMessage is garbled at TeiidWSProvider when JDV booting with
Shift-jis encoding
-----------------------------------------------------------------------------------
Key: TEIIDDES-3030
URL:
https://issues.jboss.org/browse/TEIIDDES-3030
Project: Teiid Designer
Issue Type: Bug
Components: Web Services Support
Affects Versions: 9.0.7
Environment: JDV 6.2.4
JBDS 8.1.0.GA
Teiid Designer 9.0.6 (integration stack 8.0.6) and 9.0.7
Reporter: Hiroki Daicho
Attachments: reproducer.zip
When logging inputvalue by SYSADMIN.logmsg on Web service (created by teiid designer),
the log message is garbled if the JDV booting with shift-jis encoding.
1. Generate War from VDB including webservice on Teiid Designer.
1-1. create procedure (the procedure logs input parameter by SYSADMIN.logmsg)
1-2. modeling -> create Web Service
1-3. create vdb includeing the web service
1-4. modeling -> Generate SOAP war
2. Deploy the vdb and war to JDV.
3. JDV boot with Shift-jis encoding.
4. call the webservice with testclient, the log will be garbled.
I attached reproducer.zip.
- testproject (JBDS project)
- testclient (webservice client)
- newvdb.war (generated web service)
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)