#vulnerable code 
                                @Test
    public void testDrivingSelectWithoutParametersUsingParameterStream() {
        db().select("select count(*) from person") //
                .parameters(1, 2, 3) //
                .getAs(Integer.class) //
                .test().awaitDone(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                .awaitDone(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                .assertValues(3, 3, 3) //
                .assertComplete();
    } 
                            #location 4 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                                @Test
    public void testDrivingSelectWithoutParametersUsingParameterStream() {
        try (Database db = db()) {
            db.select("select count(*) from person") //
                    .parameters(1, 2, 3) //
                    .getAs(Integer.class) //
                    .test().awaitDone(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                    .awaitDone(TIMEOUT_SECONDS, TimeUnit.SECONDS) //
                    .assertValues(3, 3, 3) //
                    .assertComplete();
        }
    }