本文整理了Java中org.apache.openejb.util.Logger.error()
方法的一些代码示例,展示了Logger.error()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger.error()
方法的具体详情如下:
包路径:org.apache.openejb.util.Logger
类名称:Logger
方法名:error
暂无
代码示例来源:origin: org.apache.tomee/openejb-core
public static void configurationParsingError(final String messageType, final String message, final String line, final String column) {
_logger.error("as0001", messageType, message, line, column);
/*
* An error broadcasting system is under development.
* At this point an appropriate error would be broadcast to all listeners.
*/
}
代码示例来源:origin: org.apache.geronimo.ext.openejb/openejb-core
public static void configurationParsingError(String messageType, String message, String line, String column) {
_logger.error("as0001", messageType, message, line, column);
/*
* An error broadcasting system is under development.
* At this point an appropriate error would be broadcast to all listeners.
*/
}
代码示例来源:origin: org.apache.tomee/openejb-core
@Override
public Object call() throws Exception {
try {
return homeMethodInvoke(interfce, method, args);
} catch (final ApplicationException ae) {
logger.error("EjbHomeProxyHandler: Asynchronous call to '" + interfce.getSimpleName() + "' on '" + method.getName() + "' failed", ae);
throw ae;
}
}
}), method.getReturnType() == Void.TYPE);
代码示例来源:origin: org.apache.openejb/openejb-core
private void endRequest() {
for (final Runnable r : endRequestRunnables.get()) {
try {
r.run();
} catch (final Exception e) {
logger.error(e.getMessage(), e);
}
}
endRequestRunnables.remove();
}
代码示例来源:origin: org.apache.openejb/openejb-core
public static void handleUnknownError(final Throwable error, final String systemLocation) {
final ByteArrayOutputStream baos = new ByteArrayOutputStream();
final PrintWriter pw = new PrintWriter(baos);
error.printStackTrace(pw);
pw.flush();
pw.close();
_logger.error("ge0001", systemLocation, new String(baos.toByteArray()));
/*
* An error broadcasting system is under development.
* At this point an appropriate error would be broadcast to all listeners.
*/
}
代码示例来源:origin: org.apache.openejb/openejb-core
public static void unregisterSilently(final ObjectName name) {
try {
get().unregisterMBean(name);
} catch (final Exception e) {
LOGGER.error("Cannot unregister MBean " + name, e);
}
}
代码示例来源:origin: org.apache.openejb/openejb-core
public static Collection<Class<?>> findExtensions(final Finder finder) {
try {
return finder.findAvailableClasses("org.apache.openejb.extension");
} catch (final IOException e) {
LOGGER.error("Extension scanning of 'META-INF/org.apache.openejb.extension' files failed", e);
return Collections.emptySet();
}
}
代码示例来源:origin: org.apache.tomee/openejb-core
@Override
public void run() {
try {
scan();
} catch (final Exception e) {
logger.error("Scan failed.", e);
}
}
}, pollIntervalMillis, pollIntervalMillis);
代码示例来源:origin: org.apache.tomee/openejb-core
public void addJarFileUrls(final String file) {
if (new File(file).exists()) { // should we test real urls?
try {
entityManagerFactoryCallable.getUnitInfo().getJarFileUrls().add(new URL(file));
} catch (final MalformedURLException e) {
LOGGER.error("url " + file + " is malformed");
}
} else {
LOGGER.error("url " + file + " is not correct");
}
}
代码示例来源:origin: org.apache.openejb/openejb-core
public synchronized void reload() {
try {
createDelegate();
} catch (final Exception e) {
LOGGER.error("can't replace EntityManagerFactory " + delegate, e);
}
}
代码示例来源:origin: org.apache.geronimo.ext.openejb/openejb-core
public void run() {
try {
scan();
}
catch (Exception e) {
getLogger().error("Scan failed.", e);
}
}
}, pollIntervalMillis, pollIntervalMillis);
代码示例来源:origin: org.apache.openejb/openejb-hsql
private void flushLine() {
if (!errorWriter)
logger.info(text.toString());
else
logger.error(text.toString());
text.setLength(0);
}
代码示例来源:origin: org.apache.openejb/tomee-catalina
private void optionalService(Properties properties, String className) {
try {
Service service = (Service) getClass().getClassLoader().loadClass(className).newInstance();
service.init(properties);
} catch (ClassNotFoundException e) {
logger.info("Optional service not installed: " + className);
} catch (Exception e) {
logger.error("Failed to start: " + className, e);
}
}
代码示例来源:origin: org.apache.tomee/openejb-core
public static void addExtensions(final ClassLoader loader, final Collection<String> classes) {
for (final String clazz : classes) {
try {
final Object object = loader.loadClass(clazz).getConstructor().newInstance();
SystemInstance.get().addObserver(object);
} catch (final Throwable t) {
LOGGER.error("Extension construction failed" + clazz, t);
}
}
}
代码示例来源:origin: org.apache.tomee/openejb-core
public static void addExtensions(final Collection<Class<?>> classes) {
for (final Class<?> clazz : classes) {
try {
final Object object = clazz.getConstructor().newInstance();
SystemInstance.get().addObserver(object);
} catch (final Throwable t) {
LOGGER.error("Extension construction failed" + clazz.getName(), t);
}
}
}
代码示例来源:origin: org.apache.openejb/openejb-core
public static void addExtensions(final ClassLoader loader, final Collection<String> classes) {
for (final String clazz : classes) {
try {
final Object object = loader.loadClass(clazz).newInstance();
SystemInstance.get().addObserver(object);
} catch (final Throwable t) {
LOGGER.error("Extension construction failed" + clazz, t);
}
}
}
代码示例来源:origin: org.apache.tomee/openejb-core
protected Transaction getTransaction() throws SystemException {
try {
return transactionManager.getTransaction();
} catch (final javax.transaction.SystemException e) {
txLogger.error("The Transaction Manager has encountered an unexpected error condition while attempting to obtain current transaction: {0}", e.getMessage());
throw new SystemException(e);
}
}
代码示例来源:origin: org.apache.geronimo.ext.openejb/openejb-core
protected Transaction getTransaction() throws SystemException {
try {
return transactionManager.getTransaction();
} catch (javax.transaction.SystemException e) {
txLogger.error("The Transaction Manager has encountered an unexpected error condition while attempting to obtain current transaction: {0}", e.getMessage());
throw new SystemException(e);
}
}
代码示例来源:origin: org.apache.tomee/openejb-core
@Override
public void run() {
try {
stopImpl();
} catch (final Throwable t) {
Logger.getInstance(LogCategory.OPENEJB_STARTUP, ActiveMQResourceAdapter.class).getChildLogger("service").error("ActiveMQ shutdown failed", t);
}
}
};
代码示例来源:origin: org.apache.geronimo.ext.openejb/openejb-core
protected void setRollbackOnly(Transaction tx) {
try {
if (tx != null && tx.getStatus() == Status.STATUS_ACTIVE) {
tx.setRollbackOnly();
txLogger.debug("TX {0}: setRollbackOnly() on transaction {1}", transactionType, tx);
}
} catch (Exception e) {
txLogger.error("Exception during setRollbackOnly()", e);
throw new IllegalStateException("No transaction active", e);
}
}
内容来源于网络,如有侵权,请联系作者删除!