« Previous Next »

Thread: Receive notification of created / updated website

Last post 10-20-2009 3:10 PM by three_sixteen. 3 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (4 items)

Sort Posts:

  • 08-27-2009, 12:57 PM

    Receive notification of created / updated website

    Is there an events system in IIS 7 extensibility model that can notify an addin when a website is created (via the "Add Web Site" dialog) or when it's bindings are updated (via the "Edit Bindings" dialog)?

    I suppose it's possible to use WMI events, but I don't want to clash with asynchronous tasks that IIS might be performing after the site is actually created.

  • 10-11-2009, 9:19 AM In reply to

    Re: Receive notification of created / updated website

    You could put a watch on the metabase file, the file is xml and you could pretty easily get a list of differences - then look for what changed to see if it matches your criteria.

    I'm not aware of a simpler way to do this but haven't ever needed to look for one..

    Steve Radich - President
    BitShop.com - IIS Cloud Solution Coming Soon - Join our "Free 3 Month Beta" Waiting List Now...
  • 10-11-2009, 5:43 PM In reply to

    Re: Receive notification of created / updated website

    There is nothing I'm aware of.  You'd have to write your own using the file notfication functionality.

    Steve Schofield
    Windows Server MVP - IIS
    http://weblogs.asp.net/steveschofield


    http://www.IISLogs.com
    Log archival solution
    Install, Configure, Forget
  • 10-20-2009, 3:10 PM In reply to

    Re: Receive notification of created / updated website

     The only way I can think of doing something like this would be to have a Windows service use the System.Filesystemwatcher class to watch the IIS config file, and when it's changed maybe parse through it or something to look for new sites.

    IIS Modules and stuff only work when you get an HTTP request, right?  I'm kind of new to IIS extensions, so that may be wrong ;)

    http://msdn.microsoft.com/en-us/library/system.io.filesystemwatcher.aspx

Page 1 of 1 (4 items)
Microsoft Communities