[英]How to customize customized properties for WebSphere using wsadmin with values in non-English characters
I am trying to create jython script that will load list of properties and will customize the server-> JVM -> custom properties.我正在尝试创建将加载属性列表并自定义服务器的 jython 脚本-> JVM -> 自定义属性。
I managed to create a script using the AdminConfig tasks, the problem is that some of the values contains non-English characters (Hebrew to be more precise), and the Jython does not managed to read them correctly我设法使用 AdminConfig 任务创建了一个脚本,问题是某些值包含非英文字符(更准确地说是希伯来语),并且 Jython 无法正确读取它们
The solution was combined- The loading of the properties files was done with InputStreamReader that used UTF8 character set-解决方案结合在一起-属性文件的加载是使用使用 UTF8 字符集的 InputStreamReader 完成的-
inStream = javaio.FileInputStream(propsFil)
instreader = javaio.InputStreamReader(inStream, "UTF8")
propFil = util.Properties()
propFil.load(instreader)
After that I needed to use the AdminTask instead of AdminConfig-之后我需要使用 AdminTask 而不是 AdminConfig-
AdminTask.setJVMSystemProperties('[-serverName '+ server + ' -nodeName '+ node+ ' -propertyName '+ config_property +' -propertyValue ' + config_value + ' ]')
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.