TRUNK-4030: locking mechanism for form_id