### Question:
Jdbi implements Configurable<Jdbi> { public <X extends Exception> void useHandle(final HandleConsumer<X> consumer) throws X { withHandle(consumer.asCallback()); } private  Jdbi(ConnectionFactory connectionFactory); static Jdbi create(Connection connection); static Jdbi create(DataSource dataSource); static Jdbi create(ConnectionFactory connectionFactory); static Jdbi create(final String url); static Jdbi create(final String url, final Properties properties); static Jdbi create(final String url, final String username, final String password); static Handle open(DataSource dataSource); static Handle open(ConnectionFactory connectionFactory); static Handle open(final Connection connection); static Handle open(final String url); static Handle open(final String url, final String username, final String password); static Handle open(final String url, final Properties props); Jdbi installPlugins(); Jdbi installPlugin(JdbiPlugin plugin); Jdbi setStatementBuilderFactory(StatementBuilderFactory factory); StatementBuilderFactory getStatementBuilderFactory(); @Override ConfigRegistry getConfig(); Jdbi setTransactionHandler(TransactionHandler handler); TransactionHandler getTransactionHandler(); Handle open(); R withHandle(HandleCallback<R, X> callback); void useHandle(final HandleConsumer<X> consumer); R inTransaction(final HandleCallback<R, X> callback); void useTransaction(final HandleConsumer<X> callback); R inTransaction(final TransactionIsolationLevel level, final HandleCallback<R, X> callback); void useTransaction(final TransactionIsolationLevel level, final HandleConsumer<X> callback); R withExtension(Class<E> extensionType, ExtensionCallback<R, E, X> callback); void useExtension(Class<E> extensionType, ExtensionConsumer<E, X> callback); E onDemand(Class<E> extensionType);  }### Answer:
@Test public void testUseHandle() { Jdbi db = Jdbi.create(this.dbRule.getConnectionString()); db.useHandle(handle -> { handle.execute("insert into something (id, name) values (1, 'Brian')"); String value = handle.createQuery("select name from something where id = 1").mapToBean(Something.class).one().getName(); assertThat(value).isEqualTo("Brian"); }); }
@Test public void testGlobalStatementCustomizers() { dbRule.getJdbi().addCustomizer(StatementCustomizers.maxRows(1)) .useHandle(handle -> { handle.execute("insert into something (id, name) values (?, ?)", 1, "hello"); handle.execute("insert into something (id, name) values (?, ?)", 2, "world"); List<Something> rs = handle.createQuery("select id, name from something") .mapToBean(Something.class) .list(); assertThat(rs).hasSize(1); }); }