Giter Club home page Giter Club logo

Comments (4)

srid avatar srid commented on August 11, 2024

multiple tail sessions should work of course as we do exactly the same in our own product. i checked out your branch multi_tail and ran go test which passes without any issue.

from tail.

srid avatar srid commented on August 11, 2024

multiple tail sessions should work of course as we do exactly the same in our own product.

snipped from our internal code:

    tailers := []*tail.Tail{}
    [...]
    for name, logfile := range logFiles {
        t, err := tail.TailFile(logfile, tail.Config{
            Follow:      true,
            ReOpen:   true})
        if err != nil {
            log.Fatal(err)
        }
        tailers = append(tailers, t)
    }
    for _, tail := range tailers {
        err := tail.Wait()
        if err != nil {
            log.Errorf("Cannot tail [%s]: %s", tail.Filename, err)
        }
    }

The Lines channel will be read by separate goroutines.

from tail.

araddon avatar araddon commented on August 11, 2024

Thanks for the info and trying it, let me try some more investigation, im running it on Ubuntu13.04 x64 (Inotify) and getting failure on that MultiAppend test (tried on laptop + desktop)::

$ go test -run Multi
--- FAIL: TestMultiTailAppend (0.15 seconds)
tail_test.go:316: tail ended early; expecting more: [more data]
FAIL
exit status 1
FAIL    github.com/ActiveState/tail 0.157s

from tail.

araddon avatar araddon commented on August 11, 2024

Upon investigation, this turned out to be unrleated, I found the issue #9

from tail.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.