Commit ce9283c1 authored by Thomas Thrainer's avatar Thomas Thrainer Committed by Michele Tartara

Move lib/bdev.py to lib/block/bdev.py

That's in preparation of extracting DRBD related code from bdev.py. As
bdev.py is already rather long, new features will require to split it
into more manageable pieces. That's why it's moved in an own directory.
Signed-off-by: default avatarThomas Thrainer <thomasth@google.com>
Signed-off-by: default avatarMichele Tartara <mtartara@google.com>
Reviewed-by: default avatarMichele Tartara <mtartara@google.com>
parent bbfa259c
......@@ -41,6 +41,7 @@ SHELL_ENV_INIT = autotools/shell-env-init
# the directory + 'dir' suffix
clientdir = $(pkgpythondir)/client
hypervisordir = $(pkgpythondir)/hypervisor
blockdir = $(pkgpythondir)/block
httpdir = $(pkgpythondir)/http
masterddir = $(pkgpythondir)/masterd
confddir = $(pkgpythondir)/confd
......@@ -108,6 +109,7 @@ DIRS = \
lib/confd \
lib/http \
lib/hypervisor \
lib/block \
lib/impexpd \
lib/masterd \
lib/rapi \
......@@ -257,7 +259,6 @@ pkgpython_PYTHON = \
lib/__init__.py \
lib/asyncnotifier.py \
lib/backend.py \
lib/bdev.py \
lib/bootstrap.py \
lib/cli.py \
lib/cmdlib.py \
......@@ -314,6 +315,10 @@ hypervisor_PYTHON = \
lib/hypervisor/hv_lxc.py \
lib/hypervisor/hv_xen.py
block_PYTHON = \
lib/block/__init__.py \
lib/block/bdev.py
rapi_PYTHON = \
lib/rapi/__init__.py \
lib/rapi/baserlib.py \
......@@ -1112,7 +1117,7 @@ python_tests = \
test/py/ganeti.asyncnotifier_unittest.py \
test/py/ganeti.backend_unittest-runasroot.py \
test/py/ganeti.backend_unittest.py \
test/py/ganeti.bdev_unittest.py \
test/py/ganeti.block.bdev_unittest.py \
test/py/ganeti.cli_unittest.py \
test/py/ganeti.client.gnt_cluster_unittest.py \
test/py/ganeti.client.gnt_instance_unittest.py \
......@@ -1232,6 +1237,7 @@ all_python_code = \
$(pkgpython_PYTHON) \
$(client_PYTHON) \
$(hypervisor_PYTHON) \
$(block_PYTHON) \
$(rapi_PYTHON) \
$(server_PYTHON) \
$(pytools_PYTHON) \
......
......@@ -54,7 +54,7 @@ from ganeti import utils
from ganeti import ssh
from ganeti import hypervisor
from ganeti import constants
from ganeti import bdev
from ganeti.block import bdev
from ganeti import objects
from ganeti import ssconf
from ganeti import serializer
......
#
#
# Copyright (C) 2006, 2007, 2008 Google Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
# 02110-1301, USA.
"""Block device abstraction
"""
......@@ -40,7 +40,7 @@ from ganeti import objects
from ganeti import ssconf
from ganeti import serializer
from ganeti import hypervisor
from ganeti import bdev
from ganeti.block import bdev
from ganeti import netutils
from ganeti import luxi
from ganeti import jstore
......
......@@ -270,7 +270,7 @@ def _GetConfigFileDiskData(block_devices, blockdev_prefix,
@param block_devices: list of tuples (cfdev, rldev):
- cfdev: dict containing ganeti config disk part
- rldev: ganeti.bdev.BlockDev object
- rldev: ganeti.block.bdev.BlockDev object
@param blockdev_prefix: a string containing blockdevice prefix,
e.g. "sd" for /dev/sda
......
......@@ -25,7 +25,6 @@
import logging
from ganeti import bdev
from ganeti import constants
from ganeti import errors
from ganeti import hypervisor
......@@ -33,6 +32,7 @@ from ganeti import netutils
from ganeti import ssconf
from ganeti import utils
from ganeti import confd
from ganeti.block import bdev
import ganeti.confd.client # pylint: disable=W0611
......
......@@ -26,12 +26,12 @@ import os
import random
import unittest
from ganeti import bdev
from ganeti import compat
from ganeti import constants
from ganeti import errors
from ganeti import objects
from ganeti import utils
from ganeti.block import bdev
import testutils
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment