0 Replies Latest reply on Feb 26, 2015 1:57 PM by wildfly.developer

    Wildfly 8.2.0 is rewriting the login roles SQL query in standalone.xml

    wildfly.developer Newbie

      The problem is occurring in the login-module section of the jdbcSecurityRealm security-domain section of standalone.xml. The SQL statement in the module option "rolesQuery" is somehow being rewritten when a project is deployed. All instances of ">" are being changed to ">" and certain table names are being changed


      For example, let's say this is the query: "SELECT * FROM Roles WHERE username=?". In the EE project, the table entity is a class called "TableRoles" annotated with "@Table(name=TableRoles.TABLE_NAME)" and TableRoles.TABLE_NAME is defined as "Roles."

      When I restart the server, WildFly is rewriting the query to this: "SELECT * FROM TableRoles WHERE username=?"

      When I try to log in, an error is occurring because there is no table called "TableRoles."

      Is there a way to tell WildFly to leave the query alone?

      Thank you.