Address remarks

Signed-off-by: Anatolii Bazko <abazko@redhat.com>
pull/619/head
Anatolii Bazko 2023-12-01 14:25:19 +01:00
parent 4572179aac
commit a00f92d9af
2 changed files with 5 additions and 5 deletions

View File

@ -15,7 +15,7 @@ import org.eclipse.che.api.workspace.server.spi.InfrastructureException;
import org.eclipse.che.api.workspace.server.spi.RuntimeInfrastructure;
/**
* An exception thrown by {@link RuntimeInfrastructure} and related components. Indicates that an
* An exception thrown by {@link RuntimeInfrastructure} and related components. Indicates that a
* user is not authorized to use Che.
*
* @author Anatolii Bazko

View File

@ -585,15 +585,15 @@ public class KubernetesNamespaceFactory {
}
}
protected void validateAuthorization(String namespaceName, String userName)
protected void validateAuthorization(String namespaceName, String username)
throws InfrastructureException {
if (!authorizationChecker.isAuthorized(userName)) {
if (!authorizationChecker.isAuthorized(username)) {
try {
permissionsCleaner.cleanUp(namespaceName);
} catch (InfrastructureException | KubernetesClientException e) {
LOG.error(
"Failed to clean up permissions for user '{}' in namespace '{}'. Cause: {}",
userName,
username,
namespaceName,
e.getMessage(),
e);
@ -602,7 +602,7 @@ public class KubernetesNamespaceFactory {
throw new AuthorizationException(
format(
"User '%s' is not authorized to create a project. Please contact your system administrator.",
userName));
username));
}
}