Any judge of a probate court wherein any action for divorce is pending may appoint an attorney to investigate and report to the court in relation thereto and may direct such attorney, or any other attorney, to defend the action. The attorney may be appointed either before or after a judgment of divorce nisi has been granted, and may enter objections to such judgment nisi becoming absolute in the same manner as the defendant. His compensation shall be fixed by the court, and shall be paid by the commonwealth, together with any expenses approved by the court, upon certificate by a justice to the state treasurer. The state police, local police and probation officers shall assist the attorneys so appointed, upon his request.
Mass. Gen. Laws ch. 208, § 16