May 2018


          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31            
 
FEEDS
 
ARCHIVES
 
RECENT ENTRIES
 
OTHER BLOGGERS
 
AGGREGATORS
 
SOCIAL NETWORKS
:: 09/27/2006 ::
ColdFusion and Rolling Your Own Logs
Return   Back To Top
I ran across a need to periodically archive my CFMX 7's logs. I initially thought about using the cffile tag and doing some combination of copy & rename actions. I quickly realized that trying to do operations on an active log file would not work. Then I remembered that wonderful coldfusion.server.ServiceFactory and the rollLog method of the LoggingService. This nifty function archives or "rolls" the log of the logfile name passed into it: rollLog("full_path_name_to logfile name plus the logfile_name"). Creating a scheduled task that periodically calls this type of function is an easy way to keep the active logs from growing too large and still maintain the former log's contents.

Here's a code example.

 

canada goose femme pas cher Soldes Louboutin Chaussures Soldes Louboutin louis vuitton taschen outlet louboutin outlet uk billig canada goose canada goose tilbud goyard pas cher longchamp bags outlet Monlcer udsalg billige parajumpers YSL replica sac louis vuitton pas cher Canada Goose Pas Cher Canada Goose Outlet UK Moncler Outlet uk goyard replica bags polo Lacoste pas cher Bolsos Longchamp España Moncler Jakker tilbud Doudoune moncler pas cher Parajumpers Jakker tilbud Ralph Lauren Soldes Parajumpers Outlet louis vuitton replica Moncler Jas sale Billiga Canada Goose Jacka Canada Goose outlet Billiga Moncler Doudoune Canada Goose Pas Cher Canada Goose Pas Cher Louboutin Soldes Canada Goose Pas Cher Hemers replica Doudoune Canada Goose Pas Cher prada replica Canada Goose Pas Cher Canada Goose Soldes Doudoune Canada Goose Pas Cher Canada Goose Pas Cher Canada Goose outlet Canada Goose outlet Canada Goose outlet