Added some log

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/vre-management/smart-executor@150908 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Luca Frosini 2017-07-07 13:22:21 +00:00
parent b00cd5e9d9
commit 7c90dfa561
1 changed files with 5 additions and 1 deletions

View File

@ -64,9 +64,13 @@ public class SmartExecutorInitializator implements ApplicationManager {
try {
authorizationEntry = Constants.authorizationService().get(token);
} catch (Exception e) {
logger.trace("Context was not retrieved from token. Going to get it from {}", ScopeProvider.class.getSimpleName());
return ScopeProvider.instance.get();
}
return authorizationEntry.getContext();
String context = authorizationEntry.getContext();
logger.trace("Context retrieved from token is {}. Context in {} is {}",
context, ScopeProvider.class.getSimpleName(), ScopeProvider.instance.get());
return context;
}
public static String getCurrentScope(String token) throws ObjectNotFound, Exception{