Added configurable compression threshold