moving to a per-client structure