release: Introduce database v2 module.

This commit is contained in:
Dave Collins 2019-07-22 02:20:07 -05:00
parent fd29a375d9
commit 9320e2ef89
No known key found for this signature in database
GPG Key ID: B8904D9D9C93D1F2
21 changed files with 39 additions and 39 deletions

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -11,7 +11,7 @@ import (
"time"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
)
// fetchBlockCmd defines the configuration options for the fetchblock command.

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -12,7 +12,7 @@ import (
"time"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
)
// blockRegionCmd defines the configuration options for the fetchblockregion

View File

@ -12,8 +12,8 @@ import (
"path/filepath"
"github.com/decred/dcrd/chaincfg/v2"
"github.com/decred/dcrd/database"
_ "github.com/decred/dcrd/database/ffldb"
"github.com/decred/dcrd/database/v2"
_ "github.com/decred/dcrd/database/v2/ffldb"
"github.com/decred/dcrd/dcrutil/v2"
)

View File

@ -14,7 +14,7 @@ import (
"time"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/dcrutil/v2"
"github.com/decred/dcrd/wire"
)

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -9,7 +9,7 @@ import (
"time"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
)
// headersCmd defines the configuration options for the loadheaders command.

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016-2018 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -11,7 +11,7 @@ import (
"runtime"
"strings"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/slog"
flags "github.com/jessevdk/go-flags"
)

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -9,8 +9,8 @@ import (
"fmt"
"testing"
"github.com/decred/dcrd/database"
_ "github.com/decred/dcrd/database/ffldb"
"github.com/decred/dcrd/database/v2"
_ "github.com/decred/dcrd/database/v2/ffldb"
)
var (

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -9,7 +9,7 @@ import (
"errors"
"testing"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
)
// TestErrorCodeStringer tests the stringized output for the ErrorCode type.

View File

@ -12,8 +12,8 @@ import (
"path/filepath"
"github.com/decred/dcrd/chaincfg/v2"
"github.com/decred/dcrd/database"
_ "github.com/decred/dcrd/database/ffldb"
"github.com/decred/dcrd/database/v2"
_ "github.com/decred/dcrd/database/v2/ffldb"
"github.com/decred/dcrd/dcrutil/v2"
"github.com/decred/dcrd/wire"
)
@ -50,7 +50,7 @@ func Example_basicUsage() {
//
// import (
// "github.com/decred/dcrd/database2"
// _ "github.com/decred/dcrd/database/ffldb"
// _ "github.com/decred/dcrd/database/v2/ffldb"
// )
// Create a database and schedule it to be closed and removed on exit.
@ -116,7 +116,7 @@ func Example_blockStorageAndRetrieval() {
//
// import (
// "github.com/decred/dcrd/database2"
// _ "github.com/decred/dcrd/database/ffldb"
// _ "github.com/decred/dcrd/database/v2/ffldb"
// )
// Create a database and schedule it to be closed and removed on exit.

View File

@ -11,7 +11,7 @@ import (
"testing"
"github.com/decred/dcrd/chaincfg/v2"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/dcrutil/v2"
)

View File

@ -19,7 +19,7 @@ import (
"sync"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/wire"
)

View File

@ -23,8 +23,8 @@ import (
"github.com/btcsuite/goleveldb/leveldb/opt"
"github.com/btcsuite/goleveldb/leveldb/util"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/internal/treap"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/database/v2/internal/treap"
"github.com/decred/dcrd/wire"
)

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -14,7 +14,7 @@ import (
"github.com/btcsuite/goleveldb/leveldb"
"github.com/btcsuite/goleveldb/leveldb/iterator"
"github.com/btcsuite/goleveldb/leveldb/util"
"github.com/decred/dcrd/database/internal/treap"
"github.com/decred/dcrd/database/v2/internal/treap"
)
const (

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016-2018 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -8,7 +8,7 @@ package ffldb
import (
"fmt"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/wire"
"github.com/decred/slog"
)

View File

@ -14,8 +14,8 @@ import (
"testing"
"github.com/decred/dcrd/chaincfg/v2"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/ffldb"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/database/v2/ffldb"
"github.com/decred/dcrd/dcrutil/v2"
)

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -12,7 +12,7 @@ The functions are only exported while the tests are being run.
package ffldb
import "github.com/decred/dcrd/database"
import "github.com/decred/dcrd/database/v2"
// TstRunWithMaxBlockFileSize runs the passed function with the maximum allowed
// file size for the database set to the provided value. The value will be set

View File

@ -26,7 +26,7 @@ import (
"time"
"github.com/decred/dcrd/chaincfg/chainhash"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/dcrutil/v2"
"github.com/decred/dcrd/wire"
)

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -8,7 +8,7 @@ package ffldb
import (
"github.com/btcsuite/goleveldb/leveldb/iterator"
"github.com/btcsuite/goleveldb/leveldb/util"
"github.com/decred/dcrd/database/internal/treap"
"github.com/decred/dcrd/database/v2/internal/treap"
)
// ldbTreapIter wraps a treap iterator to provide the additional functionality

View File

@ -1,5 +1,5 @@
// Copyright (c) 2015-2016 The btcsuite developers
// Copyright (c) 2016 The Decred developers
// Copyright (c) 2016-2019 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
@ -9,7 +9,7 @@ import (
"fmt"
"hash/crc32"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
)
// The serialized write cursor location format is:

View File

@ -21,7 +21,7 @@ import (
"github.com/btcsuite/goleveldb/leveldb"
ldberrors "github.com/btcsuite/goleveldb/leveldb/errors"
"github.com/decred/dcrd/database"
"github.com/decred/dcrd/database/v2"
"github.com/decred/dcrd/dcrutil/v2"
"github.com/decred/dcrd/wire"
)

View File

@ -1,4 +1,4 @@
module github.com/decred/dcrd/database
module github.com/decred/dcrd/database/v2
go 1.11