@Test void GetIngestionResource_StatusTable_ReturnCorrectTable() throws IngestionServiceException, IngestionClientException { assertEquals( STATUS_TABLE, resourceManager.getIngestionResource(ResourceManager.ResourceType.INGESTIONS_STATUS_TABLE)); }
String getIngestionResource(ResourceType resourceType) throws IngestionServiceException, IngestionClientException { if (!ingestionResources.containsKey(resourceType)) { refreshIngestionResources(); try { ingestionResourcesLock.readLock().lock(); if (!ingestionResources.containsKey(resourceType)) { throw new IngestionServiceException("Unable to get ingestion resources for this type: " + resourceType.getName()); } } finally { ingestionResourcesLock.readLock().unlock(); } } return ingestionResources.get(resourceType).nextValue(); }
ResourceManager implements Closeable { String getIngestionResource(ResourceType resourceType) throws IngestionServiceException, IngestionClientException { if (!ingestionResources.containsKey(resourceType)) { refreshIngestionResources(); try { ingestionResourcesLock.readLock().lock(); if (!ingestionResources.containsKey(resourceType)) { throw new IngestionServiceException("Unable to get ingestion resources for this type: " + resourceType.getName()); } } finally { ingestionResourcesLock.readLock().unlock(); } } return ingestionResources.get(resourceType).nextValue(); } }
ResourceManager implements Closeable { String getIngestionResource(ResourceType resourceType) throws IngestionServiceException, IngestionClientException { if (!ingestionResources.containsKey(resourceType)) { refreshIngestionResources(); try { ingestionResourcesLock.readLock().lock(); if (!ingestionResources.containsKey(resourceType)) { throw new IngestionServiceException("Unable to get ingestion resources for this type: " + resourceType.getName()); } } finally { ingestionResourcesLock.readLock().unlock(); } } return ingestionResources.get(resourceType).nextValue(); } ResourceManager(Client client, long defaultRefreshTime, long refreshTimeOnFailure);   ResourceManager(Client client); }
ResourceManager implements Closeable { String getIngestionResource(ResourceType resourceType) throws IngestionServiceException, IngestionClientException { if (!ingestionResources.containsKey(resourceType)) { refreshIngestionResources(); try { ingestionResourcesLock.readLock().lock(); if (!ingestionResources.containsKey(resourceType)) { throw new IngestionServiceException("Unable to get ingestion resources for this type: " + resourceType.getName()); } } finally { ingestionResourcesLock.readLock().unlock(); } } return ingestionResources.get(resourceType).nextValue(); } ResourceManager(Client client, long defaultRefreshTime, long refreshTimeOnFailure);   ResourceManager(Client client); @Override void close(); }
ResourceManager implements Closeable { String getIngestionResource(ResourceType resourceType) throws IngestionServiceException, IngestionClientException { if (!ingestionResources.containsKey(resourceType)) { refreshIngestionResources(); try { ingestionResourcesLock.readLock().lock(); if (!ingestionResources.containsKey(resourceType)) { throw new IngestionServiceException("Unable to get ingestion resources for this type: " + resourceType.getName()); } } finally { ingestionResourcesLock.readLock().unlock(); } } return ingestionResources.get(resourceType).nextValue(); } ResourceManager(Client client, long defaultRefreshTime, long refreshTimeOnFailure);   ResourceManager(Client client); @Override void close();  }