solved ticket https://issues.jboss.org/browse/RAILO-2334 and https://issues.jboss.org/browse/RAILO-2359