How do I create and edit files with multibyte characters file name on JBoss EAP for OpenShift?
Issue
- How do I create and edit files with multibyte characters file name on JBoss EAP for OpenShift?
- How do I set
ja_JP.UTF-8
as the system locale in JBoss EAP for OpenShift? - Getting the following error when I create Japanese file name
/opt/eap/日本語ファイル名.txt
:
8:59:32,756 ERROR [io.undertow.request] (default task-1) UT005023: Exception handling request to /test-app/api/files: org.jboss.resteasy.spi.UnhandledException: java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /opt/eap/???????.txt
...
Caused by: java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /opt/eap/???????.txt
at sun.nio.fs.UnixPath.encode(UnixPath.java:147)
at sun.nio.fs.UnixPath.<init>(UnixPath.java:71)
at sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:281)
at java.nio.file.Paths.get(Paths.java:84)
at com.redhat.cee.example.jafile.FileResource.createNewJaFile(FileResource.java:19)
...
Environment
- Red Hat Enterprise Application Platform (JBoss EAP)
- 7.4
- OpenShift
- 4.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.