fabric-sdk-go: github.com/hyperledger/fabric-sdk-go/internal/github.com/hyperledger/fabric/common/capabilities Index | Files

package capabilities

import "github.com/hyperledger/fabric-sdk-go/internal/github.com/hyperledger/fabric/common/capabilities"

Index

Package Files

application.go capabilities.go channel.go orderer.go

Constants

const (

    // ApplicationV1_1 is the capabilties string for standard new non-backwards compatible fabric v1.1 application capabilities.
    ApplicationV1_1 = "V1_1"

    // ApplicationV1_2 is the capabilties string for standard new non-backwards compatible fabric v1.2 application capabilities.
    ApplicationV1_2 = "V1_2"

    // ApplicationV1_3 is the capabilties string for standard new non-backwards compatible fabric v1.3 application capabilities.
    ApplicationV1_3 = "V1_3"

    // ApplicationV1_4_2 is the capabilties string for standard new non-backwards compatible fabric v1.4.2 application capabilities.
    ApplicationV1_4_2 = "V1_4_2"

    // ApplicationV2_0 is the capabilties string for standard new non-backwards compatible fabric v2.0 application capabilities.
    ApplicationV2_0 = "V2_0"

    // ApplicationPvtDataExperimental is the capabilties string for private data using the experimental feature of collections/sideDB.
    ApplicationPvtDataExperimental = "V1_1_PVTDATA_EXPERIMENTAL"

    // ApplicationResourcesTreeExperimental is the capabilties string for private data using the experimental feature of collections/sideDB.
    ApplicationResourcesTreeExperimental = "V1_1_RESOURCETREE_EXPERIMENTAL"
)
const (

    // ChannelV1_1 is the capabilities string for standard new non-backwards compatible fabric v1.1 channel capabilities.
    ChannelV1_1 = "V1_1"

    // ChannelV1_3 is the capabilities string for standard new non-backwards compatible fabric v1.3 channel capabilities.
    ChannelV1_3 = "V1_3"

    // ChannelV1_4_2 is the capabilities string for standard new non-backwards compatible fabric v1.4.2 channel capabilities.
    ChannelV1_4_2 = "V1_4_2"

    // ChannelV2_0 is the capabilities string for standard new non-backwards compatible fabric v2.0 channel capabilities.
    ChannelV2_0 = "V2_0"
)
const (

    // OrdererV1_1 is the capabilities string for standard new non-backwards compatible Fabric v1.1 orderer capabilities.
    OrdererV1_1 = "V1_1"

    // OrdererV1_4_2 is the capabilities string for standard new non-backwards compatible Fabric v1.4.2 orderer capabilities.
    OrdererV1_4_2 = "V1_4_2"

    // OrdererV2_0 is the capabilities string that defines new Fabric v2.0 orderer capabilities.
    OrdererV2_0 = "V2_0"
)

type ApplicationProvider Uses

type ApplicationProvider struct {
    // contains filtered or unexported fields
}

ApplicationProvider provides capabilities information for application level config.

func NewApplicationProvider Uses

func NewApplicationProvider(capabilities map[string]*cb.Capability) *ApplicationProvider

NewApplicationProvider creates a application capabilities provider.

func (*ApplicationProvider) ACLs Uses

func (ap *ApplicationProvider) ACLs() bool

ACLs returns whether ACLs may be specified in the channel application config

func (ApplicationProvider) CollectionUpgrade Uses

func (ap ApplicationProvider) CollectionUpgrade() bool

CollectionUpgrade returns true if this channel is configured to allow updates to existing collection or add new collections through chaincode upgrade (as introduced in v1.2)

func (*ApplicationProvider) ForbidDuplicateTXIdInBlock Uses

func (ap *ApplicationProvider) ForbidDuplicateTXIdInBlock() bool

ForbidDuplicateTXIdInBlock specifies whether two transactions with the same TXId are permitted in the same block or whether we mark the second one as TxValidationCode_DUPLICATE_TXID

func (*ApplicationProvider) HasCapability Uses

func (ap *ApplicationProvider) HasCapability(capability string) bool

HasCapability returns true if the capability is supported by this binary.

func (*ApplicationProvider) KeyLevelEndorsement Uses

func (ap *ApplicationProvider) KeyLevelEndorsement() bool

KeyLevelEndorsement returns true if this channel supports endorsement policies expressible at a ledger key granularity, as described in FAB-8812

func (*ApplicationProvider) LifecycleV20 Uses

func (ap *ApplicationProvider) LifecycleV20() bool

LifecycleV20 indicates whether the peer should use the deprecated and problematic v1.x lifecycle, or whether it should use the newer per channel approve/commit definitions process introduced in v2.0. Note, this should only be used on the endorsing side of peer processing, so that we may safely remove all checks against it in v2.1.

func (*ApplicationProvider) MetadataLifecycle Uses

func (ap *ApplicationProvider) MetadataLifecycle() bool

MetadataLifecycle always returns false

func (*ApplicationProvider) PrivateChannelData Uses

func (ap *ApplicationProvider) PrivateChannelData() bool

PrivateChannelData returns true if support for private channel data (a.k.a. collections) is enabled. In v1.1, the private channel data is experimental and has to be enabled explicitly. In v1.2, the private channel data is enabled by default.

func (*ApplicationProvider) StorePvtDataOfInvalidTx Uses

func (ap *ApplicationProvider) StorePvtDataOfInvalidTx() bool

StorePvtDataOfInvalidTx returns true if the peer needs to store the pvtData of invalid transactions.

func (ApplicationProvider) Supported Uses

func (r ApplicationProvider) Supported() error

Supported checks that all of the required capabilities are supported by this binary.

func (*ApplicationProvider) Type Uses

func (ap *ApplicationProvider) Type() string

Type returns a descriptive string for logging purposes.

func (*ApplicationProvider) V1_1Validation Uses

func (ap *ApplicationProvider) V1_1Validation() bool

V1_1Validation returns true is this channel is configured to perform stricter validation of transactions (as introduced in v1.1).

func (*ApplicationProvider) V1_2Validation Uses

func (ap *ApplicationProvider) V1_2Validation() bool

V1_2Validation returns true if this channel is configured to perform stricter validation of transactions (as introduced in v1.2).

func (*ApplicationProvider) V1_3Validation Uses

func (ap *ApplicationProvider) V1_3Validation() bool

V1_3Validation returns true if this channel is configured to perform stricter validation of transactions (as introduced in v1.3).

func (*ApplicationProvider) V2_0Validation Uses

func (ap *ApplicationProvider) V2_0Validation() bool

V2_0Validation returns true if this channel supports transaction validation as introduced in v2.0. This includes:

- new chaincode lifecycle
- implicit per-org collections

type ChannelProvider Uses

type ChannelProvider struct {
    // contains filtered or unexported fields
}

ChannelProvider provides capabilities information for channel level config.

func NewChannelProvider Uses

func NewChannelProvider(capabilities map[string]*cb.Capability) *ChannelProvider

NewChannelProvider creates a channel capabilities provider.

func (*ChannelProvider) ConsensusTypeMigration Uses

func (cp *ChannelProvider) ConsensusTypeMigration() bool

ConsensusTypeMigration return true if consensus-type migration is supported and permitted in both orderer and peer.

func (*ChannelProvider) HasCapability Uses

func (cp *ChannelProvider) HasCapability(capability string) bool

HasCapability returns true if the capability is supported by this binary.

func (*ChannelProvider) MSPVersion Uses

func (cp *ChannelProvider) MSPVersion() msp.MSPVersion

MSPVersion returns the level of MSP support required by this channel.

func (*ChannelProvider) OrgSpecificOrdererEndpoints Uses

func (cp *ChannelProvider) OrgSpecificOrdererEndpoints() bool

OrgSpecificOrdererEndpoints allows for individual orderer orgs to specify their external addresses for their OSNs.

func (ChannelProvider) Supported Uses

func (r ChannelProvider) Supported() error

Supported checks that all of the required capabilities are supported by this binary.

func (*ChannelProvider) Type Uses

func (cp *ChannelProvider) Type() string

Type returns a descriptive string for logging purposes.

type OrdererProvider Uses

type OrdererProvider struct {
    V20 bool
    // contains filtered or unexported fields
}

OrdererProvider provides capabilities information for orderer level config.

func NewOrdererProvider Uses

func NewOrdererProvider(capabilities map[string]*cb.Capability) *OrdererProvider

NewOrdererProvider creates an orderer capabilities provider.

func (*OrdererProvider) ConsensusTypeMigration Uses

func (cp *OrdererProvider) ConsensusTypeMigration() bool

ConsensusTypeMigration checks whether the orderer permits a consensus-type migration.

A Kafka-based Ordering Service Node requires these capabilities in order to receive and process a config update with consensus-type migration change. Migration is supported from Kafka to Raft only. If not present, these config updates will be rejected.

func (*OrdererProvider) ExpirationCheck Uses

func (cp *OrdererProvider) ExpirationCheck() bool

ExpirationCheck specifies whether the orderer checks for identity expiration checks when validating messages

func (*OrdererProvider) HasCapability Uses

func (cp *OrdererProvider) HasCapability(capability string) bool

HasCapability returns true if the capability is supported by this binary.

func (*OrdererProvider) PredictableChannelTemplate Uses

func (cp *OrdererProvider) PredictableChannelTemplate() bool

PredictableChannelTemplate specifies whether the v1.0 undesirable behavior of setting the /Channel group's mod_policy to "" and copying versions from the channel config should be fixed or not.

func (*OrdererProvider) Resubmission Uses

func (cp *OrdererProvider) Resubmission() bool

Resubmission specifies whether the v1.0 non-deterministic commitment of tx should be fixed by re-submitting the re-validated tx.

func (OrdererProvider) Supported Uses

func (r OrdererProvider) Supported() error

Supported checks that all of the required capabilities are supported by this binary.

func (*OrdererProvider) Type Uses

func (cp *OrdererProvider) Type() string

Type returns a descriptive string for logging purposes.

func (*OrdererProvider) UseChannelCreationPolicyAsAdmins Uses

func (cp *OrdererProvider) UseChannelCreationPolicyAsAdmins() bool

UseChannelCreationPolicyAsAdmins determines whether the orderer should use the name "Admins" instead of "ChannelCreationPolicy" in the new channel config template.

Package capabilities imports 4 packages (graph) and is imported by 1 packages. Updated 2019-09-02. Refresh now. Tools for package owners.