Search in sources :

Example 1 with TransientLocalResourceRepositoryFactory

use of org.apache.hyracks.storage.common.file.TransientLocalResourceRepositoryFactory in project asterixdb by apache.

the class TestStorageManagerComponentHolder method getLocalResourceRepository.

public static synchronized ILocalResourceRepository getLocalResourceRepository() {
    if (localResourceRepository == null) {
        try {
            ILocalResourceRepositoryFactory localResourceRepositoryFactory = new TransientLocalResourceRepositoryFactory();
            localResourceRepository = localResourceRepositoryFactory.createRepository();
        } catch (HyracksException e) {
            //In order not to change the IStorageManagerInterface due to the test code, throw runtime exception.
            throw new IllegalArgumentException();
        }
    }
    return localResourceRepository;
}
Also used : ILocalResourceRepositoryFactory(org.apache.hyracks.storage.common.file.ILocalResourceRepositoryFactory) TransientLocalResourceRepositoryFactory(org.apache.hyracks.storage.common.file.TransientLocalResourceRepositoryFactory) HyracksException(org.apache.hyracks.api.exceptions.HyracksException)

Aggregations

HyracksException (org.apache.hyracks.api.exceptions.HyracksException)1 ILocalResourceRepositoryFactory (org.apache.hyracks.storage.common.file.ILocalResourceRepositoryFactory)1 TransientLocalResourceRepositoryFactory (org.apache.hyracks.storage.common.file.TransientLocalResourceRepositoryFactory)1