-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: allow usage of tcp socket between agent and worker (#818)
# Motivation Java does not support grpc communication between the worker and the agent over unix sockets, this PR builds on the changes introduced in aneoconsulting/ArmoniK.Api#583 to enable the option to use a tcp socket instead. # Description Mimic the changes in aneoconsulting/ArmoniK.Api#583 and enlarged the kestrel configuration options in the `AgentHandler` such that it also accepts to listen on a tcp socket. In addition this PR separates the volumes used for shared data and unix socket. Before the PR both of them where mounted on `\cache`, the updated mount point for shared data is `\comm`. # Testing Terraform deployment and `just` file have been modified to take into account a new variable `socket_type`, that can be set to either `unixdomainsocket` or `tcp` so the deployment configures which socket type should be employed accordingly. With these changes the same set of tests that ran for unix sockets can be executed but using a tcp socket instead . # Impact The desired life cycle behavior in a deployment with the whole infrastructure is that the worker starts before the agent and stops after it. This is currently enforced by checking the absence/existence of the unix socket created by the agent. With the changes of this PR, in the case of choosing a tcp socket for the connection, the unix socket is not created. Hence, the infra should be adapted accordingly to guarantee the desired worker/agent life cycle. One option is to transform the worker container in Kubernetes POD into a sidecar container, but this will require the direct use of Helm charts since the Kubernetes provider we use for terraform does not support this yet. # Additional Information Not applicable # Checklist - [x] My code adheres to the coding and style guidelines of the project. - [x] I have performed a self-review of my code. - [ ] I have commented my code, particularly in hard-to-understand areas. - [ ] I have made corresponding changes to the documentation. - [x] I have thoroughly tested my modifications and added tests when necessary. - [x] Tests pass locally and in the CI. - [ ] I have assessed the performance impact of my modifications.
- Loading branch information
Showing
18 changed files
with
131 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters