Skip to content

Commit 204f0f4

Browse files
author
Jason Yellick
committed
[FAB-5270] Remove filters from multichannel
The only consumer of the filters framework is now the msgprocessor package. This CR removes all of the filter references from multichannel, and moves the filter code from fabric/orderer/common to fabric/orderer/common/msgprocessor. Change-Id: I73a562887776086c62212167c71bd72c8894b286 Signed-off-by: Jason Yellick <jyellick@us.ibm.com>
1 parent 9018aea commit 204f0f4

20 files changed

+170
-126
lines changed

orderer/common/deliver/deliver.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ import (
2020
"io"
2121

2222
"github.com/hyperledger/fabric/common/policies"
23-
"github.com/hyperledger/fabric/orderer/common/filter"
2423
"github.com/hyperledger/fabric/orderer/common/ledger"
25-
"github.com/hyperledger/fabric/orderer/common/sigfilter"
24+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
25+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/sigfilter"
2626
cb "github.com/hyperledger/fabric/protos/common"
2727
ab "github.com/hyperledger/fabric/protos/orderer"
2828
"github.com/op/go-logging"

orderer/common/configtxfilter/filter.go renamed to orderer/common/msgprocessor/configtxfilter/filter.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ package configtxfilter
1919
import (
2020
"github.com/hyperledger/fabric/common/configtx"
2121
"github.com/hyperledger/fabric/common/configtx/api"
22-
"github.com/hyperledger/fabric/orderer/common/filter"
22+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
2323
cb "github.com/hyperledger/fabric/protos/common"
2424
"github.com/hyperledger/fabric/protos/utils"
2525
)

orderer/common/configtxfilter/filter_test.go renamed to orderer/common/msgprocessor/configtxfilter/filter_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121
"testing"
2222

2323
mockconfigtx "github.com/hyperledger/fabric/common/mocks/configtx"
24-
"github.com/hyperledger/fabric/orderer/common/filter"
24+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
2525
cb "github.com/hyperledger/fabric/protos/common"
2626
"github.com/hyperledger/fabric/protos/utils"
2727

orderer/common/msgprocessor/msgprocessor.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,12 @@ package msgprocessor
1111
import (
1212
"errors"
1313

14+
"github.com/hyperledger/fabric/common/flogging"
1415
cb "github.com/hyperledger/fabric/protos/common"
1516
)
1617

18+
var logger = flogging.MustGetLogger("common/msgprocessor")
19+
1720
const (
1821
// These should eventually be derived from the channel support once enabled
1922
msgVersion = int32(0)

orderer/common/sigfilter/sigfilter.go renamed to orderer/common/msgprocessor/sigfilter/sigfilter.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ package sigfilter
1818

1919
import (
2020
"github.com/hyperledger/fabric/common/policies"
21-
"github.com/hyperledger/fabric/orderer/common/filter"
21+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
2222
cb "github.com/hyperledger/fabric/protos/common"
2323

2424
"github.com/op/go-logging"

orderer/common/sigfilter/sigfilter_test.go renamed to orderer/common/msgprocessor/sigfilter/sigfilter_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121
"testing"
2222

2323
mockpolicies "github.com/hyperledger/fabric/common/mocks/policies"
24-
"github.com/hyperledger/fabric/orderer/common/filter"
24+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
2525
cb "github.com/hyperledger/fabric/protos/common"
2626
"github.com/hyperledger/fabric/protos/utils"
2727

orderer/common/sizefilter/sizefilter.go renamed to orderer/common/msgprocessor/sizefilter/sizefilter.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ limitations under the License.
1717
package sizefilter
1818

1919
import (
20-
"github.com/hyperledger/fabric/orderer/common/filter"
20+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
2121
cb "github.com/hyperledger/fabric/protos/common"
2222
ab "github.com/hyperledger/fabric/protos/orderer"
2323
logging "github.com/op/go-logging"

orderer/common/sizefilter/sizefilter_test.go renamed to orderer/common/msgprocessor/sizefilter/sizefilter_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121

2222
"github.com/golang/protobuf/proto"
2323
mockconfig "github.com/hyperledger/fabric/common/mocks/config"
24-
"github.com/hyperledger/fabric/orderer/common/filter"
24+
"github.com/hyperledger/fabric/orderer/common/msgprocessor/filter"
2525
cb "github.com/hyperledger/fabric/protos/common"
2626
ab "github.com/hyperledger/fabric/protos/orderer"
2727
)

0 commit comments

Comments
 (0)