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 6710101
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T07:57:40+00:00 2026-05-26T07:57:40+00:00

I am not really comfortable with this subject since I always wrote my own

  • 0

I am not really comfortable with this subject since I always wrote my own logger until now.

I have a WCF REST web service.
This service needs to log information from errors to who uses it and when.

To do so the Logging Application Block from Enterprise Library ( 5.0 ) has been chosen.
In order to maintain good performance, we decided to use MSMQ. The aim is to store the logs there until we come to put it into file at some point.

I have seen on several websites that we can use WCF to transmit the message to a MSMQ and then use another entity to work with the queue or that we can use MSMQ as a transport protocol to communicate with WCF. Right now I just use the Logger class of LAB to insert the logs in the queue.

I only want to use MSMQ to desync my webservice from the logging functionality.

So here are my questions:
What are the cases where MSMQ is useful with WCF ?
In the case I describe is it not overkill to use another WCF application just to log some things in a file?

  • 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-05-26T07:57:40+00:00Added an answer on May 26, 2026 at 7:57 am

    I think you’re confusing two things here. The MSMQ transport in WCF is just that, a transport mechanism that can be used instead of HTTP or TCP. Your issue is that (I assume) you want to log asynchronously from the WCF service, which is a good idea. EntLib includes the MSMQ Distributor service, which will pick up logging events written from your application to a queue assuming a properly-configured logging block configuration that specifies MSMQ as the destination. The distributor will then actually write it to the database.

    Asynchronous logging is a very smart thing to do, because it ensures that your events are in a persistent medium in catastrophic situations where the DB has done away, for example. Not to mention the database is not accessed as part of normal application operations, which eliminates a potential point of failure.

    I worked on a web application once that was using a custom database logging mechanism. There were places where a DB operation would take place within a transaction and upon failure (say a relational constraint error from ADO) would write a message to the log… only to have it roll back along with the main transaction. That’s the kind of problem you can get yourself into if you’re writing directly to the database as part of your exception handling strategy.

    Anyway, I’m not sure if this answers your question. Here’s a good overview on how this all works in EntLib.

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

Sidebar

Related Questions

Not really too sure how to word this question, therefore if you don't particularly
Not really sure how to phrase this other than by example.. Given... DATABASES =
I'm not really sure how to ask this question, but I'll do my best.
I am not really sure how to word this question, so I did the
I've been learning C++ and one thing that I'm not really comfortable with is
Not really a coding question more a little help with my idea of a
I not really sure how to describe correctly my problem. My layout contains a
Its not really a subtraction I'm looking for. And I know its not a
I'm not really sure how to even ask the question, let alone find an
I know your not really supposed to use Flash and SWF's in a Sencha

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.