fablo icon indicating copy to clipboard operation
fablo copied to clipboard

When network is recovered from snapshots, CCaaS chaincode should start automatically

Open dzikowski opened this issue 2 months ago • 2 comments

Currently as our README says:

6. When running external chaincodes(CCAAS), Execute `./fablo chaincodes install` to start the CCAAS container

Probably it can be resolved by starting CCaaS containers in network start phase instead of chaincode installation, and possibly adding some retry policy on failures

dzikowski avatar Oct 17 '25 21:10 dzikowski

Chaincodes need the package Id in the start command to work; said package Id is only available after chaincode installation on the peer.

So even if we do start the chaincode at network start/include it in docker-compose, we'll still need to restart it after chaincode installation

dpereowei avatar Oct 24 '25 08:10 dpereowei

yeah, that's the current flow for up command:

networkUp() {
  generateArtifacts
  startNetwork             # == `start`
  generateChannelsArtifacts
  installChannels
  installChaincodes
  notifyOrgsAboutChannels
  printStartSuccessInfo
}

that means maybe we should add an additional step and build / package chaincodes before networkStart. This way package id is available on each start.

Also when you restore network from snapshot, the snapshot should include package id, so it can be easily restored.

dzikowski avatar Oct 24 '25 08:10 dzikowski