log4jdbc
log4jdbc copied to clipboard
please support mariadb
mariadb is very good product , Please attention to it and support on log4jdbc, thanks!
@dylan-tao - Just fyi, if you're referring to the formatted SQL output, you may be able to get by with a little hack:
package some.util.pkg;
import java.lang.reflect.Constructor;
import java.lang.reflect.Field;
import java.util.Map;
public class DriverSpy extends net.sf.log4jdbc.DriverSpy {
static {
try {
Field rdbmsSpecificsField = net.sf.log4jdbc.DriverSpy.class.getDeclaredField("rdbmsSpecifics");
rdbmsSpecificsField.setAccessible(true);
Class<?> clazz = Class.forName("net.sf.log4jdbc.MySqlRdbmsSpecifics");
Constructor<?> constructor = clazz.getDeclaredConstructor();
constructor.setAccessible(true);
Map rdbmsSpecifics = (Map) rdbmsSpecificsField.get(null);
rdbmsSpecifics.put(org.mariadb.jdbc.Driver.class.getName(), constructor.newInstance());
} catch (Exception e) {
throw new ExceptionInInitializerError(e);
}
}
}
Done. Sorry for LOOONG delay :)