For some use cases it is required to track the last time a contaxy service was accessed (e.g. automatically stop a service has not been used for a certain time).
This PR adds the properties last_access_time and last_access_user to the Service object that track when the service was last accessed and by which user. These values can be updated via a new endpoint /projects/{project_id}/services/{service_id}:update-service-access. Additionally, they are automatically updated if a new session token for a service is requested. As the session tokens are short-lived, this will cause a regular update of the last access time if the service is actively used.
This pull request introduces 1 alert when merging e5e1073e282b0bcecbc0742ec2e55756b69fc551 into c2dfc79024055a60712697434dfd27da92585935 - view on LGTM.com
For some use cases it is required to track the last time a contaxy service was accessed (e.g. automatically stop a service has not been used for a certain time). This PR adds the properties last_access_time and last_access_user to the Service object that track when the service was last accessed and by which user. These values can be updated via a new endpoint
/projects/{project_id}/services/{service_id}:update-service-access
. Additionally, they are automatically updated if a new session token for a service is requested. As the session tokens are short-lived, this will cause a regular update of the last access time if the service is actively used.