#define LTTNG_TRACE_FORMAT_DESCRIPTOR_H
#include <inttypes.h>
+#include <lttng/domain.h>
+#include <lttng/lttng-error.h>
#include <lttng/lttng-export.h>
#ifdef __cplusplus
#endif
struct lttng_trace_format_descriptor;
+enum lttng_domain_type;
enum lttng_trace_format_descriptor_status {
LTTNG_TRACE_FORMAT_DESCRIPTOR_STATUS_INVALID = -1,
LTTNG_EXPORT void lttng_trace_format_descriptor_destroy(
struct lttng_trace_format_descriptor *descriptor);
+/*
+ * Check if the passed trace format is supported for the passed domain.
+ */
+LTTNG_EXPORT extern enum lttng_error_code lttng_domain_supports_trace_format(
+ const struct lttng_endpoint *session_daemon_endpoint,
+ enum lttng_domain_type domain_type,
+ const struct lttng_trace_format_descriptor *trace_format_descriptor);
+
+/*
+ * For network destinations targeting a relay daemon, the session daemon will
+ * establish a connection to check for the capability at the time of the call.
+ * Note that the relay daemon at the destination address may be replaced by
+ * the time tracing starts.
+ *
+ * When destination url is a network destination (relayd), the following
+ * URL format is expected:
+ * NETPROTO://(HOST | IPADDR)[:CTRLPORT[:DATAPORT]][/TRACEPATH]
+ *
+ * Always returns LTTNG_OK for local destinations.
+ */
+LTTNG_EXPORT extern enum lttng_error_code lttng_destination_supports_trace_format(
+ const struct lttng_endpoint *session_daemon_endpoint,
+ const char *destination_url,
+ const struct lttng_trace_format_descriptor *trace_format_descriptor);
#ifdef __cplusplus
}