ref 11719: Add management of VREs to the NLPHub interface

https://support.d4science.org/issues/11719

Fixed some issue on webapp:

Errors of shared variables on servlets
Added slf4j over the whole application and logs in nlphub.log
Problem of checking nulls on arrays in Javascript
Added the ability to retrieve the context and token from the RequestUri

git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/data-analysis/nlphub@167442 82a268e6-3cf1-43bd-a215-b396298e98cf
master
Giancarlo Panichi 6 years ago
parent ed5b9111ea
commit ffebf9ef49

@ -3,13 +3,17 @@ package org.gcube.data.analysis.nlphub.session;
import javax.servlet.http.HttpServletRequest;
import org.gcube.data.analysis.nlphub.shared.Constants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
public class SessionUtils {
private static final Logger logger = LoggerFactory.getLogger(SessionUtils.class);
public static String getToken(HttpServletRequest request) {
String token = request.getParameter(Constants.TOKEN_PARAMETER);
logger.debug("Token in request: "+token);
if(token == null || token.isEmpty()){
logger.error("Token in request is null");
}
return token;
}

Loading…
Cancel
Save