tangle
tangle copied to clipboard
[CHECKLIST] Jobs v2 Milestone 2
Overview
In the first milestone, we did merge #624 that includes the most basic working blocks for the new Services System design. In this milestone, we should address the following tasks/features:
pallet-services
This milestone goals are:
- Getting EVM fee resolved, from pallet-services (see #XYZ for more information)
- Make Lookups faster, by introducing auxiliary storages and runtime APIs (with RPCs)
- [x] #634
- [x] #635
- [x] #636
- [x] #637
- [x] #638
- [x] #644
- [x] #648
Gadgets
This milestone goals are:
- Convert dfns/cggmp21 gadget into blueprint (manual process)
- Convert FROST gadget into a blueprint (manually)
- Prepare Gadget shell to use on-chain data to pull blueprints and execute them (natively for now).
- [ ] [SPEC] Writing Native Tangle Service Blueprints (TSB)
- [ ] [SPEC] Testing Tangle Service Blueprints (TSB)
- [ ] [TASK] Publish dfns/cggmp21 as native Tangle Service Blueprint (TSB)
- [ ] [TASK] Publish FROST as native Tangle Service Blueprint (TSB)
- [ ] [TASK] Gadget Shell v2
Deliverables and timeline
TBD
My goal for this milestone is to
- Be able to write a blueprint and deploy it on chain (
gadget blueprint create,gadget blueprint deploy) - Create a service request for that blueprint and select the configuration onchain. (Polkadot Apps, execute the extrinsic)
- Have the participants involved execute that service. (run the service, submit results to the chain).
Gadget blueprint create (Finishing the protocol-template)
We have early beginnings of the protocol template, which compile the gadget into a binary and provide a hash in the CI. What we don't have is the full picture, but we can start building that out now. The full picture will require:
- (P0) Adding the smart contracts to this environment. This includes a boilerplate registration and request hook/contract. I believe this should be apart of the template.
- (P0 - P1) Test environment within the protocol-template structure. Can I test my blueprint w/ a mocked service instance?
- (P2) Integrating this into a CLI that we download with a single
wgetorcurlcmd.
Gadget blueprint deploy
- (P0 - P1) Can I deploy a blueprint through Polkadot Apps UI? Does it need a CLI?
- (P2) Integrate deploy command to this CLI.
- (P2) It likely will need to read in a private key and submit the extrinsic that deploys a blueprint.
Gadget integration
- (P0) Shell manager should find all blueprints
thisshell should watch for, using an ongoing event listener, and download the binaries. - (P0) Shell manager should listen for any new service instances/jobs from the watched blueprints, using an ongoing event listener, and execute the target binary.
- How does gadget submit extrinsics? Does it have access to the keystore?
- Possibly, the gadget binary sends the result to the shell manager who manages transaction submission.
- (P0) The gadget does still listens to its job dispatch system. This job dispatch system is a trait first and foremost, which we have a Substrate implementation for.
- (P0) The gadget has a trait for submitting the job result. This shouldn't apriori depend on any blockchain unless you want to submit to a chain.
impl JobSubmitter for TangleJobSubmitter. - Testing environment. Full test env includes EVM smart contracts, gadget, tx submission against Tangle.