@Test public void testGetExistingRdsConfigByNameAndDefaultWorkspace() { when(rdsConfigRepository.findByNameAndWorkspaceId(eq(TEST_RDS_CONFIG_NAME), eq(1L))).thenReturn(Optional.ofNullable(testRdsConfig)); underTest.getByNameForWorkspace(TEST_RDS_CONFIG_NAME, defaultWorkspace); verify(rdsConfigRepository).findByNameAndWorkspaceId(anyString(), eq(1L)); }
public RDSConfig getByNameForWorkspace(String name, Workspace workspace) { return getByNameForWorkspaceId(name, workspace.getId()); }
RdsConfigService extends AbstractWorkspaceAwareResourceService<RDSConfig> { public RDSConfig getByNameForWorkspace(String name, Workspace workspace) { return getByNameForWorkspaceId(name, workspace.getId()); } }
RdsConfigService extends AbstractWorkspaceAwareResourceService<RDSConfig> { public RDSConfig getByNameForWorkspace(String name, Workspace workspace) { return getByNameForWorkspaceId(name, workspace.getId()); }  }
RdsConfigService extends AbstractWorkspaceAwareResourceService<RDSConfig> { public RDSConfig getByNameForWorkspace(String name, Workspace workspace) { return getByNameForWorkspaceId(name, workspace.getId()); }  Set<RDSConfig> findByNamesInWorkspace(Set<String> names, @NotNull Long workspaceId); Set<RDSConfig> retrieveRdsConfigsInWorkspace(Workspace workspace); RDSConfig getByNameForWorkspace(String name, Workspace workspace); RDSConfig get(Long id); RDSConfig getByStackCrnAndType(String stackCrn, DatabaseType databaseType); @Override RDSConfig delete(RDSConfig rdsConfig); RDSConfig createIfNotExists(User user, RDSConfig rdsConfig, Long workspaceId); Set<RDSConfig> findByClusterId(Long clusterId); RDSConfig findByClusterIdAndType(Long clusterId, DatabaseType databaseType); void deleteDefaultRdsConfigs(Set<RDSConfig> rdsConfigs); Set<RDSConfig> findAllByWorkspaceId(Long workspaceId); @Override WorkspaceResourceRepository<RDSConfig, Long> repository(); Set<Cluster> getClustersUsingResource(RDSConfig rdsConfig); RDSConfig resolveVaultValues(RDSConfig config); }
RdsConfigService extends AbstractWorkspaceAwareResourceService<RDSConfig> { public RDSConfig getByNameForWorkspace(String name, Workspace workspace) { return getByNameForWorkspaceId(name, workspace.getId()); }  Set<RDSConfig> findByNamesInWorkspace(Set<String> names, @NotNull Long workspaceId); Set<RDSConfig> retrieveRdsConfigsInWorkspace(Workspace workspace); RDSConfig getByNameForWorkspace(String name, Workspace workspace); RDSConfig get(Long id); RDSConfig getByStackCrnAndType(String stackCrn, DatabaseType databaseType); @Override RDSConfig delete(RDSConfig rdsConfig); RDSConfig createIfNotExists(User user, RDSConfig rdsConfig, Long workspaceId); Set<RDSConfig> findByClusterId(Long clusterId); RDSConfig findByClusterIdAndType(Long clusterId, DatabaseType databaseType); void deleteDefaultRdsConfigs(Set<RDSConfig> rdsConfigs); Set<RDSConfig> findAllByWorkspaceId(Long workspaceId); @Override WorkspaceResourceRepository<RDSConfig, Long> repository(); Set<Cluster> getClustersUsingResource(RDSConfig rdsConfig); RDSConfig resolveVaultValues(RDSConfig config);  }