Class ClassPathResourceProvider

java.lang.Object
org.jobrunr.utils.resources.ClassPathResourceProvider
All Implemented Interfaces:
AutoCloseable

public class ClassPathResourceProvider extends Object implements AutoCloseable
Class to be only used on startup to load all resources (SQL migrations and noSQL migrations) from the classpath. As Jar files need to be mounted as FileSystems which are static, this class uses explicit locking to ensure that only one consumer can access the resources at a time. It must thus always be used in a try-with-resources block.