With local mode the server is launched by IDEA when you start your application and is stopped when you stop your application.
With remote mode you launch your server manually and IDEA connects to it on application start and disconnects from it on application stop, leaving the server running.
When to use which configuration depends on your environment. With local mode you always start with a clean server instance, as the server is started freshly and has no artifacts from previous runs. While in remote mode you have shorter turnaround times, as you don't have to start/stop the server every time.
With local mode the server is launched by IDEA when you start your application and is stopped when you stop your application.
With remote mode you launch your server manually and IDEA connects to it on application start and disconnects from it on application stop, leaving the server running.
When to use which configuration depends on your environment. With local mode you always start with a clean server instance, as the server is started freshly and has no artifacts from previous runs. While in remote mode you have shorter turnaround times, as you don't have to start/stop the server every time.