Ejemplo n.º 1
0
        public NLogLogger(string name, string function)
        {
            var loggingParams = ApplicationCookieUtilities.GetLoggingParams(HttpContext.Current.User, function);
            var callGuid      = (string.IsNullOrEmpty(loggingParams.tenant) ? "" : loggingParams.tenant) + loggingParams.cono + loggingParams.oper.StripOffDomain() + loggingParams.callGuid;

            SetCommonMdcs(loggingParams.tenant, loggingParams.oper, loggingParams.cono, loggingParams.sessionid, loggingParams.function, loggingParams.host, callGuid);
            this.Logger = LogManager.GetLogger(name);
        }
Ejemplo n.º 2
0
        public LogoutResults Logout()
        {
            var loggingParams = ApplicationCookieUtilities.GetLoggingParams(HttpContext.Current.User, CommonStrings.Login_Renew);
            var logoutResult  = this.loginService.Logout(new LoginRequestModel {
                Oper = loggingParams.oper, Tenant = loggingParams.tenant, Cono = loggingParams.cono
            }, this.ActionContext.Request.Headers.Host, loggingParams.sessionid);

            return(logoutResult);
        }
Ejemplo n.º 3
0
        public long Renew()
        {
            var loggingParams   = ApplicationCookieUtilities.GetLoggingParams(HttpContext.Current.User, CommonStrings.Login_Renew);
            var numberOfMinutes = this.loginService.Renew(new LoginRequestModel {
                Oper = loggingParams.oper, Tenant = loggingParams.tenant, Cono = loggingParams.cono
            }, this.ActionContext.Request.Headers.Host, loggingParams.sessionid);

            _nLogLogger.Info(CommonStrings.Logging_Success + "Renew");
            return(numberOfMinutes);
        }