diff --git a/configure.py b/configure.py index e2ee2bb883..f281223489 100755 --- a/configure.py +++ b/configure.py @@ -535,6 +535,7 @@ idls = ['idl/gossip_digest.idl.hh', 'idl/query.idl.hh', 'idl/idl_test.idl.hh', 'idl/commitlog.idl.hh', + 'idl/tracing.idl.hh', ] scylla_tests_dependencies = scylla_core + api + idls + [ diff --git a/idl/tracing.idl.hh b/idl/tracing.idl.hh new file mode 100644 index 0000000000..716c2e8661 --- /dev/null +++ b/idl/tracing.idl.hh @@ -0,0 +1,35 @@ +/* + * Copyright 2016 ScyllaDB + */ + +/* + * This file is part of Scylla. + * + * Scylla is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Scylla is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Scylla. If not, see . + */ + +namespace tracing { +enum class trace_type : uint8_t { + NONE, + QUERY, + REPAIR, +}; + +class trace_info { + utils::UUID session_id; + tracing::trace_type type; + bool flush_on_close; +}; +} + diff --git a/tracing/tracing.hh b/tracing/tracing.hh index 738c4a1a88..bad4740e4e 100644 --- a/tracing/tracing.hh +++ b/tracing/tracing.hh @@ -83,6 +83,20 @@ inline gc_clock::duration ttl_by_type(const trace_type t) { } } +class trace_info { +public: + utils::UUID session_id; + trace_type type; + bool flush_on_close; + +public: + trace_info(utils::UUID sid, trace_type t, bool f_o_c) + : session_id(std::move(sid)) + , type(t) + , flush_on_close(f_o_c) + { } +}; + struct i_tracing_backend_helper { virtual ~i_tracing_backend_helper() {} virtual future<> start() = 0;