← Back to team overview

openstack team mailing list archive

Re: When & how are glance-cache* (.conf, -paste.ini) files loaded / parsed ?

 

Eoghan,

Yes, it does make perfect sense. Kind thanks for the explanation.

However,  what is still unclear is what config iteems that pertain to other
apps must  still be present (ie. duplicated in) glance-api.conf  (e.g.
image_cache_driver , etc )

Thanks again,

Florian
 On Mar 14, 2012 10:45 AM, "Eoghan Glynn" <eglynn@xxxxxxxxxx> wrote:

>
> Florian,
>
> The key point in the split between glance-api.conf, glance-registry.conf,
> glance-cache.conf etc. is the glance application intended to consume that
> config.
>
> This follows directly from the naming:
>
>  bin/glance-api by default consumes glance-api.conf
>  bin/glance-registry by default consumes glance-registry.conf
>  bin/glance-cache-* by default consumes glance-cache.conf
>  bin/glance-scrubber by default consumes glance-scrubber.conf
>
> This is merely a convention, which can be overridden for example by
> naming the glance API service config as foobar.conf:
>
>  bin/glance-api --config-file /path/to/foobar.conf
>
> However the naming convention is convenient as it may allow the pathname
> of the config file to be inferred if not explicitly specified, for example
> for the glance-api application, the follow search order is used:
>
>      ~/.glance/glance-api.conf
>      ~/glance-api.conf
>      /etc/glance/glance-api.conf
>      /etc/glance-api.conf
>
> or, in general, replace glance-api above with the program name, i.e.
> basename(sys.argv[0])
>
> The intended consumer then determines what options should be specified in
> each config file, for example there would be no point in defining the
> the backend s3/swift store config in glance-cache.conf, similarly no
> need to define the max cache size in glance-api.conf, nor the scrubber
> wakeup time in glance-registry.conf.
>
> Then each .conf file has a corresponding -paste.ini, which splits along
> a different axis. Here the idea is to separate the core and paste deploy
> config for a particular glance application. So for example the default
> paste config for glance-api is glance-api-paste.ini, to be found in the
> same directory as glance-api.conf. Again this is merely a convenient
> convention that may be overridden.
>
> Does that all make sense?
>
> Cheers,
> Eoghan
>
> > Can someone help me understand what options need to be in
> > "glance-api.conf" and what options can be left to
> > "glance-cache.conf" , resp "glance-cache-paste.ini" ?
> >
> > Case in point: If I wanted to use the "xattr" driver, I need to
> > specify that in "glance-api.conf" -- specifying that in
> > "glance-cache.conf" is ignored. The trivial solution is to copy the
> > options from "glance-cache.conf" and paste them in "glance-api.conf"
> > but I hardly think this was the intention of having the two split.
> >
> > So I'd like to understand when & how those two files are loaded /
> > parsed.
> >
> > The questions above is for the image cache, but I guess the same type
> > of questions can be asked for the scrubber (i.e.
> > glance-scrubber.conf" resp "glance-scrubber-paste.ini")
> >
> > Least I forget: This is for the E4 code release.
> >
> > TIA for the help,
> >
> > Florian
> >
> >
> >
> > _______________________________________________
> > Mailing list: https://launchpad.net/~openstack
> > Post to     : openstack@xxxxxxxxxxxxxxxxxxx
> > Unsubscribe : https://launchpad.net/~openstack
> > More help   : https://help.launchpad.net/ListHelp
> >
>

Follow ups

References