sessiond: introduce ltt_session::locked_ref look-up functions
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 24 May 2024 02:09:04 +0000 (02:09 +0000)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 27 Jun 2024 15:09:21 +0000 (11:09 -0400)
commitd9a970b7c05cf573d5d992615a5db3605e3219dd
tree3a94ae7bd0ee9eb11039f14394bfa9aa6eb74b63
parent9f4d1ef361e6f02cad87c78f5b1260bc9c3ebc08
sessiond: introduce ltt_session::locked_ref look-up functions

Introduce ltt_session::locked_ref look-up functions and use them at the various
sites performing session look-ups by id or name.

The users of those look-up functions are refactored to make them exception-safe.
The biggest change is that process_client_msg is now exception-safe. The
functions are also moved inside of the ltt_session class as static methods. This
namespaces them implicitly.

A number of functions that expect a locked ltt_session are modified to accept an
ltt_session::locked_ref, thus enforcing the locking assumptions of the session
at compile time.

Change-Id: If9e4f8b25d03fa8d36a5898dd421da947ec4030c
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
21 files changed:
src/bin/lttng-sessiond/Makefile.am
src/bin/lttng-sessiond/action-executor.cpp
src/bin/lttng-sessiond/agent-thread.cpp
src/bin/lttng-sessiond/client.cpp
src/bin/lttng-sessiond/cmd.cpp
src/bin/lttng-sessiond/cmd.hpp
src/bin/lttng-sessiond/ctl-utils.hpp [new file with mode: 0644]
src/bin/lttng-sessiond/dispatch.cpp
src/bin/lttng-sessiond/kernel-consumer.cpp
src/bin/lttng-sessiond/lttng-sessiond.hpp
src/bin/lttng-sessiond/main.cpp
src/bin/lttng-sessiond/manage-kernel.cpp
src/bin/lttng-sessiond/rotation-thread.cpp
src/bin/lttng-sessiond/save.cpp
src/bin/lttng-sessiond/session.cpp
src/bin/lttng-sessiond/session.hpp
src/bin/lttng-sessiond/ust-app.cpp
src/bin/lttng-sessiond/ust-registry-session.cpp
src/common/exception.cpp
src/common/exception.hpp
tests/unit/test_session.cpp
This page took 0.026654 seconds and 4 git commands to generate.