Proto commits in labgrid-project/labgrid

These 15 commits are when the Protocol Buffers files have changed:

Commit:d399a58
Author:Bastian Krause
Committer:Bastian Krause

remote: add SetPlaceRemotePlaceConfig Add an RPC to set a place's remote place config. The request carries the place's last change time, so a config changed by someone else in the meantime is not silently overwritten. Signed-off-by: Bastian Krause <bst@pengutronix.de>

Commit:3fba681
Author:Bastian Krause
Committer:Bastian Krause

remote: add Place remote_place_config Add an optional remote place config attribute which will basically hold an environment config on target level (without features) YAML string. It is stored and distributed by the coordinator. Parsing happens on client side in get_remote_place_config() and it's shown in 'labgrid-client show'. Setting it in the coordinator follows in a later commit. Signed-off-by: Bastian Krause <bst@pengutronix.de>

Commit:6499b47
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add ListReservations RPC and deprecate GetReservations Add a unary ListReservations RPC that returns reservations. Mark the legacy GetReservations RPC and messages as deprecated, update the client reservation listing path, and add coverage for listing. Log a runtime deprecation warning from GetReservations and keep client compatibility with older coordinators: fall back only when ListReservations returns UNIMPLEMENTED, and preserve other RPC errors. Copy reservations without waiting for the mutation lock. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:5b596a6
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add ListPlaces RPC and deprecate GetPlaces Add a unary ListPlaces RPC that returns places. Mark the legacy GetPlaces RPC and messages as deprecated, and add coverage for listing. Log a runtime deprecation warning from GetPlaces. Copy places without waiting for the mutation lock. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:bec610a
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add ListPlaceResources RPC Add a unary ListPlaceResources RPC that returns the exporter resources matching a requested place. Cover matched resources, empty matches, and missing-place errors using exporter fixture data where the resource name differs from its class. Copy the current resource state without taking the coordinator mutation lock. The successful read does not yield, so it can return while an acquire or release is awaiting an exporter. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:cb04581
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add ListResources RPC Add a unary ListResources RPC that returns exporter resources. Include coverage for listing all resources while waiting for exporter fixture resources to register. Copy the current resource state without waiting for the coordinator mutation lock. The successful read does not yield. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:cca4412
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add RefreshReservation RPC Add a unary RefreshReservation RPC that refreshes and returns reservation state while keeping PollReservation available as a deprecated compatibility alias. Update labgrid-client reservation waiting to use RefreshReservation and cover both new and deprecated reservation refresh paths. Fall back to PollReservation only when RefreshReservation is unimplemented, mapping the reservation ID to the legacy token field. Warn when PollReservation is called and preserve other RPC errors. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:c47eaa0
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add SharePlace RPC Add a unary SharePlace RPC that grants another user access to an acquired place while keeping AllowPlace available as a deprecated compatibility alias. Update labgrid-client to prefer the share command, retain allow as a command alias, and cover successful sharing plus not-acquired errors. Fall back to AllowPlace only when SharePlace is unimplemented, preserving the requested place and user. Warn when AllowPlace is called and preserve other RPC errors. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:1c0636f
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add UnsharePlace RPC Add a unary UnsharePlace RPC that lets the acquiring user remove a previously allowed user from a place without updating the full place state. Expose the RPC through labgrid-client and cover the success, not-acquired, and not-shared error paths. Report clearly when an older coordinator does not support unshare, without changing ownership or access as a workaround. Preserve other RPC errors. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:b1256c5
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add CreatePlace RPC Add a unary CreatePlace RPC that creates and returns the new place while keeping AddPlace available as a deprecated compatibility alias. Update labgrid-client create to use CreatePlace and cover successful creation plus duplicate-place errors. Fall back to AddPlace only when CreatePlace is unimplemented, and warn when the deprecated AddPlace RPC is used. Add a shared client fallback helper. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:c67cc84
Author:Asher Pemberton
Committer:Asher Pemberton

remote/coordinator: add GetPlace RPC Add a unary GetPlace RPC for fetching a single place by name instead of requiring callers to fetch and scan the full GetPlaces response. Return INVALID_ARGUMENT when no name is provided or when the requested place does not exist. Return an independent response snapshot without waiting for the mutation lock. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com>

Commit:af11bd4
Author:Asher Pemberton
Committer:Asher Pemberton

remote: wrap exporter client identity in a message Replace the identity string at field 4 of ExporterSetAcquiredRequest with ClientIdentity.id, allowing more identity fields to be added in future. Update coordinator and exporter accesses and regenerate the Python bindings, preserving the existing identity values and log messages. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com> Co-authored-by: Idan Saadon <idan.saadon@arm.com>

Commit:811b802
Author:Asher Pemberton
Committer:Asher Pemberton

remote: propagate client identity to exporters Add acquirer_identity to ExporterSetAcquiredRequest and regenerate its Python bindings so exporters can identify the client behind resource acquisition and release commands. Send the place owner's identity on acquisition. For releases, use the request's metadata identity or fall back to the legacy client session. This records the releasing caller even when kicking another user's place. Log the identity after successful acquisition or release. Keep identity optional for callers without metadata or a client session, and for internal cleanup. Send an empty identity in those cases so existing release clients continue to work. The added protobuf field is compatible with older coordinators and exporters. Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper Co-authored-by: Luke Beardsmore <luke.beardsmore2@arm.com> Co-authored-by: Idan Saadon <idan.saadon@arm.com>

Commit:63950cf
Author:Asher Pemberton
Committer:Rouven Czerwinski

remote/coordinator: detach place RPCs from ClientStream Allow AcquirePlace, AllowPlace and CreateReservation to identify the caller from gRPC metadata instead of requiring identity to come only from an established ClientStream session. ClientStream should remain the ordered place/resource update channel. Unary-only callers should not need to establish and synchronize that stream merely to provide identity. This reduces startup and state management overhead for short-lived tools and services. Keep the existing ClientStream session lookup as a fallback so older clients which still send startup messages on the stream continue to work. Co-developed-by: Luke Beardsmore <luke.beardsmore2@arm.com> Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> #gatekeeper Signed-off-by: Luke Beardsmore <luke.beardsmore2@arm.com> [rouven.czerwinski@linaro.org: squashed in decorator] Signed-off-by: Rouven Czerwinski <rouven.czerwinski@linaro.org>

Commit:2099ee2
Author:Jan Luebbe
Committer:Bastian Krause

treewide: replace autobahn and crossbar with gRPC Crossbar and autobahn are used to communicate between client and coordinator as well as between exporter and coordinator. Both are unfortunately not very well maintained anymore. The crossbar component was moved to its own virtualenv for quite a while to cope with conflicting dependencies. python3.13 support for crossbar is still not available (at least not in a version releases on PyPi). That's why labgrid will now move to gRPC. It's a well maintained RPC framework. As a side effect, the message transfer is more performant and the import times are shorter. gRPC relies on the protocol buffers compiler (protoc) to generate code. Use grpcio-tools 1.62.2 to do that. It's used in Yocto scarthgap and is incompatible with generated code from newer grpcio-tools. Co-developed-by: Rouven Czerwinski <r.czerwinski@pengutronix.de> Co-developed-by: Bastian Krause <bst@pengutronix.de> Signed-off-by: Jan Luebbe <jlu@pengutronix.de>

The documentation is generated from this commit.