Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FAB-18276 Ch.Part.API: extractSystemChannel must skip empty ledger #2023

Merged
merged 1 commit into from
Oct 19, 2020
Merged

FAB-18276 Ch.Part.API: extractSystemChannel must skip empty ledger #2023

merged 1 commit into from
Oct 19, 2020

Conversation

tock-ibm
Copy link
Contributor

  • orderer/common/server/main.go extractSystemChannel() panics when
    it hits an empty ledger.

  • In addition this method is not covered with unit tests at all.

  • Remove some dead code.

Signed-off-by: Yoav Tock tock@il.ibm.com
Change-Id: Ie13156784d2ec600e3f97d34f20f6836b28f7662

Type of change

  • Bug fix

Related issues

Issue: FAB-18276
Epic: FAB-17712

- orderer/common/server/main.go extractSystemChannel() panics when
it hits an empty ledger.

- In addition this method is not covered with unit tests at all.

- Remove some dead code.

Signed-off-by: Yoav Tock <tock@il.ibm.com>
Change-Id: Ie13156784d2ec600e3f97d34f20f6836b28f7662
@tock-ibm tock-ibm requested a review from a team as a code owner October 19, 2020 14:26
@C0rWin C0rWin merged commit c6f07dd into hyperledger:master Oct 19, 2020
Param-S pushed a commit to Param-S/fabric that referenced this pull request Jun 7, 2021
…yperledger#2023)

- orderer/common/server/main.go extractSystemChannel() panics when
it hits an empty ledger.

- In addition this method is not covered with unit tests at all.

- Remove some dead code.

Signed-off-by: Yoav Tock <tock@il.ibm.com>
Change-Id: Ie13156784d2ec600e3f97d34f20f6836b28f7662
manish-sethi pushed a commit that referenced this pull request Jun 7, 2021
…2648)

* FAB-18276 Ch.Part.API: extractSystemChannel must skip empty ledger (#2023)

- orderer/common/server/main.go extractSystemChannel() panics when
it hits an empty ledger.

- In addition this method is not covered with unit tests at all.

- Remove some dead code.

Signed-off-by: Yoav Tock <tock@il.ibm.com>
Change-Id: Ie13156784d2ec600e3f97d34f20f6836b28f7662

* Added RetrieveBlockByNumber into blockledger (#2635)

GetBlock is used for retrieving a block in ConfigBlockOrPanic
which has overhead of Iterator. It is now simplified by exposing
a BlockStore function RetrieveBlockByNumber.

Signed-off-by: Parameswaran Selvam <parselva@in.ibm.com>

Co-authored-by: Yoav Tock <tock@il.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants