本文整理了Java中org.jboss.logging.Logger.warnv()
方法的一些代码示例,展示了Logger.warnv()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger.warnv()
方法的具体详情如下:
包路径:org.jboss.logging.Logger
类名称:Logger
方法名:warnv
[英]Issue a log message with a level of WARN using java.text.MessageFormat-style formatting.
[中]使用java发出警告级别的日志消息。文本MessageFormat样式格式化。
代码示例来源:origin: wildfly/wildfly
private Level convertLevelIntToEnum(int level) {
switch (level) {
case SEVERE:
return Level.FATAL;
case WARNING:
return Level.WARN;
case CONFIG:
case INFO:
return Level.INFO;
case FINE:
return Level.DEBUG;
case FINER:
case FINEST:
return Level.TRACE;
default:
getLoggerForCategory("logging").warnv("Received message for log level {0}, but no such level is defined in SessionLog! Logging at INFO level...", level);
return Level.INFO;
}
}
代码示例来源:origin: org.kie.server/kie-server-router-proxy
public ConfigFileWatcher(String configFilePath, ConfigurationMarshaller marshaller, Configuration configuration) {
this.marshaller = marshaller;
this.configuration = configuration;
this.toWatch = Paths.get(configFilePath);
if (!Files.isDirectory(this.toWatch)) {
this.toWatch = Paths.get(configFilePath).getParent();
}
this.toWatch = Paths.get(toWatch.toString(), "kie-server-router.json");
try {
if(toWatch.toFile().exists()) {
lastUpdate = Files.getLastModifiedTime(toWatch).toMillis();
} else {
log.warnv("configuration file does not exists {0} ", this.toWatch);
}
} catch (IOException e) {
log.error("Unable to read last modified date of routers config file", e);
}
}
代码示例来源:origin: kiegroup/droolsjbpm-integration
public ConfigFileWatcher(String configFilePath, ConfigurationMarshaller marshaller, Configuration configuration) {
this.marshaller = marshaller;
this.configuration = configuration;
this.toWatch = Paths.get(configFilePath);
if (!Files.isDirectory(this.toWatch)) {
this.toWatch = Paths.get(configFilePath).getParent();
}
this.toWatch = Paths.get(toWatch.toString(), "kie-server-router.json");
try {
if(toWatch.toFile().exists()) {
lastUpdate = Files.getLastModifiedTime(toWatch).toMillis();
} else {
log.warnv("configuration file does not exists {0} ", this.toWatch);
}
} catch (IOException e) {
log.error("Unable to read last modified date of routers config file", e);
}
}
代码示例来源:origin: org.jboss.eap/jipijapa-eclipselink
private Level convertLevelIntToEnum(int level) {
switch (level) {
case SEVERE:
return Level.FATAL;
case WARNING:
return Level.WARN;
case CONFIG:
case INFO:
return Level.INFO;
case FINE:
return Level.DEBUG;
case FINER:
case FINEST:
return Level.TRACE;
default:
getLoggerForCategory("logging").warnv("Received message for log level {0}, but no such level is defined in SessionLog! Logging at INFO level...", level);
return Level.INFO;
}
}
代码示例来源:origin: org.jipijapa/jipijapa-eclipselink
private Level convertLevelIntToEnum(int level) {
switch (level) {
case SEVERE:
return Level.FATAL;
case WARNING:
return Level.WARN;
case CONFIG:
case INFO:
return Level.INFO;
case FINE:
return Level.DEBUG;
case FINER:
case FINEST:
return Level.TRACE;
default:
getLoggerForCategory("logging").warnv("Received message for log level {0}, but no such level is defined in SessionLog! Logging at INFO level...", level);
return Level.INFO;
}
}
代码示例来源:origin: org.keycloak/keycloak-saml-tomcat-adapter-core
return (SessionIdMapperUpdater) addTokenStoreUpdatersMethod.invoke(null, context, mapper, previousIdMapperUpdater);
} catch (ClassNotFoundException ex) {
log.warnv(ex, "Cannot use sessionIdMapperUpdater class {0}", idMapperSessionUpdaterClass);
return previousIdMapperUpdater;
} catch (NoSuchMethodException ex) {
log.warnv(ex, "Cannot use sessionIdMapperUpdater class {0}", idMapperSessionUpdaterClass);
return previousIdMapperUpdater;
} catch (SecurityException ex) {
log.warnv(ex, "Cannot use sessionIdMapperUpdater class {0}", idMapperSessionUpdaterClass);
return previousIdMapperUpdater;
} catch (IllegalAccessException ex) {
log.warnv(ex, "Cannot use {0}.addTokenStoreUpdaters(DeploymentInfo, SessionIdMapper) method", idMapperSessionUpdaterClass);
return previousIdMapperUpdater;
} catch (IllegalArgumentException ex) {
log.warnv(ex, "Cannot use {0}.addTokenStoreUpdaters(DeploymentInfo, SessionIdMapper) method", idMapperSessionUpdaterClass);
return previousIdMapperUpdater;
} catch (InvocationTargetException ex) {
log.warnv(ex, "Cannot use {0}.addTokenStoreUpdaters(DeploymentInfo, SessionIdMapper) method", idMapperSessionUpdaterClass);
return previousIdMapperUpdater;
代码示例来源:origin: org.keycloak/keycloak-saml-as7-adapter
private static void warnIfRemoteStoreIsUsed(Cache<String, String[]> ssoCache) {
final List<RemoteCacheStore> stores = getRemoteStores(ssoCache);
if (stores == null || stores.isEmpty()) {
return;
}
LOG.warnv("Unable to listen for events on remote stores configured for cache {0} (unsupported in this Infinispan limitations), logouts will not be propagated.", ssoCache.getName());
}
代码示例来源:origin: ModeShape/modeshape
private ModuleIdentifier moduleIdentifierFromName(String moduleName) {
if (StringUtil.isBlank(moduleName)) {
return null;
}
try {
return ModuleIdentifier.fromString(moduleName.trim());
} catch (IllegalArgumentException e) {
LOG.warnv("{0} is not a valid module identifier", moduleName);
return null;
}
}
代码示例来源:origin: org.kie.server/kie-server-router-proxy
try {
if(!toWatch.toFile().exists()) {
log.warnv("configuration file does not exists {0} ", this.toWatch);
Thread.sleep(sleepTime);
continue;
代码示例来源:origin: kiegroup/droolsjbpm-integration
try {
if(!toWatch.toFile().exists()) {
log.warnv("configuration file does not exists {0} ", this.toWatch);
Thread.sleep(sleepTime);
continue;
代码示例来源:origin: ModeShape/modeshape
return moduleLoader().loadModule(moduleId).getClassLoader();
} catch (ModuleLoadException e) {
LOG.warnv(e,
"Cannot load module from classpath entry with identifier: {0}",
moduleId);
代码示例来源:origin: jbosstm/narayana
public FaultOrResponse waitForResponse(String messageId, long millis) {
FaultOrResponse res = responses.get(messageId);
if (res == null) {
throw new IllegalStateException("The messageId " + messageId + " is not waiting for response");
}
synchronized (res) {
if (res.isEmpty()) {
// wait for the response to arrive
try {
WSCLogger.logger.tracev("AsynchronousRegistrationMapper waitForResponse {0} {1}", messageId, millis);
res.wait(millis);
} catch (InterruptedException e) {
WSCLogger.logger.warnv("AsynchronousRegistrationMapper waitForResponse: being interrupted and this should not happen!");
}
}
// remove the response cos it's filled
responses.remove(messageId);
}
WSCLogger.logger.tracev("AsynchronousRegistrationMapper addClientMessage returning isResponse={0} isFault={1}",
res.isResponse(), res.isFault());
return res;
}
代码示例来源:origin: ModeShape/modeshape
LOGGER.warnv(
"Cannot deploy ModeShape webapp {0} because it cannot be located by the main modeshape module", webappName);
return;
代码示例来源:origin: org.keycloak/keycloak-model-api
public static boolean verify(KeycloakSession session, PasswordPolicy passwordPolicy, String password, UserCredentialValueModel credential) {
String algorithm = credential.getAlgorithm() != null ? credential.getAlgorithm() : passwordPolicy.getHashAlgorithm();
PasswordHashProvider provider = session.getProvider(PasswordHashProvider.class, algorithm);
if (provider == null) {
log.warnv("Could not find hash provider {0} for password", algorithm);
return false;
}
return provider.verify(password, credential);
}
代码示例来源:origin: org.keycloak/keycloak-model-api
public static UserCredentialValueModel encode(KeycloakSession session, PasswordPolicy passwordPolicy, String rawPassword) {
String algorithm = passwordPolicy.getHashAlgorithm();
int iterations = passwordPolicy.getHashIterations();
if (iterations < 1) {
iterations = 1;
}
PasswordHashProvider provider = session.getProvider(PasswordHashProvider.class, passwordPolicy.getHashAlgorithm());
if (provider == null) {
log.warnv("Could not find hash provider {0} from password policy, using default provider {1}", algorithm, Constants.DEFAULT_HASH_ALGORITHM);
provider = session.getProvider(PasswordHashProvider.class, Constants.DEFAULT_HASH_ALGORITHM);
}
return provider.encode(rawPassword, iterations);
}
代码示例来源:origin: org.keycloak/keycloak-saml-as7-adapter
LOG.warnv("Cannot determine parameters of SSO cache for deployment {0}.", host + contextPath);
LOG.warnv("SSO cache mode is {0}, it is recommended to use replicated mode instead.", ssoCacheConfiguration.clustering().cacheModeString());
LOG.warnv("Failed to obtain distributed session cache container, lookup={0}", cacheContainerLookup);
return previousIdMapperUpdater;
代码示例来源:origin: org.keycloak/keycloak-saml-wildfly-adapter
LOG.warnv("Cannot determine parameters of SSO cache for deployment {0}.", deploymentInfo.getDeploymentName());
LOG.warnv("SSO cache mode is {0}, it is recommended to use replicated mode instead.", ssoCacheConfiguration.clustering().cacheModeString());
LOG.warnv("Failed to obtain distributed session cache container, lookup={0}", cacheContainerLookup);
return previousIdMapperUpdater;
代码示例来源:origin: thorntail/thorntail
indexer.index(contentStream);
} catch (IOException indexerIOException) {
LOGGER.warnv(indexerIOException,
"Failed parsing: {0} from archive: {1}",
entry.getKey().get(),
代码示例来源:origin: io.thorntail/container
indexer.index(contentStream);
} catch (IOException indexerIOException) {
LOGGER.warnv(indexerIOException,
"Failed parsing: {0} from archive: {1}",
entry.getKey().get(),
代码示例来源:origin: org.wildfly.swarm/container
indexer.index(contentStream);
} catch (IOException indexerIOException) {
LOGGER.warnv(indexerIOException,
"Failed parsing: {0} from archive: {1}",
entry.getKey().get(),
内容来源于网络,如有侵权,请联系作者删除!