Did I find the right examples for you? yes no

All Samples(15)  |  Call(15)  |  Derive(0)  |  Import(0)

src/n/o/nova-HEAD/nova/compute/manager.py   nova(Download)
    def _notify_about_instance_usage(self, context, instance, event_suffix,
                                     network_info=None, system_metadata=None,
                                     extra_usage_info=None, fault=None):
        compute_utils.notify_about_instance_usage(
            self.notifier, context, instance, event_suffix,

src/n/o/nova-gce-HEAD/nova/compute/manager.py   nova-gce(Download)
        # `__init__`.
        compute_utils.notify_about_instance_usage(
                context, instance, event_suffix, network_info=network_info,
                system_metadata=system_metadata,
                extra_usage_info=extra_usage_info, host=self.host)

src/n/o/nova-HEAD/nova/compute/api.py   nova(Download)
                try:
                    compute_utils.notify_about_instance_usage(
                            self.notifier, context, instance,
                            "%s.start" % delete_type)
                    instance.destroy()
                    compute_utils.notify_about_instance_usage(
                            self.notifier, context, instance,
        instance.info_cache.delete()
        compute_utils.notify_about_instance_usage(
            self.notifier, context, instance, "%s.start" % delete_type)
 
        elevated = context.elevated()
        instance.destroy()
        compute_utils.notify_about_instance_usage(
            self.notifier, context, instance, "%s.end" % delete_type,
            system_metadata=sys_meta)
 

src/n/o/nova-HEAD/nova/tests/conductor/test_conductor.py   nova(Download)
            'bw_usage')
        notifier = self.conductor_manager.notifier
        compute_utils.notify_about_instance_usage(notifier,
                                                  self.context, instance,
                                                  'exists',

src/n/o/nova-HEAD/nova/tests/compute/test_compute_utils.py   nova(Download)
        extra_usage_info = {'image_name': 'fake_name'}
        compute_utils.notify_about_instance_usage(
            rpc.get_notifier('compute'),
            self.context, instance, 'create.start',
            extra_usage_info=extra_usage_info)

src/n/o/nova-HEAD/nova/tests/compute/test_compute_api.py   nova(Download)
    def _test_downed_host_part(self, inst, updates, delete_time, delete_type):
        inst.info_cache.delete()
        compute_utils.notify_about_instance_usage(
                self.compute_api.notifier, self.context, inst,
                '%s.start' % delete_type)
                            constraint=None).AndReturn(fake_inst)
        compute_utils.notify_about_instance_usage(
                self.compute_api.notifier,
                self.context, inst, '%s.end' % delete_type,
                system_metadata=inst.system_metadata)
        else:
            compute_utils.notify_about_instance_usage(
                    self.compute_api.notifier, self.context,
                    inst, 'delete.start')
            db.constraint(host=mox.IgnoreArg()).AndReturn('constraint')
                                constraint='constraint').AndReturn(fake_inst)
            compute_utils.notify_about_instance_usage(
                    self.compute_api.notifier, self.context,
                    inst, 'delete.end',
                    system_metadata=inst.system_metadata)
        inst.info_cache.delete()
        compute_utils.notify_about_instance_usage(
                    self.compute_api.notifier, self.context,
                    inst, 'delete.start')
        self.context.elevated().MultipleTimes().AndReturn(self.context)

src/n/o/nova-gce-HEAD/nova/tests/compute/test_compute_utils.py   nova-gce(Download)
        db.instance_system_metadata_update(self.context, instance['uuid'],
                sys_metadata, False)
        compute_utils.notify_about_instance_usage(self.context, instance,
        'create.start', extra_usage_info=extra_usage_info)
        self.assertEquals(len(test_notifier.NOTIFICATIONS), 1)