the default charset will be different between your jvm and the tomcat jvm
try
System.out.println(Charset.defaultCharset());
this will use the default charset to encode the string which may or may not be utf-8
System.out.println("test===" + new String(searchURL.getBytes("utf-8")));
so while the byte array is utf-8 the decoder may expect something else.