#vulnerable code 
                                @Test
    public void testInsert() {
        Database db = db();
        db.update("insert into person(name, score) values(?,?)") //
                .parameters("DAVE", 12, "ANNE", 18) //
                .counts() //
                .test().awaitDone(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                .assertValues(1, 1) //
                .assertComplete();
        List<Tuple2<String, Integer>> list = db.select("select name, score from person") //
                .getAs(String.class, Integer.class) //
                .toList() //
                .timeout(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                .blockingGet();
        assertTrue(list.contains(Tuple2.create("DAVE", 12)));
        assertTrue(list.contains(Tuple2.create("ANNE", 18)));
    } 
                            #location 11 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                                @Test
    public void testInsert() {
        try (Database db = db()) {
            db.update("insert into person(name, score) values(?,?)") //
                    .parameters("DAVE", 12, "ANNE", 18) //
                    .counts() //
                    .test().awaitDone(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                    .assertValues(1, 1) //
                    .assertComplete();
            List<Tuple2<String, Integer>> list = db.select("select name, score from person") //
                    .getAs(String.class, Integer.class) //
                    .toList() //
                    .timeout(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                    .blockingGet();
            assertTrue(list.contains(Tuple2.create("DAVE", 12)));
            assertTrue(list.contains(Tuple2.create("ANNE", 18)));
        }
    }