[MIN] RESTXQ: minor rewriting
[FIX] Extended use of AutoCloseable interface