Skip to content
Snippets Groups Projects
Select Git revision
  • main default protected
  • release
  • android-hotfix
  • dependabot/go_modules/github.com/shirou/gopsutil/v3-3.22.10
  • dependabot/go_modules/github.com/prometheus/client_golang-1.13.1
  • dependabot/go_modules/github.com/alecthomas/kong-0.7.0
  • docker-rebuild
  • conn-test
  • v1.18.4-verboseidx
  • discosrv
  • stdiscosrv-v1.18.1.1
  • release-next
  • AudriusButkevicius-patch-1
  • next-rel
  • model/fixIgnoreTest
  • v1.4
  • v0.14.46-android
  • v0.14.45-android
  • v0.13
  • v0.12
  • v1.22.2-rc.1
  • v1.22.1
  • v1.22.1-rc.2
  • v1.22.1-rc.1
  • v1.22.0
  • v1.22.0-rc.2
  • v1.22.0-rc.1
  • v1.21.0
  • v1.21.0-rc.2
  • v1.21.0-rc.1
  • v1.20.4
  • v1.20.4-rc.2
  • v1.20.4-rc.1
  • v1.20.3
  • v1.20.3-rc.2
  • v1.20.3-rc.1
  • v1.20.2
  • v1.20.2-rc.3
  • v1.20.2-rc.2
  • v1.20.2-rc.1
40 results

syncthing

  • Clone with SSH
  • Clone with HTTPS
  • user avatar
    Jakob Borg authored
    Instead of just immediately dropping the event if the subscription isn't
    ready to receive it, give it 15 ms to catch up. The value 15 ms is
    grabbed out of thin air - it just seems reasonable to me.
    
    The timer juggling makes the event send pretty much exactly twice as
    slow as it was before, but we're still under a microsecond. I think it's
    negligible compared to whatever event that just happened that we're
    interested in logging (usually a file operation of some kind).
    
    	benchmark                  old ns/op     new ns/op     delta
    	BenchmarkBufferedSub-8     475           950           +100.00%
    
    	benchmark                  old allocs     new allocs     delta
    	BenchmarkBufferedSub-8     4              4              +0.00%
    
    	benchmark                  old bytes     new bytes     delta
    	BenchmarkBufferedSub-8     104           117           +12.50%
    
    GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3960
    fdcbd54c
    History
    Name Last commit Last update