The commissioner may petition for an order dissolving the corporate existence of a domestic insurer or the United States branch of an alien insurer domiciled in this state at the time the commissioner applies for a liquidation order. If the court issues a liquidation order, it also shall order dissolution if the commissioner has petitioned for it. The court shall order dissolution of the corporation upon petition by the commissioner at any time after a liquidation order has been granted. If the dissolution has not previously occurred, it shall be effected by operation of law upon the discharge of the liquidator. The commissioner shall file a dissolution with the secretary of state pursuant to section 302A.711, subdivision 2, paragraphs (a), clauses (1), (2), and (5), and (b); and subdivisions 3 and 4.