If you file for divorce in Germany, the judgment will be issued by the German court.
Dismissing your divorce and refiling in another nation can raise jurisdictional complications. If you are interested in doing that, it's wise to consult lawyers in both jurisdictions about the ramifications of your proposed actions.

