Move logging to use oslo_log library

The oslo-incubator log modlule has been removed, so port to the oslo_log
library.  Note this uses the new (non namespaced, e.g oslo.log) import
convention, we'll need to align other imports in a future commit.

Some import reordering was required due to pedantic H30[57] checks, and
the services have all been converted to initialize the oslo_log library
as this is done differently to the log.py in incubator.

Change-Id: Ib5a97123fe1b287bc531e42d7887c13ba6205628
This commit is contained in:
Steven Hardy 2015-02-13 17:15:07 +00:00
parent 521c2f6a39
commit 70112c103a
80 changed files with 114 additions and 92 deletions

View File

@ -32,6 +32,7 @@ if os.path.exists(os.path.join(possible_topdir, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
from oslo_log import log as logging
import six
from heat.common import config
@ -39,7 +40,6 @@ from heat.common.i18n import _LI
from heat.common import messaging
from heat.common import profiler
from heat.common import wsgi
from heat.openstack.common import log as logging
from heat.openstack.common import systemd
i18n.enable_lazy()
@ -48,8 +48,10 @@ LOG = logging.getLogger('heat.api')
if __name__ == '__main__':
try:
logging.register_options(cfg.CONF)
cfg.CONF(project='heat', prog='heat-api')
logging.setup('heat')
logging.setup(cfg.CONF, 'heat-api')
logging.set_defaults()
messaging.setup()
app = config.load_paste_app()

View File

@ -34,6 +34,7 @@ if os.path.exists(os.path.join(possible_topdir, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
from oslo_log import log as logging
import six
from heat.common import config
@ -41,7 +42,6 @@ from heat.common.i18n import _LI
from heat.common import messaging
from heat.common import profiler
from heat.common import wsgi
from heat.openstack.common import log as logging
from heat.openstack.common import systemd
i18n.enable_lazy()
@ -50,8 +50,10 @@ LOG = logging.getLogger('heat.api.cfn')
if __name__ == '__main__':
try:
logging.register_options(cfg.CONF)
cfg.CONF(project='heat', prog='heat-api-cfn')
logging.setup('heat')
logging.setup(cfg.CONF, 'heat-api-cfn')
logging.set_defaults()
messaging.setup()
app = config.load_paste_app()

View File

@ -34,6 +34,7 @@ if os.path.exists(os.path.join(possible_topdir, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
from oslo_log import log as logging
import six
from heat.common import config
@ -41,7 +42,6 @@ from heat.common.i18n import _LI
from heat.common import messaging
from heat.common import profiler
from heat.common import wsgi
from heat.openstack.common import log as logging
from heat.openstack.common import systemd
i18n.enable_lazy()
@ -50,8 +50,10 @@ LOG = logging.getLogger('heat.api.cloudwatch')
if __name__ == '__main__':
try:
logging.register_options(cfg.CONF)
cfg.CONF(project='heat', prog='heat-api-cloudwatch')
logging.setup('heat')
logging.setup(cfg.CONF, 'heat-api-cloudwatch')
logging.set_defaults()
messaging.setup()
app = config.load_paste_app()

View File

@ -34,12 +34,12 @@ if os.path.exists(os.path.join(POSSIBLE_TOPDIR, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
from oslo_log import log as logging
from heat.common.i18n import _LC
from heat.common import messaging
from heat.common import profiler
from heat.engine import template
from heat.openstack.common import log as logging
from heat.openstack.common import service
from heat.rpc import api as rpc_api
@ -48,9 +48,10 @@ i18n.enable_lazy()
LOG = logging.getLogger('heat.engine')
if __name__ == '__main__':
logging.register_options(cfg.CONF)
cfg.CONF(project='heat', prog='heat-engine')
logging.setup('heat')
logging.setup(cfg.CONF, 'heat-engine')
logging.set_defaults()
messaging.setup()
mgr = None

View File

@ -9,10 +9,10 @@ namespace = heat.engine.clients
namespace = heat.engine.notification
namespace = heat.engine.resources
namespace = heat.openstack.common.eventlet_backdoor
namespace = heat.openstack.common.log
namespace = heat.openstack.common.policy
namespace = heat.api.middleware.ssl
namespace = heat.api.aws.ec2token
namespace = keystonemiddleware.auth_token
namespace = oslo.messaging
namespace = oslo.db
namespace = oslo.log

View File

@ -11,6 +11,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common import exception
@ -20,7 +21,6 @@ from heat.engine import clients
from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common import exception
@ -20,7 +21,6 @@ from heat.engine import clients
from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -14,6 +14,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common.i18n import _
@ -21,7 +22,6 @@ from heat.common.i18n import _LW
from heat.engine import attributes
from heat.engine import properties
from heat.engine import resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -16,12 +16,12 @@
from keystoneclient.v2_0 import client as kc
from oslo.config import cfg
from oslo.utils import importutils
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _LE
from heat.common.i18n import _LI
from heat.common.i18n import _LW
from heat.openstack.common import log as logging
LOG = logging.getLogger('heat.common.keystoneclient')
LOG.info(_LI("Keystone V2 loaded"))

View File

@ -11,8 +11,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common.i18n import _LE
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -20,6 +20,7 @@ import urlparse
from glanceclient import client as gc
from oslo.config import cfg
from oslo_log import log as logging
from swiftclient import utils as swiftclient_utils
from troveclient import client as tc
@ -32,7 +33,6 @@ from heat.engine.clients.os import glance
from heat.engine.clients.os import nova
from heat.engine.clients.os import swift
from heat.engine.clients.os import trove
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,12 +13,13 @@
"""Resources for Rackspace DNS."""
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.openstack.common import log as logging
try:
from pyrax.exceptions import NotFound

View File

@ -15,6 +15,7 @@ import copy
import functools
import itertools
from oslo_log import log as logging
import six
from heat.common import exception
@ -26,7 +27,6 @@ from heat.engine import function
from heat.engine import properties
from heat.engine import resource
from heat.engine import scheduler
from heat.openstack.common import log as logging
try:
from pyrax.exceptions import NotFound # noqa

View File

@ -13,6 +13,8 @@
import copy
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LW
@ -20,7 +22,6 @@ from heat.engine import attributes
from heat.engine import properties
from heat.engine.resources import server
from heat.engine import support
from heat.openstack.common import log as logging
try:
import pyrax # noqa

View File

@ -12,6 +12,7 @@
# under the License.
import netaddr
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
@ -21,7 +22,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
try:
from pyrax.exceptions import NetworkInUse # noqa

View File

@ -16,6 +16,7 @@ import hashlib
from oslo.config import cfg
from oslo.serialization import jsonutils as json
from oslo.utils import importutils
from oslo_log import log as logging
import requests
import webob
@ -24,7 +25,6 @@ from heat.common.i18n import _
from heat.common.i18n import _LE
from heat.common.i18n import _LI
from heat.common import wsgi
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -16,9 +16,10 @@
import itertools
import re
from oslo_log import log as logging
from heat.api.aws import exception
from heat.common.i18n import _LE
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -18,6 +18,8 @@ Stack endpoint for Heat CloudFormation v1 API.
import json
import socket
from oslo_log import log as logging
from heat.api.aws import exception
from heat.api.aws import utils as api_utils
from heat.common import exception as heat_exception
@ -28,7 +30,6 @@ from heat.common import policy
from heat.common import template_format
from heat.common import urlfetch
from heat.common import wsgi
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
from heat.rpc import client as rpc_client

View File

@ -14,6 +14,7 @@
"""Endpoint for heat AWS-compatible CloudWatch API."""
from oslo import messaging
from oslo_log import log as logging
import six
from heat.api.aws import exception
@ -24,7 +25,6 @@ from heat.common.i18n import _LE
from heat.common.i18n import _LW
from heat.common import policy
from heat.common import wsgi
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
from heat.rpc import client as rpc_client

View File

@ -31,9 +31,6 @@ from heat.common import serializers
from heat.common import wsgi
cfg.CONF.import_opt('debug', 'heat.openstack.common.log')
class Fault(object):
def __init__(self, error):

View File

@ -19,11 +19,10 @@ return
import re
from oslo_log import log as logging
import webob
from heat.common import wsgi
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -15,6 +15,7 @@
Stack endpoint for Heat v1 ReST API.
"""
from oslo_log import log as logging
import six
from six.moves.urllib import parse
from webob import exc
@ -30,7 +31,6 @@ from heat.common import serializers
from heat.common import template_format
from heat.common import urlfetch
from heat.common import wsgi
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
from heat.rpc import client as rpc_client

View File

@ -20,13 +20,13 @@
import sys
from oslo.config import cfg
from oslo_log import log
from heat.common import context
from heat.common.i18n import _
from heat.common import service_utils
from heat.db import api
from heat.db import utils
from heat.openstack.common import log
from heat import version
@ -113,13 +113,14 @@ command_opt = cfg.SubCommandOpt('command',
def main():
log.register_options(CONF)
log.setup(CONF, "heat-manage")
CONF.register_cli_opt(command_opt)
try:
default_config_files = cfg.find_config_files('heat', 'heat-engine')
CONF(sys.argv[1:], project='heat', prog='heat-manage',
version=version.version_info.version_string(),
default_config_files=default_config_files)
log.setup("heat")
except RuntimeError as e:
sys.exit("ERROR: %s" % e)

View File

@ -19,10 +19,10 @@ import os
from eventlet.green import socket
from oslo.config import cfg
from oslo_log import log as logging
from heat.common.i18n import _
from heat.common import wsgi
from heat.openstack.common import log as logging
paste_deploy_group = cfg.OptGroup('paste_deploy')
paste_deploy_opts = [

View File

@ -19,6 +19,7 @@ from oslo.config import cfg
from oslo.middleware import request_id as oslo_request_id
from oslo.utils import importutils
from oslo_context import context
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _LE
@ -27,7 +28,6 @@ from heat.common import wsgi
from heat.db import api as db_api
from heat.engine import clients
from heat.openstack.common import local
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -19,13 +19,12 @@
import functools
import sys
from oslo_log import log as logging
import six
from six.moves.urllib import parse as urlparse
from heat.common.i18n import _
from heat.common.i18n import _LE
from heat.openstack.common import log as logging
_FATAL_EXCEPTION_FORMAT_ERRORS = False

View File

@ -22,13 +22,13 @@ from keystoneclient import session
from keystoneclient.v3 import client as kc_v3
from oslo.config import cfg
from oslo.utils import importutils
from oslo_log import log as logging
from heat.common import context
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LE
from heat.common.i18n import _LW
from heat.openstack.common import log as logging
LOG = logging.getLogger('heat.common.keystoneclient')

View File

@ -15,10 +15,12 @@
'''
Utility for fetching and running plug point implementation classes
'''
from oslo_log import log as logging
from heat.common.i18n import _LE
from heat.common.i18n import _LI
from heat.engine import resources
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)
pp_class_instances = None

View File

@ -23,10 +23,10 @@ import pkgutil
import sys
import types
from oslo_log import log as logging
import six
from heat.common.i18n import _LE
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,13 +13,13 @@
from oslo.config import cfg
from oslo import messaging
from oslo_log import log as logging
import osprofiler.profiler
import osprofiler.web
from heat.common import context
from heat.common.i18n import _LW
from heat.common import messaging as rpc_messaging
from heat.openstack.common import log as logging
cfg.CONF.import_opt('profiler_enabled', 'heat.common.config', group='profiler')

View File

@ -24,10 +24,9 @@ import datetime
import json
from lxml import etree
from oslo_log import log as logging
import six
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -14,6 +14,7 @@
"""Utility for fetching a resource (e.g. a template) from a URL."""
from oslo.config import cfg
from oslo_log import log as logging
import requests
from requests import exceptions
from six.moves import urllib
@ -21,7 +22,6 @@ from six.moves import urllib
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
from heat.openstack.common import log as logging
cfg.CONF.import_opt('max_template_size', 'heat.common.config')

View File

@ -156,8 +156,6 @@ api_cw_group = cfg.OptGroup('heat_api_cloudwatch')
cfg.CONF.register_group(api_cw_group)
cfg.CONF.register_opts(api_cw_opts,
group=api_cw_group)
cfg.CONF.import_opt('debug', 'heat.openstack.common.log')
cfg.CONF.import_opt('verbose', 'heat.openstack.common.log')
json_size_opt = cfg.IntOpt('max_json_body_size',
default=1048576,

View File

@ -14,13 +14,13 @@
import collections
from oslo.utils import timeutils
from oslo_log import log as logging
from heat.common.i18n import _
from heat.common.i18n import _LE
from heat.common import param_utils
from heat.common import template_format
from heat.engine import constraints as constr
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
LOG = logging.getLogger(__name__)

View File

@ -15,13 +15,13 @@ import warnings
from oslo.config import cfg
from oslo.utils import importutils
from oslo_log import log as logging
import six
from stevedore import extension
from heat.common import exception
from heat.common.i18n import _LE
from heat.common.i18n import _LW
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -14,13 +14,13 @@
from glanceclient import client as gc
from glanceclient import exc
from oslo.utils import uuidutils
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
from heat.engine.clients import client_plugin
from heat.engine import constraints
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -18,6 +18,7 @@ import os.path
import warnings
from oslo.config import cfg
from oslo_log import log
import six
from heat.common import environment_format as env_fmt
@ -27,8 +28,6 @@ from heat.common.i18n import _LE
from heat.common.i18n import _LI
from heat.common.i18n import _LW
from heat.engine import support
from heat.openstack.common import log
LOG = log.getLogger(__name__)

View File

@ -11,9 +11,10 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -16,11 +16,11 @@ import itertools
import sys
from oslo.config import cfg
from oslo_log import log
import six
from heat.common.i18n import _LE
from heat.common import plugin_loader
from heat.openstack.common import log
LOG = log.getLogger(__name__)

View File

@ -19,6 +19,7 @@ import warnings
from oslo.config import cfg
from oslo.utils import encodeutils
from oslo.utils import excutils
from oslo_log import log as logging
import six
from heat.common import exception
@ -39,7 +40,6 @@ from heat.engine import resources
from heat.engine import rsrc_defn
from heat.engine import scheduler
from heat.engine import support
from heat.openstack.common import log as logging
from heat.rpc import client as rpc_client
cfg.CONF.import_opt('action_retry_limit', 'heat.common.config')

View File

@ -14,6 +14,7 @@
import math
from oslo.utils import excutils
from oslo_log import log as logging
import six
from heat.common import exception
@ -30,7 +31,6 @@ from heat.engine import resource
from heat.engine.resources import instance_group as instgrp
from heat.engine import rsrc_defn
from heat.engine import support
from heat.openstack.common import log as logging
from heat.scaling import cooldown
LOG = logging.getLogger(__name__)

View File

@ -14,6 +14,7 @@
import copy
from oslo.config import cfg
from oslo_log import log as logging
import six
from heat.common import exception
@ -25,7 +26,6 @@ from heat.engine import properties
from heat.engine import resource
from heat.engine import scheduler
from heat.engine import volume_tasks as vol_task
from heat.openstack.common import log as logging
cfg.CONF.import_opt('instance_user', 'heat.common.config')

View File

@ -10,6 +10,8 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common import exception
@ -19,7 +21,6 @@ from heat.engine import attributes
from heat.engine import constraints
from heat.engine import properties
from heat.engine import signal_responder
from heat.openstack.common import log as logging
from heat.scaling import cooldown
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common import exception
@ -21,7 +22,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import stack_user
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -12,6 +12,7 @@
# under the License.
from oslo.utils import excutils
from oslo_log import log as logging
import six
from heat.common import exception
@ -24,7 +25,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine.resources import vpc
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,6 +13,7 @@
import os
from oslo.config import cfg
from oslo_log import log as logging
import six
from heat.common import exception
@ -23,7 +24,6 @@ from heat.engine import attributes
from heat.engine import constraints
from heat.engine import properties
from heat.engine import stack_resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,8 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common.i18n import _
from heat.common.i18n import _LW
from heat.engine import attributes
@ -20,7 +22,6 @@ from heat.engine import resource
from heat.engine.resources.neutron import neutron
from heat.engine.resources.neutron import subnet
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,6 +13,7 @@
from heat.common import exception
from oslo.utils import excutils
from oslo_log import log as logging
import six
from heat.common.i18n import _
@ -22,7 +23,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -23,6 +23,7 @@ import warnings
from novaclient import exceptions as nova_exceptions
from oslo.config import cfg
from oslo_log import log as logging
import six
from six.moves.urllib import parse as urlparse
@ -30,7 +31,6 @@ from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LW
from heat.engine import scheduler
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common.i18n import _
@ -20,7 +21,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import signal_responder
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -10,6 +10,8 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common import exception
@ -20,7 +22,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import signal_responder
from heat.openstack.common import log as logging
from heat.scaling import cooldown
LOG = logging.getLogger(__name__)

View File

@ -13,6 +13,7 @@
import json
from oslo_log import log as logging
import six
from heat.common import exception
@ -25,7 +26,6 @@ from heat.engine.resources.aws import volume as aws_vol
from heat.engine import scheduler
from heat.engine import support
from heat.engine import volume_tasks as vol_task
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,6 +13,7 @@
import json
from oslo_log import log as logging
from oslo_utils import timeutils
import six
@ -24,7 +25,6 @@ from heat.engine import properties
from heat.engine import resource
from heat.engine.resources import wait_condition as wc_base
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,8 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
@ -20,7 +22,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common import context
@ -23,7 +24,6 @@ from heat.engine import environment
from heat.engine import function
from heat.engine import properties
from heat.engine import resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,6 +13,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
@ -21,7 +23,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -13,6 +13,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
@ -20,7 +22,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -17,6 +17,7 @@ import uuid
from oslo.config import cfg
from oslo.serialization import jsonutils
from oslo.utils import uuidutils
from oslo_log import log as logging
import six
from heat.common import exception
@ -30,7 +31,6 @@ from heat.engine.resources.neutron import subnet
from heat.engine import scheduler
from heat.engine import stack_user
from heat.engine import support
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
cfg.CONF.import_opt('instance_user', 'heat.common.config')

View File

@ -11,13 +11,14 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common.i18n import _
from heat.engine import attributes
from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
LOG = logging.getLogger(__name__)

View File

@ -15,6 +15,7 @@ import copy
import uuid
from oslo.utils import timeutils
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
@ -26,7 +27,6 @@ from heat.engine.resources import resource_group
from heat.engine.resources.software_config import software_config as sc
from heat.engine import signal_responder
from heat.engine import support
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
LOG = logging.getLogger(__name__)

View File

@ -10,6 +10,8 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from six.moves.urllib import parse as urlparse
@ -20,7 +22,6 @@ from heat.engine import attributes
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -14,6 +14,7 @@
import json
import urlparse
from oslo_log import log as logging
from oslo_utils import timeutils
import six
@ -26,7 +27,6 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import support
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,12 +11,13 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LE
from heat.common.i18n import _LW
from heat.engine import signal_responder
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -20,11 +20,11 @@ import types
import eventlet
from oslo.utils import encodeutils
from oslo.utils import excutils
from oslo_log import log as logging
import six
from heat.common.i18n import _
from heat.common.i18n import _LI
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -24,6 +24,7 @@ from oslo import messaging
from oslo.serialization import jsonutils
from oslo.utils import timeutils
from oslo.utils import uuidutils
from oslo_log import log as logging
from osprofiler import profiler
import requests
import six
@ -52,7 +53,6 @@ from heat.engine import stack as parser
from heat.engine import stack_lock
from heat.engine import template as templatem
from heat.engine import watchrule
from heat.openstack.common import log as logging
from heat.openstack.common import service
from heat.openstack.common import threadgroup
from heat.rpc import api as rpc_api

View File

@ -12,6 +12,7 @@
# under the License.
from oslo.utils import timeutils
from oslo_log import log as logging
from heat.common import context
from heat.common.i18n import _LE
@ -19,7 +20,6 @@ from heat.common.i18n import _LW
from heat.db import api as db_api
from heat.engine import stack
from heat.engine import watchrule
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
LOG = logging.getLogger(__name__)

View File

@ -13,12 +13,11 @@
from keystoneclient.contrib.ec2 import utils as ec2_utils
from oslo.config import cfg
from oslo_log import log as logging
from six.moves.urllib import parse as urlparse
from heat.common.i18n import _LW
from heat.engine import stack_user
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -19,6 +19,7 @@ import warnings
from oslo.config import cfg
from oslo.utils import encodeutils
from oslo_log import log as logging
from osprofiler import profiler
import six
@ -41,7 +42,6 @@ from heat.engine import resources
from heat.engine import scheduler
from heat.engine import template as tmpl
from heat.engine import update
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
cfg.CONF.import_opt('error_wait_time', 'heat.common.config')

View File

@ -17,13 +17,13 @@ import uuid
from oslo.config import cfg
from oslo import messaging
from oslo.utils import excutils
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _LI
from heat.common.i18n import _LW
from heat.common import messaging as rpc_messaging
from heat.db import api as db_api
from heat.openstack.common import log as logging
cfg.CONF.import_opt('engine_life_check_timeout', 'heat.common.config')

View File

@ -15,6 +15,7 @@ import hashlib
from oslo.config import cfg
from oslo.serialization import jsonutils
from oslo_log import log as logging
import six
from heat.common import exception
@ -28,7 +29,6 @@ from heat.engine import resource
from heat.engine import scheduler
from heat.engine import stack as parser
from heat.engine import template
from heat.openstack.common import log as logging
cfg.CONF.import_opt('error_wait_time', 'heat.common.config')

View File

@ -12,13 +12,12 @@
# under the License.
import keystoneclient.exceptions as kc_exception
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LW
from heat.engine import resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -16,13 +16,13 @@ import collections
import copy
import functools
from oslo_log import log as logging
import six
from stevedore import extension
from heat.common import exception
from heat.common.i18n import _
from heat.db import api as db_api
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,6 +11,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common.i18n import _LI
@ -18,7 +19,6 @@ from heat.db import api as db_api
from heat.engine import dependencies
from heat.engine import resource
from heat.engine import scheduler
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -11,11 +11,12 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
from heat.engine import resource
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -15,6 +15,7 @@
import datetime
from oslo.utils import timeutils
from oslo_log import log as logging
from heat.common import exception
from heat.common.i18n import _
@ -23,7 +24,6 @@ from heat.common.i18n import _LW
from heat.db import api as db_api
from heat.engine import stack
from heat.engine import timestamp
from heat.openstack.common import log as logging
from heat.rpc import api as rpc_api
LOG = logging.getLogger(__name__)

View File

@ -10,6 +10,8 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from oslo_log import log as logging
import six
from heat.common.i18n import _
@ -20,7 +22,6 @@ from heat.engine import properties
from heat.engine import resource
from heat.engine import signal_responder
from heat.engine import stack_user
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)

View File

@ -17,6 +17,7 @@ import mock
from oslo.config import cfg
from oslo.messaging._drivers import common as rpc_common
from oslo.messaging import exceptions
from oslo_log import log
import six
import webob.exc
@ -241,6 +242,7 @@ class ControllerTest(object):
self.api_version = '1.0'
self.tenant = 't'
self.mock_enforce = None
log.register_options(cfg.CONF)
def _environ(self, path):
return {

View File

@ -16,6 +16,7 @@ import re
from oslo.config import cfg
from oslo.messaging._drivers import common as rpc_common
from oslo_log import log
import six
import webob
@ -34,6 +35,9 @@ class ErrorWithNewline(webob.exc.HTTPBadRequest):
class FaultMiddlewareTest(common.HeatTestCase):
def setUp(self):
super(FaultMiddlewareTest, self).setUp()
log.register_options(cfg.CONF)
def test_disguised_http_exception_with_newline(self):
wrapper = fault.FaultWrapper(None)

View File

@ -16,6 +16,7 @@ oslo.config>=1.6.0 # Apache-2.0
oslo.context>=0.1.0 # Apache-2.0
oslo.db>=1.4.1 # Apache-2.0
oslo.i18n>=1.3.0 # Apache-2.0
oslo.log>=0.1.0 # Apache-2.0
oslo.messaging>=1.6.0 # Apache-2.0
oslo.middleware>=0.3.0 # Apache-2.0
oslo.serialization>=1.2.0 # Apache-2.0

View File

@ -40,7 +40,6 @@ oslo.config.opts =
heat.engine.notification = heat.engine.notification:list_opts
heat.engine.resources = heat.engine.resources:list_opts
heat.openstack.common.eventlet_backdoor = heat.openstack.common.eventlet_backdoor:list_opts
heat.openstack.common.log = heat.openstack.common.log:list_opts
heat.openstack.common.policy = heat.openstack.common.policy:list_opts
heat.api.middleware.ssl = heat.api.middleware.ssl:list_opts
heat.api.aws.ec2token = heat.api.aws.ec2token:list_opts