All of lore.kernel.org
 help / color / mirror / Atom feed
* New configuration / command line handling
@ 2012-12-03  9:57 Roald van Loon
  2012-12-03 12:04 ` Roald van Loon
  2012-12-03 21:51 ` Josh Durgin
  0 siblings, 2 replies; 6+ messages in thread
From: Roald van Loon @ 2012-12-03  9:57 UTC (permalink / raw)
  To: ceph-devel

Hi list, ceph devs,

I've been doing some toying with Ceph lately in my spare time and one
of the things I'm doing is trying to refactor some of the
configuration handling / argument parsing. I had some trouble finding
specific runtime options and configuration settings, so I thought this
was a good way to get to know the code somewhat better :-) Because
boost was already used in some places, and some tests also used
boost::program_options, I've created a new config framework based on
this. This framework allows for more advanced configuration files in
the future, beter command line handling, and reduces the amount of
code in argument parsing somewhat. I also created a different observer
system, where different parts of the code base can subscribe to
changes in specific parameters and get notified on changes.

To allow somewhat of a smoother transition and backwards
compatibility, I've made the new configuration class inherit from the
one one (md_config_t) and switched all references (like g_conf) to the
new class. There were also some small changes in files with references
directly to md_config_t, like pidfile_write. Global_init and
common_init were duplicated such that it 'injects' the new
configuration class in the ceph_context object. Most config entries
are read directly from the md_config_t class (e.g. g_conf->pid_file),
so it will take some more changes to allow my configuration framework
to function properly.

Of course it's an extremely long long long way from ready, but maybe
you're interested. Maybe you think this is not needed at all... I'd
love to have some feedback on it either way.

Anyway, let me know if you want to check it out and I'll push my
branch to github for you to pull.


- Roald

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-12-13  1:15 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-03  9:57 New configuration / command line handling Roald van Loon
2012-12-03 12:04 ` Roald van Loon
2012-12-03 21:51 ` Josh Durgin
2012-12-03 22:46   ` Roald van Loon
2012-12-05  3:04     ` Josh Durgin
2012-12-13  1:15       ` Roald van Loon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.