diff options
author | Wei-Ning Huang <w@cobinhood.com> | 2018-09-26 10:48:31 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-04-09 21:32:49 +0800 |
commit | d056357e4999c6c70c8b8e85a9e4f533895ed6c2 (patch) | |
tree | be9f205d2ed8c73d2130b47f01fed2670c1b4d64 /swarm/storage/localstore | |
parent | 953e13b21b0aae335ef655a1907a8883f1ba7be2 (diff) | |
download | dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.tar dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.tar.gz dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.tar.bz2 dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.tar.lz dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.tar.xz dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.tar.zst dexon-d056357e4999c6c70c8b8e85a9e4f533895ed6c2.zip |
Change import go github.com/dexon-foundation/dexon
Diffstat (limited to 'swarm/storage/localstore')
-rw-r--r-- | swarm/storage/localstore/gc.go | 4 | ||||
-rw-r--r-- | swarm/storage/localstore/gc_test.go | 2 | ||||
-rw-r--r-- | swarm/storage/localstore/index_test.go | 2 | ||||
-rw-r--r-- | swarm/storage/localstore/localstore.go | 8 | ||||
-rw-r--r-- | swarm/storage/localstore/localstore_test.go | 10 | ||||
-rw-r--r-- | swarm/storage/localstore/mode_get.go | 6 | ||||
-rw-r--r-- | swarm/storage/localstore/mode_put.go | 4 | ||||
-rw-r--r-- | swarm/storage/localstore/mode_put_test.go | 6 | ||||
-rw-r--r-- | swarm/storage/localstore/mode_set.go | 2 | ||||
-rw-r--r-- | swarm/storage/localstore/retrieval_index_test.go | 10 | ||||
-rw-r--r-- | swarm/storage/localstore/subscription_pull.go | 6 | ||||
-rw-r--r-- | swarm/storage/localstore/subscription_pull_test.go | 2 | ||||
-rw-r--r-- | swarm/storage/localstore/subscription_push.go | 6 | ||||
-rw-r--r-- | swarm/storage/localstore/subscription_push_test.go | 2 |
14 files changed, 35 insertions, 35 deletions
diff --git a/swarm/storage/localstore/gc.go b/swarm/storage/localstore/gc.go index 7718d1e58..e53bdabd1 100644 --- a/swarm/storage/localstore/gc.go +++ b/swarm/storage/localstore/gc.go @@ -92,8 +92,8 @@ package localstore import ( "time" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/swarm/shed" + "github.com/dexon-foundation/dexon/log" + "github.com/dexon-foundation/dexon/swarm/shed" "github.com/syndtr/goleveldb/leveldb" ) diff --git a/swarm/storage/localstore/gc_test.go b/swarm/storage/localstore/gc_test.go index eb039a554..fa9f39ece 100644 --- a/swarm/storage/localstore/gc_test.go +++ b/swarm/storage/localstore/gc_test.go @@ -23,7 +23,7 @@ import ( "testing" "time" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" ) // TestDB_collectGarbageWorker tests garbage collection runs diff --git a/swarm/storage/localstore/index_test.go b/swarm/storage/localstore/index_test.go index d9abf440f..326b8d9f2 100644 --- a/swarm/storage/localstore/index_test.go +++ b/swarm/storage/localstore/index_test.go @@ -21,7 +21,7 @@ import ( "math/rand" "testing" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" ) // TestDB_pullIndex validates the ordering of keys in pull index. diff --git a/swarm/storage/localstore/localstore.go b/swarm/storage/localstore/localstore.go index 7a9fb54f5..c828deb12 100644 --- a/swarm/storage/localstore/localstore.go +++ b/swarm/storage/localstore/localstore.go @@ -23,10 +23,10 @@ import ( "sync" "time" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/swarm/shed" - "github.com/ethereum/go-ethereum/swarm/storage" - "github.com/ethereum/go-ethereum/swarm/storage/mock" + "github.com/dexon-foundation/dexon/log" + "github.com/dexon-foundation/dexon/swarm/shed" + "github.com/dexon-foundation/dexon/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage/mock" ) var ( diff --git a/swarm/storage/localstore/localstore_test.go b/swarm/storage/localstore/localstore_test.go index c7309d3cd..77340875b 100644 --- a/swarm/storage/localstore/localstore_test.go +++ b/swarm/storage/localstore/localstore_test.go @@ -28,9 +28,9 @@ import ( "testing" "time" - ch "github.com/ethereum/go-ethereum/swarm/chunk" - "github.com/ethereum/go-ethereum/swarm/shed" - "github.com/ethereum/go-ethereum/swarm/storage" + ch "github.com/dexon-foundation/dexon/swarm/chunk" + "github.com/dexon-foundation/dexon/swarm/shed" + "github.com/dexon-foundation/dexon/swarm/storage" "github.com/syndtr/goleveldb/leveldb" ) @@ -130,10 +130,10 @@ func TestDB_updateGCSem(t *testing.T) { // Measurements on MacBook Pro (Retina, 15-inch, Mid 2014) show // that New function executes around 1s for database with 1M chunks. // -// # go test -benchmem -run=none github.com/ethereum/go-ethereum/swarm/storage/localstore -bench BenchmarkNew -v -timeout 20m +// # go test -benchmem -run=none github.com/dexon-foundation/dexon/swarm/storage/localstore -bench BenchmarkNew -v -timeout 20m // goos: darwin // goarch: amd64 -// pkg: github.com/ethereum/go-ethereum/swarm/storage/localstore +// pkg: github.com/dexon-foundation/dexon/swarm/storage/localstore // BenchmarkNew/1000-8 200 11672414 ns/op 9570960 B/op 10008 allocs/op // BenchmarkNew/10000-8 100 14890609 ns/op 10490118 B/op 7759 allocs/op // BenchmarkNew/100000-8 20 58334080 ns/op 17763157 B/op 22978 allocs/op diff --git a/swarm/storage/localstore/mode_get.go b/swarm/storage/localstore/mode_get.go index 3a69f6e9d..16080f4f9 100644 --- a/swarm/storage/localstore/mode_get.go +++ b/swarm/storage/localstore/mode_get.go @@ -17,9 +17,9 @@ package localstore import ( - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/swarm/shed" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/log" + "github.com/dexon-foundation/dexon/swarm/shed" + "github.com/dexon-foundation/dexon/swarm/storage" "github.com/syndtr/goleveldb/leveldb" ) diff --git a/swarm/storage/localstore/mode_put.go b/swarm/storage/localstore/mode_put.go index 1a5a3d1b1..0052d6c96 100644 --- a/swarm/storage/localstore/mode_put.go +++ b/swarm/storage/localstore/mode_put.go @@ -17,8 +17,8 @@ package localstore import ( - "github.com/ethereum/go-ethereum/swarm/shed" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/shed" + "github.com/dexon-foundation/dexon/swarm/storage" "github.com/syndtr/goleveldb/leveldb" ) diff --git a/swarm/storage/localstore/mode_put_test.go b/swarm/storage/localstore/mode_put_test.go index ffe6a4cb4..ca034c03e 100644 --- a/swarm/storage/localstore/mode_put_test.go +++ b/swarm/storage/localstore/mode_put_test.go @@ -23,7 +23,7 @@ import ( "testing" "time" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" ) // TestModePutRequest validates ModePutRequest index values on the provided DB. @@ -208,11 +208,11 @@ func TestModePutUpload_parallel(t *testing.T) { // // Measurements on MacBook Pro (Retina, 15-inch, Mid 2014) // -// # go test -benchmem -run=none github.com/ethereum/go-ethereum/swarm/storage/localstore -bench BenchmarkPutUpload -v +// # go test -benchmem -run=none github.com/dexon-foundation/dexon/swarm/storage/localstore -bench BenchmarkPutUpload -v // // goos: darwin // goarch: amd64 -// pkg: github.com/ethereum/go-ethereum/swarm/storage/localstore +// pkg: github.com/dexon-foundation/dexon/swarm/storage/localstore // BenchmarkPutUpload/count_100_parallel_1-8 300 5107704 ns/op 2081461 B/op 2374 allocs/op // BenchmarkPutUpload/count_100_parallel_2-8 300 5411742 ns/op 2081608 B/op 2364 allocs/op // BenchmarkPutUpload/count_100_parallel_4-8 500 3704964 ns/op 2081696 B/op 2324 allocs/op diff --git a/swarm/storage/localstore/mode_set.go b/swarm/storage/localstore/mode_set.go index a522f4447..8043af88d 100644 --- a/swarm/storage/localstore/mode_set.go +++ b/swarm/storage/localstore/mode_set.go @@ -17,7 +17,7 @@ package localstore import ( - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" "github.com/syndtr/goleveldb/leveldb" ) diff --git a/swarm/storage/localstore/retrieval_index_test.go b/swarm/storage/localstore/retrieval_index_test.go index 9f5b452c5..bccdc6ed9 100644 --- a/swarm/storage/localstore/retrieval_index_test.go +++ b/swarm/storage/localstore/retrieval_index_test.go @@ -20,7 +20,7 @@ import ( "strconv" "testing" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" ) // BenchmarkRetrievalIndexes uploads a number of chunks in order to measure @@ -32,10 +32,10 @@ import ( // Measurements on MacBook Pro (Retina, 15-inch, Mid 2014) show // that two separated indexes perform better. // -// # go test -benchmem -run=none github.com/ethereum/go-ethereum/swarm/storage/localstore -bench BenchmarkRetrievalIndexes -v +// # go test -benchmem -run=none github.com/dexon-foundation/dexon/swarm/storage/localstore -bench BenchmarkRetrievalIndexes -v // goos: darwin // goarch: amd64 -// pkg: github.com/ethereum/go-ethereum/swarm/storage/localstore +// pkg: github.com/dexon-foundation/dexon/swarm/storage/localstore // BenchmarkRetrievalIndexes/1000-8 20 75556686 ns/op 19033493 B/op 84500 allocs/op // BenchmarkRetrievalIndexes/10000-8 1 1079084922 ns/op 382792064 B/op 1429644 allocs/op // BenchmarkRetrievalIndexes/100000-8 1 16891305737 ns/op 2629165304 B/op 12465019 allocs/op @@ -104,10 +104,10 @@ func benchmarkRetrievalIndexes(b *testing.B, o *Options, count int) { // // Measurements on MacBook Pro (Retina, 15-inch, Mid 2014). // -// go test -benchmem -run=none github.com/ethereum/go-ethereum/swarm/storage/localstore -bench BenchmarkUpload -v +// go test -benchmem -run=none github.com/dexon-foundation/dexon/swarm/storage/localstore -bench BenchmarkUpload -v // goos: darwin // goarch: amd64 -// pkg: github.com/ethereum/go-ethereum/swarm/storage/localstore +// pkg: github.com/dexon-foundation/dexon/swarm/storage/localstore // BenchmarkUpload/1000-8 20 59437463 ns/op 25205193 B/op 23208 allocs/op // BenchmarkUpload/10000-8 2 580646362 ns/op 216532932 B/op 248090 allocs/op // BenchmarkUpload/100000-8 1 22373390892 ns/op 2323055312 B/op 3995903 allocs/op diff --git a/swarm/storage/localstore/subscription_pull.go b/swarm/storage/localstore/subscription_pull.go index a18f0915d..7c686d31d 100644 --- a/swarm/storage/localstore/subscription_pull.go +++ b/swarm/storage/localstore/subscription_pull.go @@ -23,9 +23,9 @@ import ( "fmt" "sync" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/swarm/shed" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/log" + "github.com/dexon-foundation/dexon/swarm/shed" + "github.com/dexon-foundation/dexon/swarm/storage" ) // SubscribePull returns a channel that provides chunk addresses and stored times from pull syncing index. diff --git a/swarm/storage/localstore/subscription_pull_test.go b/swarm/storage/localstore/subscription_pull_test.go index 5c99e0dec..918ec4513 100644 --- a/swarm/storage/localstore/subscription_pull_test.go +++ b/swarm/storage/localstore/subscription_pull_test.go @@ -24,7 +24,7 @@ import ( "testing" "time" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" ) // TestDB_SubscribePull uploads some chunks before and after diff --git a/swarm/storage/localstore/subscription_push.go b/swarm/storage/localstore/subscription_push.go index b13f29399..4b554c38c 100644 --- a/swarm/storage/localstore/subscription_push.go +++ b/swarm/storage/localstore/subscription_push.go @@ -20,9 +20,9 @@ import ( "context" "sync" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/swarm/shed" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/log" + "github.com/dexon-foundation/dexon/swarm/shed" + "github.com/dexon-foundation/dexon/swarm/storage" ) // SubscribePush returns a channel that provides storage chunks with ordering from push syncing index. diff --git a/swarm/storage/localstore/subscription_push_test.go b/swarm/storage/localstore/subscription_push_test.go index 73e7c25f7..52f57f52e 100644 --- a/swarm/storage/localstore/subscription_push_test.go +++ b/swarm/storage/localstore/subscription_push_test.go @@ -24,7 +24,7 @@ import ( "testing" "time" - "github.com/ethereum/go-ethereum/swarm/storage" + "github.com/dexon-foundation/dexon/swarm/storage" ) // TestDB_SubscribePush uploads some chunks before and after |