[FAB-10176] Fix invalid configtx.yaml documents

Change-Id: Ibf52f9380ed3b724c594b53550321a12475e9860
Signed-off-by: Matthew Sykes <sykesmat@us.ibm.com>
This commit is contained in:
Matthew Sykes 2018-05-17 08:41:05 -04:00
parent c3979b5716
commit e2f4f20bd6
3 changed files with 202 additions and 201 deletions

View file

@ -6,31 +6,48 @@
--- ---
################################################################################ ################################################################################
# #
# Profile # SECTION: Orderer
# #
# - Different configuration profiles may be encoded here to be specified # - This section defines the values to encode into a config transaction or
# as parameters to the configtxgen tool # genesis block for orderer related parameters
# #
################################################################################ ################################################################################
Profiles: Orderer: &OrdererDefaults
TwoOrgsOrdererGenesis: # Orderer Type: The orderer implementation to start
Orderer: # Available types are "solo" and "kafka"
<<: *OrdererDefaults OrdererType: solo
Organizations:
- *OrdererOrg Addresses:
Consortiums: - orderer.example.com:7050
SampleConsortium:
Organizations: # Batch Timeout: The amount of time to wait before creating a batch
- *Org1 BatchTimeout: 2s
- *Org2
TwoOrgsChannel: # Batch Size: Controls the number of messages batched into a block
Consortium: SampleConsortium BatchSize:
Application:
<<: *ApplicationDefaults # Max Message Count: The maximum number of messages to permit in a batch
Organizations: MaxMessageCount: 10
- *Org1
- *Org2 # Absolute Max Bytes: The absolute maximum number of bytes allowed for
# the serialized messages in a batch.
AbsoluteMaxBytes: 98 MB
# Preferred Max Bytes: The preferred maximum number of bytes allowed for
# the serialized messages in a batch. A message larger than the preferred
# max bytes will result in a batch larger than preferred max bytes.
PreferredMaxBytes: 512 KB
Kafka:
# Brokers: A list of Kafka brokers to which the orderer connects
# NOTE: Use IP:port notation
Brokers:
- 127.0.0.1:9092
# Organizations is the list of orgs which are defined as participants on
# the orderer side of the network
Organizations:
################################################################################ ################################################################################
# #
@ -89,51 +106,6 @@ Organizations:
- Host: peer0.org2.example.com - Host: peer0.org2.example.com
Port: 7051 Port: 7051
################################################################################
#
# SECTION: Orderer
#
# - This section defines the values to encode into a config transaction or
# genesis block for orderer related parameters
#
################################################################################
Orderer: &OrdererDefaults
# Orderer Type: The orderer implementation to start
# Available types are "solo" and "kafka"
OrdererType: solo
Addresses:
- orderer.example.com:7050
# Batch Timeout: The amount of time to wait before creating a batch
BatchTimeout: 2s
# Batch Size: Controls the number of messages batched into a block
BatchSize:
# Max Message Count: The maximum number of messages to permit in a batch
MaxMessageCount: 10
# Absolute Max Bytes: The absolute maximum number of bytes allowed for
# the serialized messages in a batch.
AbsoluteMaxBytes: 98 MB
# Preferred Max Bytes: The preferred maximum number of bytes allowed for
# the serialized messages in a batch. A message larger than the preferred
# max bytes will result in a batch larger than preferred max bytes.
PreferredMaxBytes: 512 KB
Kafka:
# Brokers: A list of Kafka brokers to which the orderer connects
# NOTE: Use IP:port notation
Brokers:
- 127.0.0.1:9092
# Organizations is the list of orgs which are defined as participants on
# the orderer side of the network
Organizations:
################################################################################ ################################################################################
# #
# SECTION: Application # SECTION: Application
@ -147,3 +119,31 @@ Application: &ApplicationDefaults
# Organizations is the list of orgs which are defined as participants on # Organizations is the list of orgs which are defined as participants on
# the application side of the network # the application side of the network
Organizations: Organizations:
################################################################################
#
# Profile
#
# - Different configuration profiles may be encoded here to be specified
# as parameters to the configtxgen tool
#
################################################################################
Profiles:
TwoOrgsOrdererGenesis:
Orderer:
<<: *OrdererDefaults
Organizations:
- *OrdererOrg
Consortiums:
SampleConsortium:
Organizations:
- *Org1
- *Org2
TwoOrgsChannel:
Consortium: SampleConsortium
Application:
<<: *ApplicationDefaults
Organizations:
- *Org1
- *Org2

View file

@ -4,72 +4,6 @@
# #
--- ---
################################################################################
#
# Profile
#
# - Different configuration profiles may be encoded here to be specified
# as parameters to the configtxgen tool
#
################################################################################
Profiles:
OneOrgOrdererGenesis:
Orderer:
<<: *OrdererDefaults
Organizations:
- *OrdererOrg
Consortiums:
SampleConsortium:
Organizations:
- *Org1
OneOrgChannel:
Consortium: SampleConsortium
Application:
<<: *ApplicationDefaults
Organizations:
- *Org1
################################################################################
#
# Section: Organizations
#
# - This section defines the different organizational identities which will
# be referenced later in the configuration.
#
################################################################################
Organizations:
# SampleOrg defines an MSP using the sampleconfig. It should never be used
# in production but may be used as a template for other definitions
- &OrdererOrg
# DefaultOrg defines the organization which is used in the sampleconfig
# of the fabric.git development environment
Name: OrdererOrg
# ID to load the MSP definition as
ID: OrdererMSP
# MSPDir is the filesystem path which contains the MSP configuration
MSPDir: crypto-config/ordererOrganizations/example.com/msp
- &Org1
# DefaultOrg defines the organization which is used in the sampleconfig
# of the fabric.git development environment
Name: Org1MSP
# ID to load the MSP definition as
ID: Org1MSP
MSPDir: crypto-config/peerOrganizations/org1.example.com/msp
AnchorPeers:
# AnchorPeers defines the location of peers which can be used
# for cross org gossip communication. Note, this value is only
# encoded in the genesis block in the Application section context
- Host: peer0.org1.example.com
Port: 7051
################################################################################ ################################################################################
# #
# SECTION: Orderer # SECTION: Orderer
@ -115,6 +49,46 @@ Orderer: &OrdererDefaults
# the orderer side of the network # the orderer side of the network
Organizations: Organizations:
################################################################################
#
# Section: Organizations
#
# - This section defines the different organizational identities which will
# be referenced later in the configuration.
#
################################################################################
Organizations:
# SampleOrg defines an MSP using the sampleconfig. It should never be used
# in production but may be used as a template for other definitions
- &OrdererOrg
# DefaultOrg defines the organization which is used in the sampleconfig
# of the fabric.git development environment
Name: OrdererOrg
# ID to load the MSP definition as
ID: OrdererMSP
# MSPDir is the filesystem path which contains the MSP configuration
MSPDir: crypto-config/ordererOrganizations/example.com/msp
- &Org1
# DefaultOrg defines the organization which is used in the sampleconfig
# of the fabric.git development environment
Name: Org1MSP
# ID to load the MSP definition as
ID: Org1MSP
MSPDir: crypto-config/peerOrganizations/org1.example.com/msp
AnchorPeers:
# AnchorPeers defines the location of peers which can be used
# for cross org gossip communication. Note, this value is only
# encoded in the genesis block in the Application section context
- Host: peer0.org1.example.com
Port: 7051
################################################################################ ################################################################################
# #
# SECTION: Application # SECTION: Application
@ -128,3 +102,30 @@ Application: &ApplicationDefaults
# Organizations is the list of orgs which are defined as participants on # Organizations is the list of orgs which are defined as participants on
# the application side of the network # the application side of the network
Organizations: Organizations:
################################################################################
#
# Profile
#
# - Different configuration profiles may be encoded here to be specified
# as parameters to the configtxgen tool
#
################################################################################
Profiles:
OneOrgOrdererGenesis:
Orderer:
<<: *OrdererDefaults
Organizations:
- *OrdererOrg
Consortiums:
SampleConsortium:
Organizations:
- *Org1
OneOrgChannel:
Consortium: SampleConsortium
Application:
<<: *ApplicationDefaults
Organizations:
- *Org1

View file

@ -6,37 +6,52 @@
--- ---
################################################################################ ################################################################################
# #
# Profile # SECTION: Capabilities
# #
# - Different configuration profiles may be encoded here to be specified # - This section defines the capabilities of fabric network. This is a new
# as parameters to the configtxgen tool # concept as of v1.1.0 and should not be utilized in mixed networks with
# v1.0.x peers and orderers. Capabilities define features which must be
# present in a fabric binary for that binary to safely participate in the
# fabric network. For instance, if a new MSP type is added, newer binaries
# might recognize and validate the signatures from this type, while older
# binaries without this support would be unable to validate those
# transactions. This could lead to different versions of the fabric binaries
# having different world states. Instead, defining a capability for a channel
# informs those binaries without this capability that they must cease
# processing transactions until they have been upgraded. For v1.0.x if any
# capabilities are defined (including a map with all capabilities turned off)
# then the v1.0.x peer will deliberately crash.
# #
################################################################################ ################################################################################
Profiles: Capabilities:
# Channel capabilities apply to both the orderers and the peers and must be
# supported by both. Set the value of the capability to true to require it.
Global: &ChannelCapabilities
# V1.1 for Global is a catchall flag for behavior which has been
# determined to be desired for all orderers and peers running v1.0.x,
# but the modification of which would cause incompatibilities. Users
# should leave this flag set to true.
V1_1: true
TwoOrgsOrdererGenesis: # Orderer capabilities apply only to the orderers, and may be safely
Capabilities: # manipulated without concern for upgrading peers. Set the value of the
<<: *ChannelCapabilities # capability to true to require it.
Orderer: Orderer: &OrdererCapabilities
<<: *OrdererDefaults # V1.1 for Order is a catchall flag for behavior which has been
Organizations: # determined to be desired for all orderers running v1.0.x, but the
- *OrdererOrg # modification of which would cause incompatibilities. Users should
Capabilities: # leave this flag set to true.
<<: *OrdererCapabilities V1_1: true
Consortiums:
SampleConsortium: # Application capabilities apply only to the peer network, and may be safely
Organizations: # manipulated without concern for upgrading orderers. Set the value of the
- *Org1 # capability to true to require it.
- *Org2 Application: &ApplicationCapabilities
TwoOrgsChannel: # V1.1 for Application is a catchall flag for behavior which has been
Consortium: SampleConsortium # determined to be desired for all peers running v1.0.x, but the
Application: # modification of which would cause incompatibilities. Users should
<<: *ApplicationDefaults # leave this flag set to true.
Organizations: V1_1: true
- *Org1
- *Org2
Capabilities:
<<: *ApplicationCapabilities
################################################################################ ################################################################################
# #
@ -156,49 +171,34 @@ Application: &ApplicationDefaults
################################################################################ ################################################################################
# #
# SECTION: Capabilities # Profile
# #
# - This section defines the capabilities of fabric network. This is a new # - Different configuration profiles may be encoded here to be specified
# concept as of v1.1.0 and should not be utilized in mixed networks with # as parameters to the configtxgen tool
# v1.0.x peers and orderers. Capabilities define features which must be
# present in a fabric binary for that binary to safely participate in the
# fabric network. For instance, if a new MSP type is added, newer binaries
# might recognize and validate the signatures from this type, while older
# binaries without this support would be unable to validate those
# transactions. This could lead to different versions of the fabric binaries
# having different world states. Instead, defining a capability for a channel
# informs those binaries without this capability that they must cease
# processing transactions until they have been upgraded. For v1.0.x if any
# capabilities are defined (including a map with all capabilities turned off)
# then the v1.0.x peer will deliberately crash.
# #
################################################################################ ################################################################################
Capabilities: Profiles:
# Channel capabilities apply to both the orderers and the peers and must be
# supported by both. Set the value of the capability to true to require it.
Global: &ChannelCapabilities
# V1.1 for Global is a catchall flag for behavior which has been
# determined to be desired for all orderers and peers running v1.0.x,
# but the modification of which would cause incompatibilities. Users
# should leave this flag set to true.
V1_1: true
# Orderer capabilities apply only to the orderers, and may be safely TwoOrgsOrdererGenesis:
# manipulated without concern for upgrading peers. Set the value of the Capabilities:
# capability to true to require it. <<: *ChannelCapabilities
Orderer: &OrdererCapabilities Orderer:
# V1.1 for Order is a catchall flag for behavior which has been <<: *OrdererDefaults
# determined to be desired for all orderers running v1.0.x, but the Organizations:
# modification of which would cause incompatibilities. Users should - *OrdererOrg
# leave this flag set to true. Capabilities:
V1_1: true <<: *OrdererCapabilities
Consortiums:
# Application capabilities apply only to the peer network, and may be safely SampleConsortium:
# manipulated without concern for upgrading orderers. Set the value of the Organizations:
# capability to true to require it. - *Org1
Application: &ApplicationCapabilities - *Org2
# V1.1 for Application is a catchall flag for behavior which has been TwoOrgsChannel:
# determined to be desired for all peers running v1.0.x, but the Consortium: SampleConsortium
# modification of which would cause incompatibilities. Users should Application:
# leave this flag set to true. <<: *ApplicationDefaults
V1_1: true Organizations:
- *Org1
- *Org2
Capabilities:
<<: *ApplicationCapabilities