Do not use toString() with loggers
[aaa.git] / aaa-shiro / impl / src / main / java / org / opendaylight / aaa / datastore / h2 / UserStore.java
index d383a3182984ab0a139ae9cc4db067958a13f639..e434d17a66540ee493d7914b690559dcf2a3a7e7 100644 (file)
@@ -92,7 +92,7 @@ public class UserStore extends AbstractStore<User> {
         try (Connection conn = dbConnect();
                 PreparedStatement pstmt = conn.prepareStatement("SELECT * FROM USERS WHERE userid = ? ")) {
             pstmt.setString(1, IDMStoreUtil.createUserid(username, domain));
-            LOG.debug("query string: {}", pstmt.toString());
+            LOG.debug("query string: {}", pstmt);
             users.setUsers(listFromStatement(pstmt));
         } catch (SQLException s) {
             throw new StoreException("SQL Exception : " + s);
@@ -104,7 +104,7 @@ public class UserStore extends AbstractStore<User> {
         try (Connection conn = dbConnect();
                 PreparedStatement pstmt = conn.prepareStatement("SELECT * FROM USERS WHERE userid = ? ")) {
             pstmt.setString(1, id);
-            LOG.debug("query string: {}", pstmt.toString());
+            LOG.debug("query string: {}", pstmt);
             return firstFromStatement(pstmt);
         } catch (SQLException s) {
             throw new StoreException("SQL Exception : " + s);