if (logger.isLoggable(Level.FINER)) {
logger.log(Level.FINER, "URI: {0}", uri.toString());
logger.log(Level.FINER, "Using auth info: User: {0}, Password: {1}",
new Object[]{user, ok(password) ? "<non-null>" : "<null>"});
}
final AuthenticationInfo authInfo = authenticationInfo();
if (authInfo != null) {
HttpBasicAuthFilter besicAuth = new HttpBasicAuthFilter(authInfo.getUser(), authInfo.getPassword() == null ? "" : authInfo.getPassword());
target.configuration().register(besicAuth);
}
Metrix.event("doRestCommand() - about to prepare request builder");
Builder request = target.request(acceptedResponseTypes);
Metrix.event("doRestCommand() - about to add headers");