Freehub disengages and then rengages — what is the issue?
Most likely pawls or other parts of freehub's engagement mechanism have become sticky. Opening it, cleaning it up and applying light grease (if at all) should help.

Much less likely but not impossible is that the pawls have become worn. Replacing them is then in order. In any case, servicing the freehub is the first thing to do.