This week's book giveaway is in the Jython/Python forum.
We're giving away four copies of Murach's Python Programming and have Michael Urban and Joel Murach on-line!
See this thread for details.
Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Best practice to implement logs in MVC  RSS feed

 
Ritesh Pareek
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

Can anybody suggest me best practice to implement logs in MVC design pattern.


Thanks & Regards

Ritesh PAreek
 
Amit Vinod Dali
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Pattern Name = Secure Logger
Description = This pattern defines how to capture the application-specific events and exceptions in a secure and reliable manner to support security auditing. It accommodates the different behavioral nature of HTTP servlets, EJBs, SOAP messages, and other middleware events.
Logger = Java API for logging

Pattern Name = Audit Interceptor
Description = Works in conjunction with the Secure Logger pattern provides instrumentation of the logging aspects in the front, and the Audit Interceptor pattern enables the administration and manages the logging and audit in the back-end.
Logger = log4j
 
Ritesh Pareek
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for valuable information.

My major confusions are regarding following things-

1. Should i populate all log in to controller only (This topic is some how related with exception handling, right now i am throwing all exceptions back to controller from model and logging in controller)
2. Business logic require logging all create/edit/delete event (what and by whom). Can you explain me best approach for this.

Thanks

Ritesh PAreek
 
Amit Vinod Dali
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Logging-What and When
 
Ritesh Pareek
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Amit,


Thanks for this valuable link.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!