Log Analytics tool to track only specific static files


#1

I’m wanting to use the Log Analytics tool on a site I have that doesn’t run any javascript. There is one page that has some static files for download and I want to track that, but I don’t want to track every static file that gets downloaded.

I see in the FAQ that there is a way to exclude specific log lines. Since the files I want to track are only on one page, example.com/downloads.html, is there a way I can exclude tracking of all of ther static files? Or is there a way I can track only specific static files?


#2

I can see in import_logs.py:


STATIC_EXTENSIONS = (
    'gif jpg jpeg png bmp ico svg ttf eot woff class swf css js xml robots.txt'
).split()


DOWNLOAD_EXTENSIONS = (
    '7z aac arc arj asf asx avi bin csv deb dmg doc exe flv gz gzip hqx '
    'jar mpg mp2 mp3 mp4 mpeg mov movie msi msp odb odf odg odp '
    'ods odt ogg ogv pdf phps ppt qt qtm ra ram rar rpm sea sit tar tbz '
    'bz2 tbz tgz torrent txt wav wma wmv wpd xls xml z zip'
).split()

Is it possible I could change the settings of one of these two blocks to only the filetypes I want to track? The files are all ebook format, so the type doesn’t appear anywhere else on the site.