rewrote tight composition query manager