Skip to content

Commit 67847ee

Browse files
Merge pull request ceph#61791 from MaxKellermann/common_includes
common: add missing includes Reviewed-By: Adam Emerson <[email protected]>
2 parents 0ce5cdc + 81cac39 commit 67847ee

17 files changed

+65
-19
lines changed

src/common/Finisher.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#define CEPH_FINISHER_H
1717

1818
#include "include/Context.h"
19-
#include "include/common_fwd.h"
2019
#include "common/Thread.h"
2120
#include "common/ceph_mutex.h"
2221
#include "common/Cond.h"

src/common/Formatter.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
#ifndef CEPH_FORMATTER_H
44
#define CEPH_FORMATTER_H
55

6-
#include "include/int_types.h"
76
#include "include/buffer_fwd.h"
87

98
#include <deque>

src/common/PriorityCache.cc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@
1515
#include "PriorityCache.h"
1616
#include "common/dout.h"
1717
#include "perfglue/heap_profiler.h"
18+
19+
#if defined(WITH_SEASTAR) && !defined(WITH_ALIEN)
20+
#include "crimson/common/perf_counters_collection.h"
21+
#else
22+
#include "common/perf_counters_collection.h"
23+
#endif
24+
1825
#define dout_context cct
1926
#define dout_subsys ceph_subsys_prioritycache
2027
#undef dout_prefix

src/common/SloppyCRCMap.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
#ifndef CEPH_COMMON_SLOPPYCRCMAP_H
55
#define CEPH_COMMON_SLOPPYCRCMAP_H
66

7+
#include <map>
8+
79
#include "include/encoding.h"
810

911
namespace ceph {

src/common/TrackedOp.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,15 @@
1616

1717
#include <atomic>
1818
#include "common/StackStringStream.h"
19+
#include "common/ceph_context.h"
1920
#include "common/ceph_mutex.h"
21+
#include "common/debug.h"
22+
#include "common/Formatter.h"
2023
#include "common/histogram.h"
2124
#include "common/perf_counters.h" // for class PerfCountersBuilder
2225
#include "common/Thread.h"
2326
#include "common/Clock.h"
27+
#include "common/zipkin_trace.h"
2428
#include "include/spinlock.h"
2529
#include "msg/Message.h"
2630

@@ -30,6 +34,14 @@
3034
#include "common/perf_counters_collection.h"
3135
#endif
3236

37+
#include <boost/intrusive/list.hpp>
38+
#include <boost/intrusive_ptr.hpp>
39+
40+
#include <atomic>
41+
#include <list>
42+
#include <set>
43+
#include <vector>
44+
3345
#define OPTRACKER_PREALLOC_EVENTS 20
3446

3547
class TrackedOp;

src/common/ceph_time.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,6 @@
2020
#include <string>
2121
#include <optional>
2222
#include <fmt/chrono.h>
23-
#if FMT_VERSION >= 90000
24-
#include <fmt/ostream.h>
25-
#endif
2623
#include <sys/time.h>
2724

2825
#if defined(__APPLE__)

src/common/cmdparse.cc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,18 @@
1313
*/
1414

1515
#include "include/common_fwd.h"
16+
#include "common/BackTrace.h"
1617
#include "common/cmdparse.h"
1718
#include "common/Formatter.h"
1819
#include "common/debug.h"
1920
#include "common/strtol.h"
21+
#include "include/ceph_assert.h" // boost clobbers this
22+
#include "include/types.h" // for operator<<(std::vector)
2023
#include "json_spirit/json_spirit.h"
2124

25+
#include <ostream>
26+
#include <sstream>
27+
2228
using std::is_same_v;
2329
using std::ostringstream;
2430
using std::string;

src/common/cmdparse.h

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@
44
#define CEPH_COMMON_CMDPARSE_H
55

66
#include <vector>
7-
#include <stdexcept>
7+
#include <exception>
8+
#include <map>
9+
#include <string>
810
#include <optional>
9-
#include <ostream>
11+
#include <iosfwd>
1012
#include <boost/variant.hpp>
11-
#include "include/ceph_assert.h" // boost clobbers this
1213
#include "include/common_fwd.h"
13-
#include "common/Formatter.h"
14-
#include "common/BackTrace.h"
14+
15+
namespace ceph { class Formatter; }
1516

1617
typedef boost::variant<std::string,
1718
bool,

src/common/convenience.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,7 @@
1212
*
1313
*/
1414

15-
#include <mutex>
16-
#include <memory>
1715
#include <optional>
18-
#include <shared_mutex>
1916
#include <type_traits>
2017
#include <utility>
2118

src/common/fair_mutex.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@
44

55
#include "common/ceph_mutex.h"
66

7-
#include <thread>
7+
#ifdef CEPH_DEBUG_MUTEX
8+
#include <thread> // for std::this_thread::get_id()
9+
#endif
10+
811
#include <string>
912

1013
namespace ceph {

0 commit comments

Comments
 (0)