org.jboss.logging.Logger.debugv()方法的使用及代码示例

x33g5p2x  于2022-01-23 转载在 其他  
字(9.9k)|赞(0)|评价(0)|浏览(192)

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

Logger.debugv介绍

[英]Issue a log message with a level of DEBUG using java.text.MessageFormat-style formatting.
[中]使用java发出具有调试级别的日志消息。文本MessageFormat样式格式化。

代码示例

代码示例来源:origin: hibernate/hibernate-orm

  1. @Override
  2. public void nullSafeSet(
  3. PreparedStatement st, Object value, int index, SharedSessionContractImplementor session)
  4. throws HibernateException, SQLException {
  5. if ( value == null ) {
  6. log.debugv("Binding null to parameter {0} ",index);
  7. st.setNull( index, Types.VARCHAR );
  8. }
  9. else {
  10. String stringValue = BitSetTypeDescriptor.INSTANCE.toString( (BitSet) value );
  11. log.debugv("Binding {0} to parameter {1} ", stringValue, index);
  12. st.setString( index, stringValue );
  13. }
  14. }

代码示例来源:origin: hibernate/hibernate-orm

  1. @Override
  2. public Object nullSafeGet(
  3. ResultSet rs, String[] names, SharedSessionContractImplementor session, Object owner)
  4. throws HibernateException, SQLException {
  5. String columnName = names[0];
  6. String columnValue = (String) rs.getObject( columnName );
  7. log.debugv("Result set column {0} value is {1}", columnName, columnValue);
  8. return columnValue == null ? null :
  9. BitSetTypeDescriptor.INSTANCE.fromString( columnValue );
  10. }

代码示例来源:origin: hibernate/hibernate-orm

  1. @Override
  2. public boolean onFlushDirty(
  3. Object entity,
  4. Serializable id,
  5. Object[] currentState,
  6. Object[] previousState,
  7. String[] propertyNames,
  8. Type[] types) {
  9. LOGGER.debugv( "Entity {0}#{1} changed from {2} to {3}",
  10. entity.getClass().getSimpleName(),
  11. id,
  12. Arrays.toString( previousState ),
  13. Arrays.toString( currentState )
  14. );
  15. return super.onFlushDirty( entity, id, currentState,
  16. previousState, propertyNames, types
  17. );
  18. }
  19. }

代码示例来源:origin: org.wildfly/wildfly-testsuite-shared

  1. private File writeProperties(Properties properties, String fileName) throws IOException {
  2. File result = new File(tempFolder, fileName);
  3. LOGGER.debugv("Creating property file {0}", result);
  4. try (FileOutputStream fos = new FileOutputStream(result)) {
  5. // comment $REALM_NAME is just a workaround for https://issues.jboss.org/browse/WFLY-7104
  6. properties.store(fos, "$REALM_NAME=" + name + "$");
  7. }
  8. return result;
  9. }

代码示例来源:origin: org.wildfly/wildfly-testsuite-shared

  1. private File writeProperties(Properties properties, String fileName) throws IOException {
  2. File result = new File(tempFolder, fileName);
  3. LOGGER.debugv("Creating property file {0}", result);
  4. try (FileOutputStream fos = new FileOutputStream(result)) {
  5. // comment $REALM_NAME is just a workaround for https://issues.jboss.org/browse/WFLY-7104
  6. properties.store(fos, "$REALM_NAME=" + name + "$");
  7. }
  8. return result;
  9. }

代码示例来源:origin: ModeShape/modeshape

  1. protected static String moduleNameFor(String componentFQN) {
  2. String moduleName = MODULE_NAME_BY_COMPONENT_FQN.getProperty(componentFQN);
  3. if (StringUtil.isBlank(moduleName)) {
  4. int index = componentFQN.lastIndexOf(".");
  5. moduleName = index != -1 ? componentFQN.substring(0, index) : componentFQN;
  6. }
  7. LOG.debugv("Module name for {0} has been resolved to {1}", componentFQN, moduleName);
  8. return moduleName;
  9. }
  10. }

代码示例来源:origin: org.keycloak/keycloak-proxy-server

  1. public ConstraintBuilder constraint(String pattern) {
  2. log.debugv("add constraint: {0}", pattern);
  3. return new ConstraintBuilder(pattern);
  4. }

代码示例来源:origin: org.jboss.weld.se/weld-se

  1. protected void handleFile(File file, BeanArchiveBuilder builder) throws IOException {
  2. log.debugv("Handle archive file: {0}", file);
  3. try (ZipFile zip = new ZipFile(file)) {
  4. Enumeration<? extends ZipEntry> entries = zip.entries();
  5. ZipFileEntry entry = new ZipFileEntry(PROCOTOL_JAR + ":" + file.toURI().toURL().toExternalForm() + JAR_URL_SEPARATOR);
  6. while (entries.hasMoreElements()) {
  7. add(entry.setName(entries.nextElement().getName()), builder);
  8. }
  9. }
  10. }

代码示例来源:origin: weld/core

  1. protected void handleFile(File file, BeanArchiveBuilder builder) throws IOException {
  2. log.debugv("Handle archive file: {0}", file);
  3. try (ZipFile zip = new ZipFile(file)) {
  4. Enumeration<? extends ZipEntry> entries = zip.entries();
  5. ZipFileEntry entry = new ZipFileEntry(PROCOTOL_JAR + ":" + file.toURI().toURL().toExternalForm() + JAR_URL_SEPARATOR);
  6. while (entries.hasMoreElements()) {
  7. add(entry.setName(entries.nextElement().getName()), builder);
  8. }
  9. }
  10. }

代码示例来源:origin: weld/core

  1. protected void handleFile(File file, BeanArchiveBuilder builder) throws IOException {
  2. log.debugv("Handle archive file: {0}", file);
  3. try (ZipFile zip = new ZipFile(file)) {
  4. Enumeration<? extends ZipEntry> entries = zip.entries();
  5. ZipFileEntry entry = new ZipFileEntry(PROCOTOL_JAR + ":" + file.toURI().toURL().toExternalForm() + JAR_URL_SEPARATOR);
  6. while (entries.hasMoreElements()) {
  7. add(entry.setName(entries.nextElement().getName()), builder);
  8. }
  9. }
  10. }

代码示例来源:origin: weld/core

  1. protected void handleFile(File file, BeanArchiveBuilder builder) throws IOException {
  2. log.debugv("Handle archive file: {0}", file);
  3. try (ZipFile zip = new ZipFile(file)) {
  4. Enumeration<? extends ZipEntry> entries = zip.entries();
  5. ZipFileEntry entry = new ZipFileEntry(PROCOTOL_JAR + ":" + file.toURI().toURL().toExternalForm() + JAR_URL_SEPARATOR);
  6. while (entries.hasMoreElements()) {
  7. add(entry.setName(entries.nextElement().getName()), builder);
  8. }
  9. }
  10. }

代码示例来源:origin: org.jboss.weld.servlet/weld-servlet-shaded

  1. protected void handleFile(File file, BeanArchiveBuilder builder) throws IOException {
  2. log.debugv("Handle archive file: {0}", file);
  3. try (ZipFile zip = new ZipFile(file)) {
  4. Enumeration<? extends ZipEntry> entries = zip.entries();
  5. ZipFileEntry entry = new ZipFileEntry(PROCOTOL_JAR + ":" + file.toURI().toURL().toExternalForm() + JAR_URL_SEPARATOR);
  6. while (entries.hasMoreElements()) {
  7. add(entry.setName(entries.nextElement().getName()), builder);
  8. }
  9. }
  10. }

代码示例来源:origin: org.jboss.weld.se/weld-se-shaded

  1. protected void handleFile(File file, BeanArchiveBuilder builder) throws IOException {
  2. log.debugv("Handle archive file: {0}", file);
  3. try (ZipFile zip = new ZipFile(file)) {
  4. Enumeration<? extends ZipEntry> entries = zip.entries();
  5. ZipFileEntry entry = new ZipFileEntry(PROCOTOL_JAR + ":" + file.toURI().toURL().toExternalForm() + JAR_URL_SEPARATOR);
  6. while (entries.hasMoreElements()) {
  7. add(entry.setName(entries.nextElement().getName()), builder);
  8. }
  9. }
  10. }

代码示例来源:origin: org.keycloak/keycloak-model-mongo

  1. protected void ensureIndex(String name, String[] fields, boolean unique, boolean sparse) {
  2. DBCollection col = db.getCollection(name);
  3. BasicDBObject o = new BasicDBObject();
  4. for (String f : fields) {
  5. o.append(f, 1);
  6. }
  7. col.createIndex(o, new BasicDBObject("unique", unique).append("sparse", sparse));
  8. log.debugv("Created index {0}, fields={1}, unique={2}, sparse={3}", name, Arrays.toString(fields), unique, sparse);
  9. }

代码示例来源:origin: org.keycloak/keycloak-model-mongo

  1. private void convertOAuthClientsToClients() {
  2. DBCollection clients = db.getCollection("clients");
  3. DBCollection oauthClients = db.getCollection("oauthClients");
  4. oauthClients.dropIndex("realmId_1_name_1");
  5. oauthClients.update(new BasicDBObject(), new BasicDBObject("$rename", new BasicDBObject("name", "clientId")), false, true);
  6. oauthClients.update(new BasicDBObject(), new BasicDBObject("$set", new BasicDBObject("consentRequired", true)), false, true);
  7. DBCursor curs = oauthClients.find();
  8. while (curs.hasNext()) {
  9. clients.insert(curs.next());
  10. }
  11. oauthClients.drop();
  12. log.debugv("Converted oauthClients to clients");
  13. }

代码示例来源:origin: org.keycloak/keycloak-adapter-core

  1. public boolean handledRequest() {
  2. log.debugv("AuthenticatedActionsValve.invoke {0}", facade.getRequest().getURI());
  3. if (corsRequest()) return true;
  4. String requestUri = facade.getRequest().getURI();
  5. if (requestUri.endsWith(AdapterConstants.K_QUERY_BEARER_TOKEN)) {
  6. queryBearerToken();
  7. return true;
  8. }
  9. if (!isAuthorized()) {
  10. return true;
  11. }
  12. return false;
  13. }

代码示例来源:origin: org.keycloak/keycloak-adapter-core

  1. protected void queryBearerToken() {
  2. log.debugv("queryBearerToken {0}",facade.getRequest().getURI());
  3. if (abortTokenResponse()) return;
  4. facade.getResponse().setStatus(200);
  5. facade.getResponse().setHeader("Content-Type", "text/plain");
  6. try {
  7. facade.getResponse().getOutputStream().write(facade.getSecurityContext().getTokenString().getBytes());
  8. } catch (IOException e) {
  9. throw new RuntimeException(e);
  10. }
  11. facade.getResponse().end();
  12. }

代码示例来源:origin: org.keycloak/keycloak-adapter-core

  1. protected void completeAuthentication(BearerTokenRequestAuthenticator bearer, String method) {
  2. RefreshableKeycloakSecurityContext session = new RefreshableKeycloakSecurityContext(deployment, null, bearer.getTokenString(), bearer.getToken(), null, null, null);
  3. final KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal = new KeycloakPrincipal<RefreshableKeycloakSecurityContext>(AdapterUtils.getPrincipalName(deployment, bearer.getToken()), session);
  4. completeBearerAuthentication(principal, method);
  5. log.debugv("User ''{0}'' invoking ''{1}'' on client ''{2}''", principal.getName(), facade.getRequest().getURI(), deployment.getResourceName());
  6. }

代码示例来源:origin: org.keycloak/keycloak-model-mongo

  1. private void addRealmCodeSecret() {
  2. DBCollection realms = db.getCollection("realms");
  3. DBObject query = new QueryBuilder()
  4. .and("codeSecret").is(null).get();
  5. DBCursor objects = realms.find(query);
  6. while (objects.hasNext()) {
  7. DBObject object = objects.next();
  8. object.put("codeSecret", KeycloakModelUtils.generateCodeSecret());
  9. realms.save(object);
  10. log.debugv("Added realm.codeSecret, id={0}", object.get("id"));
  11. }
  12. }

代码示例来源:origin: org.keycloak/keycloak-adapter-core

  1. protected void completeAuthentication(OAuthRequestAuthenticator oauth) {
  2. RefreshableKeycloakSecurityContext session = new RefreshableKeycloakSecurityContext(deployment, tokenStore, oauth.getTokenString(), oauth.getToken(), oauth.getIdTokenString(), oauth.getIdToken(), oauth.getRefreshToken());
  3. final KeycloakPrincipal<RefreshableKeycloakSecurityContext> principal = new KeycloakPrincipal<RefreshableKeycloakSecurityContext>(AdapterUtils.getPrincipalName(deployment, oauth.getToken()), session);
  4. completeOAuthAuthentication(principal);
  5. log.debugv("User ''{0}'' invoking ''{1}'' on client ''{2}''", principal.getName(), facade.getRequest().getURI(), deployment.getResourceName());
  6. }

相关文章