UTF-8 unsupported message from registration subsystem, ESB 4.4 fuse

I updated my compilation of ServiceMix to compile ESA 4.4. However, I got errors from the logging system that I cannot find how to handle.

Error message:

Warning: encoding "UTF-8" not supported, using UTF-8 

UTF-8 encoding is NOT used. Files are encoded in the encoding of Windows-1250 (characters from this set are correctly converted, others, of course, are not available).

I found a discussion of a similar problem here in StackOverflow, where a problem was discovered with the Xerces parser, but without a hint how to solve it in this special case. Has anyone successfully dealt with this?

+4
source share
1 answer

The problem is that something is trying to access the UTF-8 character set (possibly through Charset.forName ("UTF-8"), which is trying to instantiate the class in the package sun.nio.cs.UTF_8.

Although this will exist at run time of the JVM without the restrictions of the class loader, at run time OSGi code will not be executed.

The solution would be to modify the package generating this error message as follows:

Import-Package: ..., sun.nio.cs; resolution: = optional

This means that if he tries to create an instance of the class in this package, he will have to find it - however, if it is not present (say, because you use a different runtime), it will still work.

Note that this means that System.bundle exports the sun.nio.cs package, which you can create by creating a snippet (see http://wiki.osgi.org/wiki/Fragment ), or if the system package exports the package sun.nio.cs with the property org.osgi.framework.system.packages.

In any case, it looks like the logging pool should fix, and not something that you need to fix - did you report an error upstream?

+7
source

All Articles