Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7546443
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T09:12:00+00:00 2026-05-30T09:12:00+00:00

we are developing an web application using GWT 2.4, Errai 1.3.2. It is running

  • 0

we are developing an web application using GWT 2.4, Errai 1.3.2. It is running on Tomcat 6 (6.0.35) and built by Maven (3.0.4).

When running this application on Tomcat, the transfer of special cases is not working. More specific, the request works fine but the response of special characters converts them to �. When using the errai maven archetype, it has the same behaviour. When using GWT-RPC instead of errai RPC, everything works fine. Running the same application in Dev-Mode, the problem doesn’t occur.

When looking at the request/response in chrome, both have character encoding UTF-8.

I think this might be an errai bug because there is some String encoding in errai before sending the response.

It would be great, if someone could help me!! It’s really a tricky problem…

Thanks, Walter


PS: I have already tried the following potential solutions, which all do not work:

Setting index.html head:

<meta http-equiv="content-type" content="text/html; charset=UTF-8">

Define a custom Servlet Filter

WEB.xml

<filter>
    <filter-name>SessionFilter</filter-name>
    <filter-class>at.apa.excelsa.web.server.SessionFilter</filter-class>
    <init-param>
        <param-name>requestEncoding</param-name>
        <param-value>UTF-8</param-value>
    </init-param>
</filter>
<filter-mapping>
    <filter-name>SessionFilter</filter-name>
    <url-pattern>*</url-pattern>
</filter-mapping>

Filter.java

public class SessionFilter implements Filter {

String encoding;

@Override
public void init(FilterConfig filterConfig) throws ServletException {
    encoding = filterConfig.getInitParameter("requestEncoding");
    if (encoding == null) {
        encoding = "UTF-8";
    }
}

@Override
public void doFilter(ServletRequest request, ServletResponse response,
        FilterChain chain) throws IOException, ServletException {

    if(request.getCharacterEncoding()==null) {
        request.setCharacterEncoding(encoding);
    }

    response.setContentType("text/html; charset=UTF-8");
    response.setCharacterEncoding("UTF-8");

    chain.doFilter(request, response);
}

On Tomcat Server.xml setting URIEncoding

<Connector port="8080" protocol="HTTP/1.1" 
           connectionTimeout="20000" 
           redirectPort="8443" useBodyEncodingForURI="true" URIEncoding="UTF-8" />

Maven in pom.xml

<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
...
<build>
    <outputDirectory>war/WEB-INF/classes</outputDirectory>
        <plugins>
             <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>gwt-maven-plugin</artifactId>
                <version>${gwt.maven}</version>
                <configuration>
                    ...
                    <extraJvmArgs>-Xmx512m **-Dfile.encoding=UTF-8**</extraJvmArgs>
                    ...
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>resources</goal>
                            <goal>compile</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            ...
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T09:12:01+00:00Added an answer on May 30, 2026 at 9:12 am

    After almost 2 days of searching, I have found the solution: Tomcat needs the following JVM argument in order to solve the issue:

    -Dfile.encoding=UTF-8 
    

    BR Walter

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I use tomcat. I am developing a web application using struts2, and I use
I am developing a web application using Spring JS and Dojo Toolkit. In this
I am developing a web application using Spring and Tomcat 7.0. When I test
I have some doubts, i m developing a web application in GWT using MVP
I'm developing a web application using asp.net 3.5. This application has a lot of
I am using the GWT for developing my web application and would like to
I'm currently developing a web application using Struts2 framework. This application requires to dynamically
I am developing a web application using gwt and gwtp. I can get a
I'm developing web application using CodeIgniter. All this time, I put the custom js
I am developing a web application using php and mysql. This application runs on

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.