There are no preferential policies for resigning.
However, if you are a regular employee of your company, you can apply for internal withdrawal. If you are a civil servant, you can retire after 30 years of service.
If not, it’s best to stick with it. Three years will pass quickly.