Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2008 > BOOK: Microsoft SQL Server 2008 Integration Services Problem-Design-Solution
|
BOOK: Microsoft SQL Server 2008 Integration Services Problem-Design-Solution
This is the forum to discuss the Wrox book Microsoft SQL Server 2008 Integration Services Problem-Design-Solution by Erik Veerman, Jessica M. Moss, Brian Knight, Jay Hackney ; ISBN: 978-0-470-52576-0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Microsoft SQL Server 2008 Integration Services Problem-Design-Solution section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 8th, 2011, 09:04 PM
Registered User
 
Join Date: Jul 2011
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default Framework Configuration Management CH02 - Turn logging on/off (Share experience)

Hi,

After I implemented the framework, my boss suggested to configure the logging feature to be able to turn on/off. I understand his point of view that the logging of each task execution details may not be necessary, and it only needs to be turned on for debugging and troubleshooting.

I implemented this configuration of turning logging on/off by change the event handler property 'disable' - make this configurable via the configuration table:
  • add SSIS package configuration (SQL SERVER Type) with below value:
  • This can be done by adding a new sql server type configuration in the package configuration wizard and choose the correct property e.g. "EventHandlers[OnPostExecute].Properties[Disable]". The value end up being added into the configuration table:

    ConfigurationFilter ConfiguredValue PackagePath ConfiguredValueType
    PkgLevel_PostExecuteEvent False \Package.EventHandlers[OnPostExecute].Properties[Disable] Boolean
    PkgLevel_PreExecuteEvent False \Package.EventHandlers[OnPreExecute].Properties[Disable] Boolean
    PkgLevel_VaraibleValueChangedEvent False \Package.EventHandlers[OnVariableValueChanged].Properties[Disable] Boolean
  • Or just add the configuration value in the table, and use the SSIS package configuration wizard to filter each configuration.
    INSERT INTO [Framework].[SSISConfigurations]
    ([ConfigurationFilter]
    ,[ConfiguredValue]
    ,[PackagePath]
    ,[ConfiguredValueType])
    VALUES
    ('PkgLevel_PreExecuteEvent'
    ,'False'
    ,'\Package.EventHandlers[OnPreExecute].Properties[Disable]'
    ,'Boolean')
    ;

    INSERT INTO [Framework].[SSISConfigurations]
    ([ConfigurationFilter]
    ,[ConfiguredValue]
    ,[PackagePath]
    ,[ConfiguredValueType])
    VALUES
    ('PkgLevel_PostExecuteEvent'
    ,'False'
    ,'\Package.EventHandlers[OnPostExecute].Properties[Disable]'
    ,'Boolean')
    ;

    INSERT INTO [Framework].[SSISConfigurations]
    ([ConfigurationFilter]
    ,[ConfiguredValue]
    ,[PackagePath]
    ,[ConfiguredValueType])
    VALUES
    ('PkgLevel_VaraibleValueChangedEvent'
    ,'False'
    ,'\Package.EventHandlers[OnVariableValueChanged].Properties[Disable]'
    ,'Boolean')
    ;
  • I can then change the ConfiguredValue to true if the logging needs to be turned on.

Because we must keep the 'OnError' event handler logging, I could not turn on/off on the "SQL LogPackageStart" or "SQL LogPackageEnd" as this will break the FK constraints.

Hope this is helpful to anyone who wants to do similar thing. And please let me know if you have better ideas.

Kind Regards,
Min
 
Old April 16th, 2012, 04:35 PM
Registered User
 
Join Date: Jan 2012
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Thumbs up reset logs

Hi I added a sql task to clean the log tables and added a configuration to disable/enable it in a similar way you did...

-- clean

TRUNCATE TABLE dbo.PackageErrorLog
GO
TRUNCATE TABLE dbo.PackageTaskLog
GO
DELETE dbo.PackageLog
go
delete dbo.BatchLog
go
delete dbo.PackageVersion
go
delete dbo.Package
go


===
the var
!@[User::LogsClear]
===
the config
-- LogsClear
INSERT INTO [dbo].[SSIS Configurations]
([ConfigurationFilter]
,[ConfiguredValue]
,[PackagePath]
,[ConfiguredValueType])
VALUES
('CommonConfigurations'
,'False'
,'\Package.Variables[User::LogsClear].Properties[Value]'
,'Boolean')
Hope it helps...
mamatucci.wordpress.com





Similar Threads
Thread Thread Starter Forum Replies Last Post
Framework Configuration Management CH02 Discussion minnie.schurr BOOK: Microsoft SQL Server 2008 Integration Services Problem-Design-Solution 0 September 8th, 2011 01:16 AM
Framework management setup CH02 warning mesage minnie.schurr BOOK: Microsoft SQL Server 2008 Integration Services Problem-Design-Solution 2 September 6th, 2011 10:36 PM
.net framework configuration jwhitley .NET Framework 2.0 2 August 8th, 2007 07:54 PM
SSIS - Built-In Logging / Custom Logging ivobecker23 SQL Server 2005 0 April 21st, 2006 05:41 AM
Regarding TO .NET Framework Configuration vppatil_dotnet General .NET 0 September 28th, 2004 01:54 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.