The Commissioner of Transportation, if he finds that a dangerous condition exists at such crossing, except a dangerous condition arising out of improper or inadequate maintenance, shall issue such order to such municipality or to any such public service company directing the removal, change or relocation of such crossing, highway, tracks, pipes, wires, poles or other fixtures or tree or building or other structure, as may be necessary to eliminate such dangerous condition; and shall apportion the cost thereof among such public service company or companies, such municipality and the state, and shall determine the conditions and the time and manner of the payment of such apportionments, provided the portion of the cost to be paid by such public service company in the elimination of any such dangerous conditions on state maintained highways shall not exceed ten per cent. The party or parties ordered by said commissioner to perform the work necessary to remove such dangerous condition shall serve written notice, at least thirty days prior to the approximate date of the commencement of such work, upon all other parties in interest, including any public service company whose plant is involved or affected by such work, and any such public service company shall provide such means as may be necessary for the continued use of such plant in such manner as to best serve the interests and convenience of the public.