connect_grpc_channel#
- ansys.sherlock.core.launcher.connect_grpc_channel(port: int = 9090, server_version: int | None = None)#
Create a gRPC connection to a specified port and return the
Sherlock
connection object.The
Sherlock
connection object is used to invoke the APIs from their respective services. This can be used to connect to the Sherlock instance that is already running with the specified port.- Parameters:
port (int, optional) – Port number for the connection. Default is
SHERLOCK_DEFAULT_PORT
.server_version (int, optional) – Version of Sherlock. Default is the newest version that is installed.
- Returns:
The instance of sherlock.
- Return type:
Sherlock