mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-22 15:10:02 +00:00
Use AppLog and System.Logger for logging rather than slf4j-api
The avaje-applog-slf4j dependency means this is still using slf4j-api for implementation. Remove that dependency and service load the desired implementation.
This commit is contained in:
1 parent
d145e6494d
commit
a23f241fff
108 files changed
+668
-758
No files matched your search
@@ -1,24 +1,24 @@
|
||||
package io.localtest;
|
||||
|
||||
import io.avaje.applog.AppLog;
|
||||
import io.ebean.DB;
|
||||
import io.ebean.Database;
|
||||
import io.ebean.annotation.PersistBatch;
|
||||
import io.ebean.annotation.Platform;
|
||||
import io.ebeaninternal.api.SpiEbeanServer;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.lang.System.Logger.Level;
|
||||
import java.sql.Types;
|
||||
|
||||
public abstract class BaseTestCase {
|
||||
|
||||
protected static Logger logger = LoggerFactory.getLogger(BaseTestCase.class);
|
||||
protected static System.Logger logger = AppLog.getLogger(BaseTestCase.class);
|
||||
|
||||
/**
|
||||
* this is the clock delta that may occur between testing machine and db server.
|
||||
* If the clock delta of DB server is in future, an "asOf" query may not find the
|
||||
* correct entry.
|
||||
*
|
||||
* <p>
|
||||
* Note: That some tests may use a Thread.sleep to wait, so that the local system clock
|
||||
* can catch up. So don't set that to a too high value.
|
||||
*/
|
||||
@@ -35,7 +35,7 @@ public abstract class BaseTestCase {
|
||||
// First try, if we get the default server. If this fails, all tests will fail.
|
||||
DB.getDefault();
|
||||
} catch (Throwable e) {
|
||||
logger.error("Fatal error while getting ebean-server. Exiting...", e);
|
||||
logger.log(Level.ERROR, "Fatal error while getting ebean-server. Exiting...", e);
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
@@ -47,7 +47,7 @@ public abstract class BaseTestCase {
|
||||
public boolean isSqlServer() {
|
||||
return Platform.SQLSERVER == platform();
|
||||
}
|
||||
|
||||
|
||||
public boolean isDB2() {
|
||||
return Platform.DB2 == platform();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user