wso2 bps3.5.1 bpmn the comments cannot support Chinese character - wso2

BPS3.5.1 is running on windows. The database is mysql-5.7.13. Mysql is configured by using utf-8.
when posting a comments via result api, the incorrect character is stored in database.
https://192.168.111.94:9443/bpmn/runtime/tasks/7525/comments
{
"message" : "This is a 测试.",
"saveProcessInstanceId" : true
}
I have configured bps to support utf-8 by setting
set JAVA_OPTS=%JAVA_OPTS% -Dfile.encoding=utf8

This is due to a mysql encoding problem for UTF-8. It is recommended to use latin1 charset for windows. Refer point 5 in [1] of the WSO2 BPS documentation.
[1]- https://docs.wso2.com/display/BPS351/Setting+up+MySQL

Related

Configuring wso2 ldap: read binary attributes

I am configuring WSO2 with ldap and want to read the "objectGUID" property which is a binary attribute in LDAP. Is there a way to get this data?
We can read binary attributes with the property as below.
<Property name="java.naming.ldap.attributes.binary">objectGUID</Property>
However due to the objectGUID's encoding, it won't be shown by its actual value(as a UUID) in the latest GA releases.
Showing objectGUID as a UUID is also fixed for the upcoming release (5.4.0) and more details can be found in this JIRA. In case you are interested you can try this out in the latest pre-releases for IS 5.4.0 from here.
On newer wso2 releases the setting can be found in deployment.toml:
[user_store]
ldap_binary_attributes= "objectGUID AnotherObjectGUID"

Setting the external proxy which requires authentication for Postman

I am setting up the native windows Postman and trying to run the "Request Header" api provided in Postman Echo collection. I get the following error.
"Error: tunneling socket could not be established, statusCode=407"
I can see in the postman console that it is picking up the correct proxy server from environment. My proxy server requires authentication, how do I provide credential information. I tried to start Postman using the following command but it did not help.
postman.exe --proxy-server=userName:password#myproxy:8090
Unfortunately the proxy tab in Settings does not allow authenticated proxies.
Entering proxy info in the format "userName:password#myproxy" will cause everything before the '#' symbol to be removed.
You may already know, but since version 5.2, Postman includes a "Proxy" tab into the "Settings" section.
You should be able to configure your proxy on your system (if you are using Windows you can do it in Internet Options>>Connections>>LAN Settings) and then enable the "Use system proxy" in this tab.
After testing this method is helpful:
Windows- create a postman.bat file with the following content:
set HTTP_PROXY=http://USER:PASS#host:port
set HTTPS_PROXY=https://USER:PASS#host:port
start C:\path\to\Postman.exe
as I get this from here
In the "Global Proxy Configuration" section of the Proxy tab, setting the "Proxy Server" value to -
userName:password#proxyHost:proxyPort resolves the issue.
I could solve this problem for Postman and also for other local tools that are not capable of NTLM authentication against a proxy.
The solution is the open source proxy service/demon CNTLM that runs under Linux, macOS and Windows. The project has not been updated for a while but I could easily install and run it under Windows 10.
Best part is that it is able to check your proxy's capabilities and automatically find the latest NTLM version that the proxy supports.
http://cntlm.sourceforge.net/
You can add Proxy-Authorization header with value Basic base64encode($user:$password)
launch postman through :
vagrant#localhost:~/Downloads/Postman-linux-x64-7.6.0/Postman/app$ ./Postman
and set/unset proxy values

how to decode a encoded xml in developer studio/ web service

I am using web services to read a xml report from oracle xmlserver.
The service then returns encoded value of the report and then I have to decode it via web link. Problem is i can not use web link every time to decode it
Is there any way that it doesn't return me encoded value and returns actual xml.
Also, is there any way to decode the encoded file via developer studio?
Any ideas and thoughts will be appreciated.

wso2 bps support Chinese character in variables

I am working on bps 3.2.0. When I send request to bps server, if there are any Chinese character in variables (request body) , it will be converted to ??? in bps. I would like to know how can I fix it?
Does it cause by any running parameters which I should take care?
Or does it caused by java web application iso8859-1 bug?
it is caused by uni code setting when starting wso2 application, just add
set JAVA_OPTS=%JAVA_OPTS% -Dfile.encoding=utf8

Calling a webservice that uses ISO-8859-1 encoding from Progress 4GL

I'm use progress 4Gl and i have to call a webservice that uses ISO-8859-1 but i receive the error when a execute the run statment:
Error receiving Web Service Response: Cannot get 'ISO-8859-1' transcoder from the TranscoderRepository. (11773)
And the developer of webservice can not change the encoding.
Someone can help me?
Progress only supports the UTF-8 and UTF-16 encoding with the OpenEdge Web Services as required by the WS-I
According to this knowledgebase entry
If you're sure the data is standard ascii (character values with ascii value < 128) there is a work-around.
You download the wsdl of the webservice locally.
Replace iso8859-1 but utf-8 in the locally saved file.
Use that wsdl instead of the one from the webservice.
This is a work-around, not an ideal solution.