]> git.mxchange.org Git - addressbook-ejb.git/commitdiff
let the logger log the size of the list
authorRoland Haeder <roland@mxchange.org>
Fri, 16 Oct 2015 10:23:04 +0000 (12:23 +0200)
committerRoland Haeder <roland@mxchange.org>
Fri, 16 Oct 2015 10:23:04 +0000 (12:23 +0200)
Signed-off-by:Roland Häder <roland@mxchange.org>

src/java/org/mxchange/addressbook/model/shared/SharedAddressbooksSessionBean.java

index 2608b5812455214a01f32204324e18bf53d812ad..edb9b1c7b577fa73131b492c5dc61fb77e599e44 100644 (file)
@@ -61,13 +61,19 @@ public class SharedAddressbooksSessionBean extends BaseDatabaseBean implements S
                }
 
                // Get named query
-               Query query = this.getEntityManager().createNamedQuery("SearchUserSharedAddressbooks"); //NOI18N
+               Query query = this.getEntityManager().createNamedQuery("SearchUserSharedAddressbooks", List.class); //NOI18N
 
                // Set parameter
                query.setParameter("user", user); //NOI18N
 
                // Return full list
-               return query.getResultList();
+               List<ShareableAddressbook> list = query.getResultList();
+
+               // Trace message
+               this.getLoggerBeanLocal().logTrace(MessageFormat.format("allSharedAddressbooks: list.size()={0} - EXIT!", list.size()));
+
+               // Return list
+               return list;
        }
 
        @Override