Example #1
0
        except:
            pass
        try:
            self.file.close()
        except:
            pass
    
    
if __name__ == '__main__':
    from b3.fake import fakeConsole
    
    print "------------------------------------"
    config = b3.config.XmlConfigParser()
    config.setXml("""
    <configuration plugin="httpytail">
        <settings name="settings">
            <set name="timeout">15</set>
            <set name="maxGapBytes">1024</set>
        </settings>
    </configuration>
    """)
    p = HttpytailPlugin(fakeConsole, config)

    
    print "------------------------------------"
    p = HttpytailPlugin(fakeConsole)

    p.initThread('http://www.somewhere.tld/somepath/somefile.log')
    time.sleep(30)
    fakeConsole.shutdown()
    time.sleep(8)
Example #2
0
        except:
            pass
        try:
            self.file.close()
        except:
            pass
    
    
if __name__ == '__main__':
    from b3.fake import fakeConsole
    
    print "------------------------------------"
    config = b3.config.XmlConfigParser()
    config.setXml("""
    <configuration plugin="httpytail">
        <settings name="settings">
            <set name="timeout">15</set>
            <set name="maxGapBytes">1024</set>
        </settings>
    </configuration>
    """)
    p = HttpytailPlugin(fakeConsole, config)

    
    print "------------------------------------"
    p = HttpytailPlugin(fakeConsole)

    p.initThread('http://www.somewhere.tld/somepath/somefile.log')
    time.sleep(30)
    fakeConsole.shutdown()
    time.sleep(8)