cloudtrends / soi-toolkit

Automatically exported from code.google.com/p/soi-toolkit
1 stars 0 forks source link

Service description components: set CXF-encoding for code generation #360

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Using CXF 2.5.1 with Java 6 causes problems if WSDL or XML-schema files 
contains umlaut-characters, CXF-code generation is done in platform encoding 
and when the compiler kicks in (using UTF-8 as encoding) we get compile errors 
due to "unmappable character ..." (since the generated code is not UTF-8 
encoded).

See: https://issues.apache.org/jira/browse/CXF-2450

A simple fix is to fork code-gen with encoding set like:

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.cxf</groupId>
        <artifactId>cxf-codegen-plugin</artifactId>
        <configuration>
          <fork>once</fork>
          <additionalJvmArgs>-Dfile.encoding=UTF-8</additionalJvmArgs>
        </configuration>
        <executions>

The problem doesn't seem to exist when using Java7 (fixed in JAXB 2.2.5+ 
according to CXF issue).

Original issue reported on code.google.com by hakan.d...@gmail.com on 12 Dec 2013 at 9:42

GoogleCodeExporter commented 9 years ago

Original comment by hakan.d...@gmail.com on 23 Jan 2014 at 9:20

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r2109.

Original comment by hakan.d...@gmail.com on 23 Jan 2014 at 9:24