36 Commits

Author SHA1 Message Date
Jay Xu
86383ff900 Add EMC Unity Driver for Manila
EMC Unity arrays are capable of support manila.
Add a new Unity plugin in manila which allows user to create NFS/CIFS
share with a Unity backend.

The plugin should support following APIs:

* connect: Connect to the Unity Storage.
* check_for_setup_error: No implementation.
* create_share: Create a share and export it based on the protocol used
  (NFS or CIFS).
* create_share_from_snapshot: Create a share from a snapshot - clone a
  snapshot.
* delete_share: Delete a share.
* extend_share: Extend the maximum size of a share.
* create_snapshot: Create a snapshot for the specified share.
* delete_snapshot: Delete the snapshot of the share.
* allow_access: Allow access of a user/host to a share.
* deny_access: Remove the access of a user/host to the share.
* ensure_share: Check whether share exists or not.
* update_share_stats: Retrieve share related statistics from Unity.
* get_network_allocatins_number: Returns number of network allocations
  for creating VIFs.
* setup_server: Set up and configures share server with given network
  parameters.
* teardown_server: Tear down the share server.

DocImpact
Co-Authored-By: Cedric Zhuang <cedric.zhuang@emc.com>
Change-Id: Ic520539341fa19ec5c6c6b85c3c1dcecf70e5141
Implements: blueprint emc-unity-manila-support
2016-07-28 23:13:29 -07:00
tpsilva
f10776d832 Add DriverFilter and GoodnessWeigher to manila
This patch ports cinder's DriverFilter and GoodnessWeigher to manila.
These can use two new properties provided by backends,
'filter_function' and 'goodness_function', which can be used to filter
and weigh qualified backends, respectively.

Reference for cinder spec: I59b607a88953a346aa35e67e785a0417a7ce8cc9
Reference for cinder commit: I38408ab49b6ed869c1faae746ee64a3bae86be58

DocImpact
Change-Id: I873f4152e16efdeb30ceae26335a7974dc9b4b69
Implements: blueprint driver-filter-goodness-weigher
2016-07-18 17:28:40 -03:00
Doug Hellmann
04ce4a42d0 register the config generator default hook with the right name
No config generator hooks should ever be registered with a name that
belongs to another project. In this case, using oslo.middleware.cors
means that *every other project* that loads the middleware gets this
application's defaults when the generator is run on a system with
everything installed (such as a dev box with devstack). Use the name
of the app instead, to ensure that the defaults are only set when this
app's sample config and documentation are being generated.

Change-Id: I6a8c7d44b9db9325003ff2fdb667b0ced7739e96
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2016-03-11 16:06:50 -05:00
Tin Lam
75d85aab3c Moved CORS middleware configuration into oslo-config-generator
The default values needed for manila's implementation of cors
middleware have been moved from paste.ini into the configuration
hooks provided by oslo.config. Furthermore, these values have been
added to the default initialization procedure. This ensures
that if a value remains unset in the configuration file, it will
fallback to using sane defaults. It also ensures that an operator
modifying the configuration will be presented with that same
set of defaults.

Change-Id: Ie4adc39866a4ee6132eab6a111660218b3e6e5bd
Closes-Bug: #1551836
2016-03-03 16:13:20 +00:00
Rodrigo Barbieri
eaaa86f1f4 Introduced Data Service
Added a new service defined as data, whose purpose is to
receive requests, process data operations such as copying,
migration, backup, and send back the response after operation
has been completed.

In this patch the service has no methods, it is empty, the
operation it should perform will be added in subsequent patches.

Implements: blueprint data-copy-service
Change-Id: I31365c8ac4197541af175c82f8f18a3d11740a99
2016-03-01 17:13:51 -03:00
Goutham Pacha Ravi
68925cbac7 Scheduler enhancements for Share Replication
Backends supporting replication of shares could be
limited by vendor or storage model or software. Cloud
administrators may also need to configure backends
outside of Manila to support replication between these
backends.

Hence, Manila should allow administrators to specify
'replication_domain's. This configuration is reported to the
scheduler as a backend capability as part of the
_update_share_stats() driver call. The scheduler
should acknowledge this 'capability' when scheduling
shares supporting replication and replicas themselves.

Introduce a new scheduler filter that uses a backend
reported "capability" called 'replication_domain'.

Implements bp: manila-dr-scheduler-enhancements

DocImpact

Change-Id: I194054a9a1071c2d577a588e3299ae81490cd0f8
2016-02-24 14:05:09 -05:00
ting.wang
663c663f4b Replace deprecated oslo_messaging _impl_messaging
Use oslo_messaging.notify.messaging instead of the
deprecated oslo_messaging.notify._impl_messaging.

ref:
https://github.com/openstack/oslo.messaging/blob/master/oslo_messaging/notify/_impl_messaging.py#L20

Change-Id: I8691877d968312a0480860717b6e07c162ddd47a
2016-02-10 17:48:56 +08:00
Ben Swartzlander
689c7a62e0 Remove version per M-1 release instructions
http://lists.openstack.org/pipermail/openstack-dev/2015-November/080692.html

Change-Id: I2e60b0f1aab323097c80033dc18c6e71b03eaabf
Depends-On: I940523437b7de1a5c113535dfd0ecfdc2cc6bea8
2015-12-03 14:22:13 -05:00
Clinton Knight
af2e103514 Reorganize scheduler and merge code from Oslo incubator
With oslo-incubator going away, we need to pull those classes into
the Manila code base, along with their unit tests.  This presents a
good opportunity to do some long-needed housecleaning.  This commit
does the following:

1. Moves the scheduler classes from openstack.common to manila.
2. Adds the unit tests from olso-incubator into Manila.
3. Removes duplication among the combined scheduler modules.
4. Moves scheduler drivers into a sub-module.
5. Normalizes class and module naming throughout the scheduler.
6. Splits some unit test files so they match the names of the
   modules that they test.
7. Converts usage of mox & oslotest to mock & unittest.
8. Adds a few unit tests to boost coverage levels.

Implements: blueprint reorganize-manila-scheduler
Change-Id: I7aa237e17787e89a95bb198093ea9bc9498279cd
2015-12-01 20:54:17 +00:00
Dustin Schoenbrun
c1fe6c4140 Make setup.py install Manila Tempest plugin
This commit makes the install directive in setup.py install the
Manila Tempest plugin when the rest of Manila is installed.

Closes-Bug: #1513953
Co-Author: Marc Koderer <marc@koderer.com>
Change-Id: Id2d75c2901e795ad1309cde275592d89f223471d
2015-11-06 20:59:22 +00:00
Thierry Carrez
52e3fbc18a Open Mitaka development
Bump preversion to mark the start of the Mitaka development branch.
The liberty release branch will be cut from the previous commit.

Change-Id: I3dea067f7e610f551376555d54e23e4ab440c08b
2015-09-22 15:34:39 +02:00
Alex Meade
f3a761f06b Scheduler changes for consistency groups
This patch implements the scheduler changes for
scheduling the creation of consistency groups,
shares within consistency groups, and cgsnapshots.

The consistency group scheduling filter was added
to allow the filtering of hosts that are not supported
by a specified consistency group. If no CG is specified
on share create then this filter is a no-op. CGs will be
scheduled only to a backend that supports all of its
specified share types.

Partially implements bp manila-consistency-groups

Change-Id: Ia03191085cefb47a17ce99ad3f30ba70412f5802
2015-09-05 18:21:17 -04:00
Marc Koderer
09798caae1 Use Tempest plugin interface
Make use of the Tempest plugin interface instead of copying Manila
files into Tempest. This will remove the burden to port Manila
tests onto Tempest master recurrently.

This ports all existing Manila Tempest test to the new structure.

It uses manila_tempest_tests as new top folder for all Tempest
tests. It follow the model of Heat (see [1]).

[1]: https://github.com/openstack/heat/tree/master/heat_integrationtests

Change-Id: Ie5ed64a6777ed1acf8dd56522c26705ae897596d
Partly-implements: bp tempest-plugin-interface
Depends-On: I26dd32b1de8cceeaa6dc674092efec683df71889
2015-09-05 00:36:33 +00:00
Thomas Bechtold
9c679056ee Fix sample config file generation
There's a import missing and oslo-config-generator expects
"oslo.config.opts" as namespace to search for configuration options.

Change-Id: Ib1b3fef9340a8932e8a0a7aacf6dc92ad7a32ab7
Closes-bug: #1485526
2015-08-17 13:26:56 +02:00
Julia Varlamova
bec250e62f Add PoolWeigher for Manila scheduler
Add PoolWeigher which enumerate all of the pools that have existing
share_servers and give those pools a value of 1 while all the other
pools should have a value of 0.

Config option pool_weight_multiplier can be used to increase the
priority of scheduling shares on pools with existing share_servers.

Implements BP share-server-pool-mapping

Change-Id: I7e462de47d50a971237672033e956ed92ce72896
2015-06-26 08:48:13 -04:00
Doug Hellmann
bbb4130ab4 Update version for Liberty
Update the version for Liberty, switching from date-based versioning
to pre-versioning using SemVer. See
http://lists.openstack.org/pipermail/openstack-dev/2015-May/065211.html
and
http://lists.openstack.org/pipermail/openstack-dev/2015-June/067082.html
for details.

Change-Id: I6a35fa0dda798fad93b804d00a46af80f08d475c
2015-06-17 17:27:09 +00:00
Valeriy Ponomaryov
c4e055bd8f Stop using deprecated 'oslo' namespace
Replace usage of deprecated 'oslo' namespace with appropriate 'oslo_*'
namespaces in Manila setup.cfg file.

Change-Id: I3fbe75023d3dec266c0121df436639a2041eadd5
2015-06-10 09:58:00 +03:00
Julia Varlamova
b6ab3167dc Use entry_points for manila scripts
Manila scripts located in bin/* should be covered with unit tests.
In order to add unit tests for bin/* scripts:
- all
- api
- manage
- scheduler
- share
we move them into manila/cmd and use pbr to setup console scripts
which will call the respective main function of each script under manila/cmd.
It will allow us to import from manila.cmd and individually test each 'main' function.

Add unit tests for manila/cmd/* scripts.

Implements bp unit-tests-for-manila-scripts

Change-Id: I9be6b948a6de7ba76405411e98d7531cf225b57e
2015-04-14 21:04:01 +03:00
Thierry Carrez
3d75fb2294 Open Liberty development
Bump pre-version in setup.cfg to formally open Liberty development.
Kilo release branch will be cut from the previous commit.

Change-Id: I48850330d28989b08c1841934b96d748d6173ff5
2015-04-09 16:57:42 +02:00
Shaun Edwards
9cc913ed53 EMC Isilon Manila driver
The Isilon Manila driver supports the following functionalities:
* Create/delete NFS/CIFS share
* Create/delete snapshot
* Allow/deny access to share
* Create share from snapshot

implements: blueprint emc-isilon-manila-driver

Change-Id: If5f064751120890afba0571bc2b407d141ba0323
2015-03-10 15:47:21 +00:00
Valeriy Ponomaryov
bcbab9ce11 Remove Python 2.6 classifier
OpenStack projects dropped support for py26 in Kilo release. So, remove its
classifier.

Change-Id: I22f18eeb9c66837475fa46b06ca4e7b5492065ef
2015-03-01 08:13:45 +00:00
Thomas Bechtold
1d4fb90e10 Set pbr 'warnerrors' option for doc build
By setting this pbr option in setup.cfg, the doc build will fail in
case of any warnings or errors occur during the build process.

Change-Id: I5aa77eb9c45a12e7e4d467eebb90487709cbe197
2015-01-07 17:46:14 +01:00
Jay Xu
e8709c8005 Update EMC Manila driver framework using stevedore
Alternative way of registering plugins in EMC Manila driver framework
using the module *stevedore*.

Change-Id: I3c38a2dbc9575a81c83e64180cd37916abe68334
Implements: blueprint register-emc-manila-plugin-with-stevedore
2014-12-10 05:00:32 -05:00
Andreas Jaeger
883e02f219 Switch to oslo.config
The config module in oslo-incubator has been replaced by oslo.config.
Projects need to switch completely to oslo.config for kilo.

This patch does:
* Register options with oslo.config (new file manila/opts.py)
* Generate the config file using oslo-config-generator
* Remove obsoleted entries for this from openstack-common.conf
* Remove oslo-incubator config files

Change-Id: I30b594423c08782e13a1f615099ae65f997a8551
Closes-Bug: #1382183
2014-10-22 19:55:45 +02:00
Thierry Carrez
7456e27f67 Open Kilo development
Bump pre-version to 2015.1 to formally open master branch to Kilo
development.

Change-Id: Ic011bec64d120e87426076835862a2a327282854
2014-09-30 10:58:51 +02:00
Andreas Jaeger
4d7f4fc43f Fix version number to Juno
We need to update the version number in setup.cfg, otherwise pbr will
fail with:
"error in setup command: Error parsing /opt/stack/new/manila/setup.cfg:
ValueError: git history requires a target version of
pbr.version.SemanticVersion(2014.2.0.0b4), but target version is
pbr.version.SemanticVersion(2013.2.0)"

Change-Id: I608c1dce0169fe78667e5818f2abff3dc8b11447
2014-09-04 07:51:24 +02:00
Andreas Jaeger
cf9f134531 Remove bin/manila-rpc-zmq-receiver
This module is unused and not working, remove it.

Change-Id: I2133af6264e0a4a8b3c056fe4a52de7a041f8b5b
2014-08-25 08:48:22 +02:00
Andreas Jaeger
086d3bd69b Remove manila-clear-rabbit-queues
This script should be removed because it does not
appear to be widely used and there is no user documentation for
it. Also, RabbitMQ now includes a management plugin and CLI,
rabbitmqadmin, that allows you to delete queues and exchanges.

For reference, this removed in nova as part of
https://review.openstack.org/#/c/40355/.

and removed from cinder:
https://review.openstack.org/#/c/109786/

Change-Id: I32403890e190969657ae813e7d3e34a951030321
2014-08-14 13:12:47 +02:00
vponomaryov
13f0446ed5 Use oslo.rootwrap library instead of local copy
Remove rootwrap code copied from oslo-incubator, make
manila-rootwrap a console_script entrypoint pointing in
oslo.rootwrap instead.

Partially-implements blueprint use-common-code

Change-Id: I519e8dec24dc9c48243af41dc0f423c05a0d92e2
2014-07-25 06:03:28 +00:00
vponomaryov
16a04df3d0 Refactor test framework
Manila's test framework is pretty old and requires update.

Changes:
- usage of nose replaced with testr
- now all the tests are thread safe
- added new options for run_tests.sh, such as --concurrency, --debug, etc...
- new '--concurrency' option for run_tests.sh defaults to 1, examples:
    ./run_tests.sh  # will run in 1 thread
    ./run_tests.sh --concurrency 2  # will run tests in 2 threads
- added tools/colorizer.py for colorizing output of testrun with run_tests.sh
- tests running with tox use as much threads as cores available by default
- examples of testrun with tox:
    tox  # will run test suites defined with 'envlist' in tox.ini, now it is pep8,py26,py27
    tox -epy27  # amount of threads is equal to amount of cores
    tox -epy27 -- --concurrency=2  # amount of threads is 2
    tox -epy27 -- --concurrency=4  # amount of threads is 4
- Added 'Database' class to manila.test module, for more conveniant db testing
- updated policy file 'manila/tests/policy.json' to allow share-network actions
- removed nose-related requirements
- added new requirements for testrepository, subunit

With merge of this change all old installed virtual environments become
incompatible and should be removed with "rm -rf .tox .venv" before testrun.

Implements blueprint testr-with-unittests

Change-Id: I9579ecd538e29d478dbc12adc7dcc33fc668b397
2014-07-22 14:58:48 +03:00
Valeriy Ponomaryov
8e5da48361 Migrate to oslo.messaging instead of commom/rpc
Manila uses oslo-incubator/rpc as an RPC library.
During Havana, oslo/rpc was cleaned up and moved into
oslo.messaging with a more stable and well-defined API.

oslo-incubator/rpc considered as deprecated and should be
replaced with oslo.messaging in Manila.

Sum changes:

* New dependency oslo.messaging>=1.3.0 is required

* The new rpc module has init() and cleanup() methods which manage the
global oslo.messaging transport state. The TRANSPORT and NOTIFIER
globals are conceptually similar to the current RPCIMPL global,
except we're free to create and use alternate Transport objects.

* The rpc.get_{client,server,notifier}() methods are just helpers
which wrap the global messaging state, specifiy serializers and
specify the use of the eventlet executor.

* In oslo.messaging, a request context is expected to be a dict, so
RequestContextSerializer was added which can serialize to and from
dicts using RequestContext.{to,from}_dict()

* The allowed_rpc_exception_modules configuration option is replaced
by an allowed_remote_exmods get_transport() parameter. This is not
something that users ever need to configure, but it is something
each project using oslo.messaging needs to be able to customize.

* We maintain a global NOTIFIER object and create specializations of
it with specific publisher IDs in order to avoid notification driver
loading overhead.

* rpc.py contains transport aliases for backwards compatibility
purposes. setup.cfg also contains notification driver aliases for
backwards compat.

* messaging.ConfFixture is used in tests to override oslo.messaging
config options, rather than making assumptions about the options
registered by the library.

Partially-implements bp oslo-messaging

Change-Id: I42cd582f3e1ff96c8f6e8957122b8e9176b1771d
2014-07-03 18:59:33 +03:00
Sascha Peilicke
7e4e38f038 Support building wheels (PEP-427)
With that, building and uploading wheels to PyPI is only one "python
setup.py bdist_wheel" away.

Change-Id: Ie69ebaf407748b3bc2763fa6b34d3b2b58ea6e3a
2013-11-19 11:25:32 +01:00
Monty Taylor
58e2867192 Change wording of short description
It's important to keep the language very specific for trademark reasons.

Change-Id: I147d0c56339099bb0bd602700fe57b67975efc36
2013-10-15 19:45:32 -03:00
Yulia Portnova
bb79e54fa1 Removed backups 2013-09-03 12:00:14 +03:00
Yulia Portnova
dc4ce932ed Renamed cinder to manila.
Fixed setup.py, fixed bin scripts.
2013-09-02 09:59:07 +03:00
Ben Swartzlander
f99ef92c90 Initialize from cinder 2013-08-08 10:34:06 -04:00