use of com.newrelic.agent.bridge.datastore.JdbcDatabaseVendor in project newrelic-java-agent by newrelic.
the class DatabaseServiceTest method createConnectionFactory.
private ConnectionFactory createConnectionFactory(final Connection connection) {
final JdbcDatabaseVendor jdbcDatabaseVendor = new JdbcDatabaseVendor("MySQL", "database", true) {
@Override
public DatastoreVendor getDatastoreVendor() {
return DatastoreVendor.MySQL;
}
};
ConnectionFactory connectionFactory = new ConnectionFactory() {
@Override
public Connection getConnection() throws SQLException {
return connection;
}
@Override
public DatabaseVendor getDatabaseVendor() {
return jdbcDatabaseVendor;
}
};
return connectionFactory;
}
Aggregations