Created
March 19, 2020 14:49
-
-
Save sarxos/832e9080a73b533d0a4dd14a43002bef to your computer and use it in GitHub Desktop.
A @ BuildStep to register files as hot deployment resources
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @BuildStep | |
| List<HotDeploymentWatchedFileBuildItem> hotDeploymentWatchedFiles(LaunchModeBuildItem launchMode) { | |
| List<HotDeploymentWatchedFileBuildItem> watchedFiles = new ArrayList<>(); | |
| watchedFiles.add(new HotDeploymentWatchedFileBuildItem("META-INF/persistence.xml")); | |
| watchedFiles.add(new HotDeploymentWatchedFileBuildItem(INTEGRATOR_SERVICE_FILE)); | |
| watchedFiles.add(new HotDeploymentWatchedFileBuildItem(SERVICE_CONTRIBUTOR_SERVICE_FILE)); | |
| getSqlLoadScript(launchMode.getLaunchMode()).ifPresent(script -> { | |
| watchedFiles.add(new HotDeploymentWatchedFileBuildItem(script)); | |
| }); | |
| return watchedFiles; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment