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

Simplify service hash calculation and creation. #1372

Closed
NicolasMahe opened this issue Sep 27, 2019 · 0 comments · Fixed by #1375
Closed

Simplify service hash calculation and creation. #1372

NicolasMahe opened this issue Sep 27, 2019 · 0 comments · Fixed by #1375
Assignees

Comments

@NicolasMahe
Copy link
Member

  • The service create backend function need to do less stuff in order to take less time to run. This function will be run by the validators of the network and they have less than 10 sec to create a block that could contains thousands of service creation tx.
  • The service hash is currently calculated with the actual source files of the service. This requires to download from IPFS all the source, untar it, iterate of the files and finally create a hash for the source files.
    As the IPFS hash that reference the source files is already in the Service struct, and it is deterministic, we could simply use it to replace the manual source files hash calculation.
  • The service create backend function is also building the docker image for pre-optimization (as the image is already available locally, it is fast to start the associated instance). This need to be removed as well.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants