Codebase list golang-github-renekroon-ttlcache / upstream/2.10.0+ds
New upstream version 2.10.0+ds Sascha Steinbiss 2 years ago
3 changed file(s) with 7 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
1818 - golint .
1919 - go test -cover -race -count=1 -timeout=30s -run .
2020 - go test -covermode=count -coverprofile=coverage.out -timeout=90s -run .
21 - '[ ! -z "$COVERALLS_TOKEN" ] && $HOME/gopath/bin/goveralls -coverprofile=coverage.out -service=travis-ci -repotoken $COVERALLS_TOKEN'
21 - if [ "$TRAVIS_BRANCH" = "master" ]; then $HOME/gopath/bin/goveralls -coverprofile=coverage.out -service=travis-ci -repotoken $COVERALLS_TOKEN; fi
2222 - cd bench; go test -run=Bench.* -bench=. -benchmem; cd ..
0 # 2.10.0 (December 2021)
1
2 #62 : @nikhilk1701 found a memory leak where removed items are not directly eligible for garbage collection. There are no API changes.
3
04 # 2.9.0 (October 2021)
15
26 #55,#56,#57 : @chenyahui was on fire and greatly improved the peformance of the library. He also got rid of the blocking call to expirationNotification, making the code run twice as fast in the benchmarks!
7777 n := len(old)
7878 item := old[n-1]
7979 item.queueIndex = -1
80 // de-reference the element to be popped for Garbage Collector to de-allocate the memory
81 old[n-1] = nil
8082 pq.items = old[0 : n-1]
8183 return item
8284 }