Skip to content

Comments

mon: include cleanup#61608

Merged
MaxKellermann merged 14 commits intoceph:mainfrom
MaxKellermann:mon_includes
Feb 15, 2025
Merged

mon: include cleanup#61608
MaxKellermann merged 14 commits intoceph:mainfrom
MaxKellermann:mon_includes

Conversation

@MaxKellermann
Copy link
Member

Another PR split from #60490; this time the "mon" subsystem.

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows
  • jenkins test rook e2e

@MaxKellermann MaxKellermann requested a review from a team as a code owner January 31, 2025 12:26
@github-actions github-actions bot added cephfs Ceph File System core mon labels Jan 31, 2025
@batrick
Copy link
Member

batrick commented Feb 5, 2025

jenkins test make check

@batrick
Copy link
Member

batrick commented Feb 5, 2025

jenkins test make check arm64

@batrick
Copy link
Member

batrick commented Feb 5, 2025

jenkins test windows

@batrick
Copy link
Member

batrick commented Feb 5, 2025

jenkins test api

@MaxKellermann
Copy link
Member Author

This PR is broken because it depends on include corrections in other subsystems. I'll need to split other commits from the big draft PR first.

@MaxKellermann
Copy link
Member Author

I have rebased this PR on #61607 plus two more bug fix patches. With these, I can build Ceph locally; let's see if the CI is happy.

@MaxKellermann MaxKellermann mentioned this pull request Feb 6, 2025
14 tasks
@MaxKellermann
Copy link
Member Author

The two CI failures (SIGBUS, SIGSEGV) look unrelated to these compile-time changes.

Copy link
Contributor

@idryomov idryomov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it intended that commits touching the RBD CLI tool, rbd-mirror daemon and rbd-nbd driver ended up in the PR for the "mon" subsystem?

@idryomov idryomov mentioned this pull request Feb 7, 2025
14 tasks
@MaxKellermann
Copy link
Member Author

Is it intended that commits touching the RBD CLI tool, rbd-mirror daemon and rbd-nbd driver ended up in the PR for the "mon" subsystem?

Not quite, but my first attempt at this PR caused build failures in these other subsystem because includes there were missing. So I added more commits to check what the minimum set of fixes is needed to fix this PR. (Ceph is a fragile mess!)

@MaxKellermann
Copy link
Member Author

btw. @idryomov check my comment here: #61607 (comment)

@idryomov
Copy link
Contributor

idryomov commented Feb 7, 2025

caused build failures in these other subsystem because includes there were missing ... (Ceph is a fragile mess!)

(You may have elaborated on this in one of the other PRs that clean up includes, if so feel free to just post a link.)

I'm curious how you are building Ceph that you are hitting these build issues so reliably? Between the full-time developers and Jenkins, either various subsets or the entire project gets built well over a hundred times a day and all those builds pass (at least to the best of my knowledge). Are you doing it with no concurrency to fit into a small RAM budget or some kind of piece-wise builds juggling individual make/ninja targets?

@idryomov
Copy link
Contributor

idryomov commented Feb 7, 2025

btw. @idryomov check my comment here: #61607 (comment)

Is this in relation to RBD? That comment seems orthogonal to the thread here.

@MaxKellermann
Copy link
Member Author

Is this in relation to RBD? That comment seems orthogonal to the thread here.

Not RBD, but MGR. The MGR commits in this PR are "borrowed" from the other PR, and the comment I linked to explains that this PR depends on the other PR or else Ceph fails to build.

I'm curious how you are building Ceph that you are hitting these build issues so reliably?

Most of the build failures happen when I remove unnecessary includes from headers, but then dozes of other sources fail to compile because they depend on a certain header without including it. Prior to my work, that just happened to work by chance, not by design, due to the many (unnecessary) indirect includes. So a good piece of my work is to add all the include directives that are missing.

But there were also many Ceph build failures without any of my include cleanups. I tried to build just MDS (because MDS is all I'm interested in right now), so I disabled all the features that are not relevant for MDS (e.g. Bluestore) to speed up the build (Ceph build times are very painful). Just look at all my Bluestore-related PRs, e.g. #61019 #60547 #60305 #61020
These never occurred to all of you because apparently nobody (except me) has ever built Ceph without Bluestore support.

@MaxKellermann MaxKellermann mentioned this pull request Feb 7, 2025
14 tasks
@idryomov
Copy link
Contributor

idryomov commented Feb 7, 2025

I tried to build just MDS (because MDS is all I'm interested in right now), so I disabled all the features that are not relevant for MDS (e.g. Bluestore) to speed up the build (Ceph build times are very painful). Just look at all my Bluestore-related PRs, e.g. #61019 #60547 #60305 #61020
These never occurred to all of you because apparently nobody (except me) has ever built Ceph without Bluestore support.

Right -- building Ceph without Bluestore is weird because once you build your changes you generally want to test them end-to-end and if it's not a trivial test where a RAM-backed object store can do, Bluestore is very much needed ;) People absolutely (re)build just the MDS all the time, but only after having built "the world" once.

@MaxKellermann
Copy link
Member Author

People absolutely (re)build just the MDS all the time, but only after having built "the world" once.

I don't want do build the world, only MDS. I have a draft patch that allows enabling/disabling all of those top-level components, and if you enable only MDS, then cmake will only look for the dependencies needed by MDS. I might some day finish it and submit it.
Right now, I can build just MDS, but I still need all the dependencies for all other compoenents, and that annoys me.

@idryomov
Copy link
Contributor

@MaxKellermann I merged #61607, this PR can be rebased.

@idryomov
Copy link
Contributor

jenkins test api

@MaxKellermann
Copy link
Member Author

What's with these qatzip errors?

./qatzip_internal.h:445:25: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
void streamBufferCleanup();
                        ^
                         void
1 error generated.
make[1]: *** [Makefile:528: libqatzip_la-qatzip_counter.lo] Error 1
make[1]: *** Waiting for unfinished jobs....
In file included from qatzip.c:67:
./qatzip_internal.h:445:25: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
void streamBufferCleanup();
                        ^
                         void
In file included from qatzip_gzip.c:51:
./qatzip_internal.h:445:25: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
void streamBufferCleanup();
                        ^
                         void
1 error generated.
make[1]: *** [Makefile:535: libqatzip_la-qatzip_gzip.lo] Error 1
qatzip.c:1680:18: error: variable 'sleep_cnt' set but not used [-Werror,-Wunused-but-set-variable]
    unsigned int sleep_cnt = 0;
                 ^
qatzip.c:2565:18: error: variable 'sleep_cnt' set but not used [-Werror,-Wunused-but-set-variable]
    unsigned int sleep_cnt = 0;
                 ^

qatzip is a submodule, but how can this PR affect mistakes in the submodule?

@idryomov
Copy link
Contributor

qatzip is a submodule, but how can this PR affect mistakes in the submodule?

It's not caused by this PR, this is affecting other outstanding PRs as well.

@MaxKellermann MaxKellermann mentioned this pull request Feb 13, 2025
14 tasks
@idryomov
Copy link
Contributor

jenkins test make check

@idryomov
Copy link
Contributor

jenkins test api

@idryomov
Copy link
Contributor

jenkins test make check

@idryomov
Copy link
Contributor

jenkins test api

1 similar comment
@idryomov
Copy link
Contributor

jenkins test api

@idryomov
Copy link
Contributor

jenkins test make check

@tchaikov
Copy link
Contributor

the build failure should be fixed by #61827

@idryomov
Copy link
Contributor

idryomov commented Feb 14, 2025

The offending Jenkins builder is getting reimaged.

@idryomov
Copy link
Contributor

jenkins test make check

@MaxKellermann MaxKellermann merged commit 1fffa31 into ceph:main Feb 15, 2025
12 checks passed
@MaxKellermann MaxKellermann deleted the mon_includes branch February 15, 2025 04:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants