Introduce "--blocking-timeout" channel parameter
[lttng-tools.git] / src / common / mi-lttng.c
index 197add2d470518bf0e18f4f2ecc16320d8a88265..9c1597b363f67a7ed230443160f81a434f6dea35 100644 (file)
@@ -863,6 +863,7 @@ int mi_lttng_channel_attr(struct mi_writer *writer,
        struct lttng_channel *chan = caa_container_of(attr,
                        struct lttng_channel, attr);
        uint64_t discarded_events, lost_packets, monitor_timer_interval;
+       int64_t blocking_timeout;
 
        assert(attr);
 
@@ -882,6 +883,12 @@ int mi_lttng_channel_attr(struct mi_writer *writer,
                goto end;
        }
 
+       ret = lttng_channel_get_blocking_timeout(chan,
+                       &blocking_timeout);
+       if (ret) {
+               goto end;
+       }
+
        /* Opening Attributes */
        ret = mi_lttng_writer_open_element(writer, config_element_attributes);
        if (ret) {
@@ -936,6 +943,14 @@ int mi_lttng_channel_attr(struct mi_writer *writer,
                goto end;
        }
 
+       /* Retry timeout in usec */
+       ret = mi_lttng_writer_write_element_signed_int(writer,
+               config_element_blocking_timeout,
+               blocking_timeout);
+       if (ret) {
+               goto end;
+       }
+
        /* Event output */
        ret = mi_lttng_writer_write_element_string(writer,
                config_element_output_type,
This page took 0.025208 seconds and 5 git commands to generate.