Class RestartServer
java.lang.Object
org.springframework.boot.devtools.restart.server.RestartServer
Server used to
restart
the current application with updated
ClassLoaderFiles
.- Since:
- 1.3.0
- Author:
- Phillip Webb
-
Constructor Summary
ConstructorDescriptionRestartServer
(SourceDirectoryUrlFilter sourceDirectoryUrlFilter) Create a newRestartServer
instance.RestartServer
(SourceDirectoryUrlFilter sourceDirectoryUrlFilter, ClassLoader classLoader) Create a newRestartServer
instance. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
restart
(Set<URL> urls, ClassLoaderFiles files) Called to restart the application.void
updateAndRestart
(ClassLoaderFiles files) Update the current running application with the specifiedClassLoaderFiles
and trigger a reload.
-
Constructor Details
-
RestartServer
Create a newRestartServer
instance.- Parameters:
sourceDirectoryUrlFilter
- the source filter used to link remote directory to the local classpath
-
RestartServer
Create a newRestartServer
instance.- Parameters:
sourceDirectoryUrlFilter
- the source filter used to link remote directory to the local classpathclassLoader
- the application classloader
-
-
Method Details
-
updateAndRestart
Update the current running application with the specifiedClassLoaderFiles
and trigger a reload.- Parameters:
files
- updated class loader files
-
restart
Called to restart the application.- Parameters:
urls
- the updated URLsfiles
- the updated files
-