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

Implement funding and watching service over tcp+perun's protobuf encoding. #266

Open
wants to merge 14 commits into
base: develop
Choose a base branch
from

Conversation

manoranjith
Copy link

Description

Implement funding and watching service over tcp+perun's protobuf encoding.

Category

Implementation Task

Relevant issue

Testing

Steps to run the tests

Needs to be tested along with an embedded implementation, which will use this API.
This will be documented separately.

Checklist

  • Name is added to the NOTICE file, if it is not present already.
  • Changes are rebased onto the target branch.

Manoranjith added 11 commits December 14, 2023 14:13
- The filesToMove array was not populated. Hence, the directories were
  empty. To fix, populate this array properly.

- The idProvider.yml include only the own alias. To fix, modify the
  logic to include everything except own alias.

Signed-off-by: Manoranjith <[email protected]>
- Change build command to install. This installs the binaries in $GOBIN
  directory.

- Add generate command that generates the artefacts for demo.

Signed-off-by: Manoranjith <[email protected]>
Signed-off-by: Manoranjith <[email protected]>
- Previously, the nested map was not initialized. This caused a panic
  when Register was invoked.

- Initializing the map fixes this it.

Signed-off-by: Manoranjith <[email protected]>
- ETH asset is registered by default already during the initialization
  fo the funder.

Signed-off-by: manoranjith <[email protected]>
- The key can be used for initializing pre-funded accounts in
  ganache-cli or for initializing the same keys for tests in alternate
  clients (like rust implementation).

Signed-off-by: manoranjith <[email protected]>
- Add a flag to run command to specify the service to run.
- Split the serve function in gprc package.

Signed-off-by: Manoranjith <[email protected]>
- This is a temporary workaround to enable the existing version of
  perunnode-cli to connect with the API in fundwatch only mode to
  generate a session-id by opening a session.

- Once, the perunnode-cli is updated, this can be undone.

Signed-off-by: Manoranjith <[email protected]>
- The extracted handlers use in golang standard context, protobuf
  request/response messages.

- Hence, these can be shared between grpc and other upcoming
  implementations (like peruniotcp server).

Signed-off-by: Manoranjith <[email protected]>
- The extracted handlers use in golang standard context, protobuf
  request/response messages.

- Hence, these can be shared between grpc and other upcoming
  implementations (like peruniotcp server).

Signed-off-by: Manoranjith <[email protected]>
@manoranjith manoranjith force-pushed the perunio-api branch 2 times, most recently from 6899640 to 4946237 Compare December 14, 2023 16:04
manoranjith added 2 commits December 14, 2023 17:07
- Define a api_messages.proto as a enum of all the funding and watching
  services.

- This is needed, for parsing of the request, because unlike grpc, tcp
  adapter using perunio's custom messaging scheme does not have an
  in-built routing mechanism.

Signed-off-by: manoranjith <[email protected]>
- Also combine the commands for watching and funding service, because
  the api_messages.proto depends on both of these definitions.

Signed-off-by: manoranjith <[email protected]>
Copy link
Contributor

@danielksan81 danielksan81 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

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 this pull request may close these issues.

2 participants