[OpenStack-docs] Question about which keyword should use?(weigher/weighter)
Steve Gordon
sgordon at redhat.com
Tue Jul 21 19:53:57 UTC 2015
----- Original Message -----
> From: "Matt Kassawara" <mkassawara at gmail.com>
> To: "Atsushi SAKAI" <sakaia at jp.fujitsu.com>
>
> We should call these "weight" or "weights" to agree with every other
> technical thing that uses this concept.
Aren't these configuration values based on the literal strings actually used in the code? E.g. (note that weighter appears to be a typo introduced in the docs, scheduler_default_weighters doesn't exist anywhere as a configuration key in the source code:
sgordon at localhost:~/Source/cinder(master)> grep -r GoodnessWeighter *
sgordon at localhost:~/Source/cinder(master)> grep -r GoodnessWeigher *
cinder/tests/unit/scheduler/test_goodness_weigher.py:class GoodnessWeigherTestCase(test.TestCase):
cinder/tests/unit/scheduler/test_goodness_weigher.py: super(GoodnessWeigherTestCase, self).setUp()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/tests/unit/scheduler/test_goodness_weigher.py: weigher = goodness.GoodnessWeigher()
cinder/scheduler/weights/goodness.py:class GoodnessWeigher(weights.BaseHostWeigher):
setup.cfg: GoodnessWeigher = cinder.scheduler.weights.goodness:GoodnessWeigher
sgordon at localhost:~/Source/cinder(master)> grep -r "scheduler_default_weighters" * -r
sgordon at localhost:~/Source/cinder(master)> grep -r "scheduler_default_weighers" * -r
cinder/tests/unit/scheduler/test_scheduler.py: # scheduler_default_filters and scheduler_default_weighers when
cinder/tests/unit/scheduler/test_scheduler.py: scheduler_default_weighers=['CapacityWeigher'])
cinder/tests/unit/scheduler/test_scheduler.py: self.assertEqual(CONF.scheduler_default_weighers,
cinder/tests/unit/scheduler/test_scheduler.py: scheduler_default_weighers=['CapacityWeigher'])
cinder/tests/unit/scheduler/test_scheduler.py: self.assertEqual(CONF.scheduler_default_weighers,
cinder/scheduler/simple.py: scheduler_default_weighers = 'ChanceWeigher'
cinder/scheduler/simple.py: scheduler_default_weighers = 'AllocatedCapacityWeigher'
cinder/scheduler/host_manager.py: cfg.ListOpt('scheduler_default_weighers',
cinder/scheduler/host_manager.py: CONF.set_override('scheduler_default_weighers',
cinder/scheduler/host_manager.py: CONF.set_override('scheduler_default_weighers',
cinder/scheduler/host_manager.py: it uses CONF.scheduler_default_weighers instead.
cinder/scheduler/host_manager.py: weight_cls_names = CONF.scheduler_default_weighers
> On Tue, Jul 21, 2015 at 12:34 AM, Atsushi SAKAI <sakaia at jp.fujitsu.com>
> wrote:
>
> > Hello
> >
> > I am looking around following document and find same two keywords are used
> > on the document.
> > Which word (weigher/weighter) is correct for this case?
> >
> > for example
> > GoodnessWeigher
> > VolumeNumberWeigher scheduler_default_weighters
> >
> > OpenStack Cloud Administrator Guide
> > http://docs.openstack.org/draft/admin-guide-cloud-rst/
> >
> > Thanks
> > Atsushi SAKAI
> >
> >
> > _______________________________________________
> > OpenStack-docs mailing list
> > OpenStack-docs at lists.openstack.org
> > http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-docs
> >
>
> _______________________________________________
> OpenStack-docs mailing list
> OpenStack-docs at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-docs
>
--
Steve Gordon, RHCE
Sr. Technical Product Manager,
Red Hat Enterprise Linux OpenStack Platform
More information about the OpenStack-docs
mailing list