Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8070617
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T13:26:33+00:00 2026-06-05T13:26:33+00:00

I have a MVC3 web application. I am using Ninject 2 for dependency injection

  • 0

I have a MVC3 web application. I am using Ninject 2 for dependency injection and the Ninject logging extension with log4net for logging.
My client wants to be able to “trace” a user session in Production to troubleshoot possible problems. The way we wanted to implement it is by dynamically changing the log level for that user, for example by storing a cookie so when Ninject.logging provides the logger instance, it knows to provide a log instance with level set to Debug.
I didn’t find any way to do this, either by using Ninject logging or plain log4net.
Any suggestions?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T13:26:37+00:00Added an answer on June 5, 2026 at 1:26 pm

    We ended up modifying the ninject.extension.logging in this way:
    – In LoggerFactoryBase we modified the GetLogger(IContext context) method to retrieve a cookie from the HttpContext
    – If this value is set, we get or create the logger with “Tracing.” + type name
    – In log4net config we have a logger called “Tracing” set to Debug

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

we are developing a web application using MVC3 and VS2010. We have some pdf
we are developing a web application using MVC3 and Jquery. we have a situation
I'm starting a web application with MVC3 and Ninject. There is one dependency that
I have Ninject working nicely in an ASP.NET MVC3 web application. I'd like to
I am currently creating an MVC3 application using Ninject. I have two controllers which
I've written a simple web application using asp.net mvc3 and I have a login
I am new to unit testing. I have a web application using asp.net mvc3
We're using NLog for logging in an C# MVC3 web application. All of our
I have been working on ASP.net MVC3 Web application using MSSQL 2008 R2 for
I have an MVC3 web application written in C#. I am using McvMailer to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.