Skip to content

Commit 0d864c6

Browse files
author
Jason Yellick
committed
[FAB-4424] Clarify configtx flag and error
The configtxgen tool has a flag "-asOrg" which takes an organization's name, and performs a config update as that org (useful for updating anchor peers only, today). Apparently this flag can be interpretted as requiring the organization's MSP ID, and not name. This CR adds a clarifying "(by name)" to the parameter help, and additionally changes the error message when the org name is not found, to refer to the organization name, and not simply the org. Change-Id: I7c3dfc215d7efbf731ce0fb2464b9bafbd0572cb Signed-off-by: Jason Yellick <[email protected]>
1 parent 52853f8 commit 0d864c6

File tree

1 file changed

+2
-2
lines changed
  • common/configtx/tool/configtxgen

1 file changed

+2
-2
lines changed

common/configtx/tool/configtxgen/main.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ func doOutputAnchorPeersUpdate(conf *genesisconfig.Profile, channelID string, ou
112112
}
113113

114114
if org == nil {
115-
return fmt.Errorf("No org matching: %s", asOrg)
115+
return fmt.Errorf("No organization name matching: %s", asOrg)
116116
}
117117

118118
anchorPeers := make([]*pb.AnchorPeer, len(org.AnchorPeers))
@@ -335,7 +335,7 @@ func main() {
335335
flag.StringVar(&inspectBlock, "inspectBlock", "", "Prints the configuration contained in the block at the specified path")
336336
flag.StringVar(&inspectChannelCreateTx, "inspectChannelCreateTx", "", "Prints the configuration contained in the transaction at the specified path")
337337
flag.StringVar(&outputAnchorPeersUpdate, "outputAnchorPeersUpdate", "", "Creates an config update to update an anchor peer (works only with the default channel creation, and only for the first update)")
338-
flag.StringVar(&asOrg, "asOrg", "", "Performs the config generation as a particular organization, only including values in the write set that org (likely) has privilege to set")
338+
flag.StringVar(&asOrg, "asOrg", "", "Performs the config generation as a particular organization (by name), only including values in the write set that org (likely) has privilege to set")
339339

340340
flag.Parse()
341341

0 commit comments

Comments
 (0)