Credit for prior service shall be granted to each person who was employed by a contracting agency at the time of becoming a member and who became a member on the effective date of the agency’s contract or within three years after last rendering prior service.