Hi Julian,

On Tue, Jul 14, 2015 at 7:57 PM,  <[email protected]> wrote:
> +
> +            List<String> ids = new ArrayList<String>();
> +            for (T doc : documents) {
> +                ids.add(doc.getId());
> +            }
> +            LOG.debug("insert of " + ids + " failed", ex);
> +
> +            // collect additional exceptions
> +            String messages = LOG.isDebugEnabled() ? 
> RDBJDBCTools.getAdditionalMessages(ex) : "";
> +            if (!messages.isEmpty()) {
> +                LOG.debug("additional diagnostics: " + messages);
> +            }

If all that work is to be done for debug logging then probably the
whole block should be within isDebugEnabled check

+ LOG.debug("insert of " + ids + " failed", ex);

Instead of using concatenation it would be better to use placeholders like

LOG.debug("insert of {} failed",ids, ex);

Chetan Mehrotra

Reply via email to