Optimize logging handler by making RESERVED a set instead of a tuple