org.vertx.java.core.logging.Logger.debug()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(6.7k)|赞(0)|评价(0)|浏览(133)

本文整理了Java中org.vertx.java.core.logging.Logger.debug()方法的一些代码示例,展示了Logger.debug()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger.debug()方法的具体详情如下:
包路径:org.vertx.java.core.logging.Logger
类名称:Logger
方法名:debug

Logger.debug介绍

暂无

代码示例

代码示例来源:origin: org.vert-x/vertx-core

public void handle(final Message<JsonObject> msg) {
  Match curMatch = checkMatches(false, address, msg.body);
  if (curMatch.doesMatch) {
   if (curMatch.requiresAuth && sockAuths.get(sock) == null) {
    log.debug("Outbound message for address " + address + " rejected because auth is required and socket is not authed");
   } else {
    checkAddAccceptedReplyAddress(msg.replyAddress);
    deliverMessage(sock, address, msg);
   }
  } else {
   log.debug("Outbound message for address " + address + " rejected because there is no inbound match");
  }
 }
};

代码示例来源:origin: org.vert-x/vertx-core

private void logInternal(final String perms) {
  if ((perms != null) && log.isDebugEnabled()) {
    log.debug("You are running on Windows and POSIX style file permissions are not supported");
  }
}

代码示例来源:origin: com.englishtown/vertx-mod-cassandra

@Override
protected void initLoadBalancingPolicy(JsonObject loadBalancing) {
  // Recall super
  super.initLoadBalancingPolicy(loadBalancing);
  // If LB policy not set, try env vars
  if (loadBalancingPolicy == null) {
    String localDC = container.env().get(ENV_VAR_LOCAL_DC);
    if (!Strings.isNullOrEmpty(localDC)) {
      logger.debug("Using environment config for Local DC of " + localDC);
      loadBalancingPolicy = new DCAwareRoundRobinPolicy(localDC);
    } else {
      logger.debug("No environment configuration found for local DC");
    }
  }
}

代码示例来源:origin: com.englishtown/vertx-mod-cassandra

@Override
protected void initSeeds(JsonArray seeds) {
  // Recall super
  super.initSeeds(seeds);
  // If default, try env vars
  if (DEFAULT_SEEDS.equals(this.seeds)) {
    String envVarSeeds = container.env().get(ENV_VAR_SEEDS);
    if (!Strings.isNullOrEmpty(envVarSeeds)) {
      logger.debug("Using environment configuration of " + envVarSeeds);
      String[] seedsArray = envVarSeeds.split("\\|");
      this.seeds = ImmutableList.copyOf(seedsArray);
    }
  }
}

代码示例来源:origin: org.vert-x/vertx-core

public void handle(AsyncResult<Boolean> res) {
  if (res.succeeded()) {
   if (res.result) {
    cacheAuthorisation(sessionID, sock);
    checkAndSend(send, address, jsonObject, sock, replyAddress);
   } else {
    log.debug("Inbound message for address " + address + " rejected because sessionID is not authorised");
   }
  } else {
   log.error("Error in performing authorisation", res.exception);
  }
 }
});

代码示例来源:origin: com.englishtown/vertx-mod-jersey

@Override
public void init(JerseyConfigurator configurator) {
  baseUri = configurator.getBaseUri();
  maxBodySize = configurator.getMaxBodySize();
  applicationHandlerDelegate = configurator.getApplicationHandler();
  logger.debug("DefaultJerseyHandler - initialized");
}

代码示例来源:origin: com.englishtown/vertx-mod-cassandra

/**
 * Reconnects to the cluster with a new session.  Any existing session is closed asynchronously.
 */
@Override
public void reconnect() {
  logger.debug("Call to reconnect the session has been made");
  Session oldSession = session;
  session = cluster.connect();
  if (oldSession != null) {
    oldSession.closeAsync();
  }
  metrics.afterReconnect();
}

代码示例来源:origin: com.englishtown/vertx-mod-cassandra

@Override
public void close() {
  logger.debug("Call to close the session has been made");
  if (metrics != null) {
    metrics.close();
    metrics = null;
  }
  if (cluster != null) {
    cluster.closeAsync().force();
    cluster = null;
    session = null;
  }
  clusterBuilder = null;
}

代码示例来源:origin: org.vert-x/vertx-core

private void doSendOrPub(final boolean send, final SockJSSocket sock, final String address,
             final JsonObject jsonObject, final String replyAddress) {
 if (log.isDebugEnabled()) {
  log.debug("Received msg from client in bridge. address:"  + address + " message:" + jsonObject.encode());
    log.debug("Inbound message for address " + address + " rejected because it requires auth and sessionID is missing");
  log.debug("Inbound message for address " + address + " rejected because there is no match");

代码示例来源:origin: org.vert-x/vertx-core

private void cleanupConnection(ServerID theServerID,
                ConnectionHolder holder,
                boolean failed) {
 if (holder.timeoutID != -1) {
  vertx.cancelTimer(holder.timeoutID);
 }
 if (holder.pingTimeoutID != -1) {
  vertx.cancelTimer(holder.pingTimeoutID);
 }
 try {
  holder.socket.close();
 } catch (Exception ignore) {
 }
 // The holder can be null or different if the target server is restarted with same serverid
 // before the cleanup for the previous one has been processed
 // So we only actually remove the entry if no new entry has been added
 if (connections.remove(theServerID, holder)) {
  log.debug("Cluster connection closed: " + theServerID + " holder " + holder);
  if (failed) {
   cleanSubsForServerID(theServerID);
  }
 }
}

代码示例来源:origin: org.vert-x/vertx-core

private void checkAndSend(boolean send, final String address, JsonObject jsonObject,
             final SockJSSocket sock,
             final String replyAddress) {
 final Handler<Message<JsonObject>> replyHandler;
 if (replyAddress != null) {
  replyHandler = new Handler<Message<JsonObject>>() {
   public void handle(Message<JsonObject> message) {
    // Note we don't check outbound matches for replies
    // Replies are always let through if the original message
    // was approved
    checkAddAccceptedReplyAddress(message.replyAddress);
    deliverMessage(sock, replyAddress, message);
   }
  };
 } else {
  replyHandler = null;
 }
 if (log.isDebugEnabled()) {
  log.debug("Forwarding message to address " + address + " on event bus");
 }
 if (send) {
  eb.send(address, jsonObject, replyHandler);
 } else {
  eb.publish(address, jsonObject);
 }
}

代码示例来源:origin: org.vert-x/vertx-platform

depName != null ? depName : "deployment-" + UUID.randomUUID().toString();
log.debug("Deploying name : " + deploymentName + " main: " + main +
  " instances: " + instances);

代码示例来源:origin: io.vertx/vertx-platform

log.debug("Deploying name : " + deploymentID + " main: " + theMain + " instances: " + instances);

代码示例来源:origin: com.englishtown/vertx-mod-jersey

logger.debug("DefaultJerseyHandler - handle request and read body: " + vertxRequest.method() + " " + vertxRequest.uri());
logger.debug("DefaultJerseyHandler - handle request: " + vertxRequest.method() + " " + vertxRequest.uri());

代码示例来源:origin: io.vertx/vertx-platform

protected void sendRequest(String scheme, String host, int port, String uri, Handler<HttpClientResponse> respHandler) {
 final String proxyHost = getProxyHost();
 if (proxyHost != null) {
  // We use an absolute URI
  uri = scheme + "://" + host + ":" + port + uri;
 }
 HttpClientRequest req = client.get(uri, respHandler);
 if (proxyHost != null){
  if (isUseDestinationHostHeaderForProxy()) {
   req.putHeader("host", host);
  } else {
   req.putHeader("host", proxyHost);
  }
 } else {
  req.putHeader("host", host);
 }
 if (getBasicAuth() != null) {
  log.debug("Using HTTP Basic Authorization");
  req.putHeader("Authorization","Basic " + getBasicAuth());
 }
 req.putHeader("user-agent", "Vert.x Module Installer");
 req.end();
}

相关文章

微信公众号

最新文章

更多