feat: Include UDS path in connection properties.#5172
Conversation
Up to standards ✅🟢 Issues
|
| IP address used to connect to Fluent. | ||
| port : int | None | ||
| Port used to connect to Fluent. | ||
| uds_fullpath : str | Path | None |
There was a problem hiding this comment.
| uds_fullpath : str | Path | None | |
| uds_full_path : str | Path | None |
There was a problem hiding this comment.
@seanpearsonuk The naming followed the parameter name in the cyberchannel module documentation. The create_channel within cyberchannel is exposed to users and we also support passing the channel within the FluentConnection constructor while directly initializing the session classes (although this is not a mainstream usage pattern). Should we change the parameter name in PyFluent or be consistent with the cyberchannel module?
There was a problem hiding this comment.
@RobPasMue I think that the name of the parameter in cyberchannel could be updated. WDYT?
There was a problem hiding this comment.
Hi @seanpearsonuk! We can update the cyberchannel if needed - but the update would imply accepting both options in fact, at least for a while. We could then move to deprecating the old version.
Nonetheless - what's the main driver? I'm guessing readability but just in case =)
|
|
||
| ip: str | None = None | ||
| port: int | None = None | ||
| uds_fullpath: str | Path | None = None |
There was a problem hiding this comment.
| uds_fullpath: str | Path | None = None | |
| uds_full_path: str | Path | None = None |
| self._channel_str = None | ||
| self._slurm_job_id = None | ||
| self.finalizer_cbs = [] | ||
| self._uds_fullpath = None |
There was a problem hiding this comment.
| self._uds_fullpath = None | |
| self._uds_full_path = None |
| self._channel_str = address | ||
| uds_fullpath = get_uds_path(address) | ||
| if uds_fullpath is None: | ||
| self._uds_fullpath = get_uds_path(address) |
There was a problem hiding this comment.
| self._uds_fullpath = get_uds_path(address) | |
| self._uds_full_path = get_uds_path(address) |
| uds_fullpath = get_uds_path(address) | ||
| if uds_fullpath is None: | ||
| self._uds_fullpath = get_uds_path(address) | ||
| if self._uds_fullpath is None: |
There was a problem hiding this comment.
| if self._uds_fullpath is None: | |
| if self._uds_full_path is None: |
| ip=ip, | ||
| port=port, | ||
| uds_fullpath=uds_fullpath, | ||
| uds_fullpath=self._uds_fullpath, |
There was a problem hiding this comment.
| uds_fullpath=self._uds_fullpath, | |
| uds_full_path=self._uds_full_path, |
| inside_container, | ||
| ip=ip, | ||
| port=port, | ||
| uds_fullpath=self._uds_fullpath, |
There was a problem hiding this comment.
| uds_fullpath=self._uds_fullpath, | |
| uds_full_path=self._uds_full_path, |
Context
For local-connection on Linux, ip+port is replaced by UDS path which should be available within session's connection properties.
Change Summary
Include the UDS full-path in session's connection properties.
Rationale
The connection properties are useful to connect another client session to the same server and the UDS path is required to connect locally in Linux.
Impact
The UDS path info will be available within session's connection properties.