find a location for property in a new city

Monday, 28 May 2012

How to turn off logging on Combres

I have been using Combres for my .NET app to minify, combine and compress my JavaScript and CSS. So far I have found it awesome.

It really does do everything it claims. Minifing your scripts and CSS, then combines them all so that all the code is sent via one HTTP request (well one for CSS and one for JavaScript). It also handles GZip or deflate compression should the request accept it. It is easy to set up since it is now available through NuGet and using it will make YSlow smile when it scans your site.

Logging

One thing that is annoying though is that Combres seems to log everything it does. "Use content from content's cache for Resource x...Use content from content's cache for Resource y" This is fine in development but unnecessary in production so I wanted to turn it off but couldn't find how to do this in any documentation.

The way I managed to turn off logging was to find the line in the web.config that combres put in that looks like this:

<combres definitionUrl="~/App_Data/combres.xml" logProvider="Combres.Loggers.Log4NetLogger" />

You simply need to remove the logProvider so it looks like this:

<combres definitionUrl="~/App_Data/combres.xml" />

If you still want logging on your development environment you can simply remove the logProvider attribute in a web.config transform.

Follow britishdev on Twitter

26 comments:

  1. Please keep on posting such quality articles as this is a rare thing to find these days. I am always searching online for articles that can help me. Looking forward to another great blog. Good luck to the author! all the best! http://celabright.org

    ReplyDelete
  2. Considerably the article is in reality the greatest on this noteworthy topic. I agree with your conclusions and will eagerly look forward to your next updates. Saying thanks will not just be sufficient for the wonderful clarity in your writing. I will immediately grab your rss feed to stay privy of any updates!
    SNA Auto Rental

    ReplyDelete
  3. Please keep on the posting this article because it is rear thing.

    ReplyDelete
  4. I wanted to thank you for this great read!! I definitely enjoying every little bit of it I have you bookmarked to check out new stuff your post

    ReplyDelete
  5. This article gives the valuable information . this is very nice one and gives indepth information. thanks for this nice article.
    Walking Holidays Europe

    ReplyDelete
  6. This is my first time at your blog and I've really enjoyed looking around. I will come back again in the future to check out some of the other articles.
    Fire Stopping

    ReplyDelete
  7. Thank you! Been wanting to turn off logging for months. (That's right, this is a real comment! Blast you spam-bots and your atrocious yet amusing grammar!) For the newbies, the Web.config file is found at the root level of the ASP.NET solution folder.

    ReplyDelete
  8. I can set up my new idea from this post. It gives in depth information. Thanks for this valuable information for all,..

    Catninja.org
    Wormate-io.com

    ReplyDelete
  9. great post. Thanks for sharing this information.Tutuapp APK

    ReplyDelete
  10. Motifz Designer Lawn. 1, 2 & 3 Piece Unstitched Premium Embroidered Lawn 2019, Premium Lawn, Lawn 2019, Best lawn collection, Motifz, Best Lawn in Pakistan, Shipping worldwide. Stitching option available.

    ReplyDelete
  11. Buy Premium lawn Online for Women's at best prices available at Motifz. ✓ Latest Fashion, ✓ Trendy Designs ➤ Shop Now!

    ReplyDelete
  12. Linksys router provides the feature of a web-based setup on linksys ip address

    ReplyDelete
  13. Color print test page or black & white 720x960 is the link which can print high quality printer test page by just visiting the website test page

    ReplyDelete
  14. QuickBooks technical support phone number is available at different stores and you can work easily without any tension.

    ReplyDelete
  15. Wholesale printed custom perfume boxes with the highest quality and affordable prices. Free worldwide Delivery and free Custom Perfume Boxes design.

    ReplyDelete
  16. Packers And Movers Bangalore Local Household Shifting Service, Get Free Best Price Quotes Local Packers and Movers in Bangalore List, Compare Charges, Save Money And Time at
    Local Packers And Movers Bangalore

    ReplyDelete
  17. Buy online wholesale custom cosmetic boxes and packaging at seashore packaging at the easy price Free shipping worldwide with 24/7 customer support.

    ReplyDelete
  18. Blackbird packaging provide you with any size, shape design, custom cosmetic boxes sooner than any other packaging competitor in the market

    ReplyDelete
  19. Get Shifting/Relocation Quotation from ###Packers and Movers Delhi. Packers and Movers Delhi 100% Affordable and Reliable ***Household Shifting Services. Compare Transportation Charges and Save Time, Verified and Trusted Packers and Movers in Delhi, Cheap and Safe Local, Domestic House Shifting @ Packers And Movers Delhi

    ReplyDelete
  20. Packaging town is a one-stop solution for the short-run Custom Packaging, Wholesale cream Boxes needs, and supplies at ease.

    ReplyDelete
  21. mylar label bags in stock now. Ready made Cali pack designs. Fast Shipping at Your Supplies. Custom designs available

    ReplyDelete