title: Logging WCF Request to Database
body: <p>I want to log every request xml message in my WCF service project to database. Please suggest me which is the best and preferred approach. </p>
  
  <p>1) Using idispatchmessageinspector interface</p>
  
  <p><a href="http://msdn.microsoft.com/en-us/library/system.servicemodel.dispatcher.idispatchmessageinspector(v=VS.90).aspx" rel="nofollow noreferrer">http://msdn.microsoft.com/en-us/library/system.servicemodel.dispatcher.idispatchmessageinspector(v=VS.90).aspx</a></p>
  
  <p>OR</p>
  
  <p>2) writing Custom SQL database trace listener? </p>