167 Commits

Author SHA1 Message Date
Jenkins
8d47940def Merge "Fix meta var problem in cluster-policy-list" 2016-01-15 15:57:17 +00:00
Jenkins
f4deb39c62 Merge "Remove cluster-policy-enable/disable" 2016-01-15 15:21:01 +00:00
EldonZhao
3576f5d65b Fix update_policy parameter passing error
Closes-Bug: #1534072
Change-Id: I98079458b4d1f04ba64bbd40e4640b8547bc1af8
2016-01-15 16:13:14 +08:00
tengqm
6cf6c81222 Remove cluster-policy-enable/disable
The cluster-policy-enable and cluster-policy-disable APIs are now
useless since we have removed almost all other properties from a
cluster-policy binding. The enable/disable logic has better be done
through the cluster-policy-update operation which is more generic than
these two. So we have deleted them from senlin-api and sdk.

This patch adapts the client to this change.

Change-Id: I3c3a58ab7e75faec21400bbbad0b5e8420790d51
2016-01-15 02:41:11 -05:00
tengqm
7d4b7b7c76 Fix meta var problem in cluster-policy-list
We were trying to make the METAVAR a little bit intuitive for command
line options. However, the argparse package is obviously not that smart
as we imagined. It cannot parse '<KEY[:DIR]>' properly so the command is
now failing silently.

This patch fixes the problem.

Change-Id: I6eae7f0eb8b92ad8443236b1f1213a28a3118307
2016-01-15 02:36:47 -05:00
Jenkins
9118fff840 Merge "Remove node join/leave from senlinclient" 2016-01-15 05:33:03 +00:00
Ethan Lynn
8ff51b8398 Remove node join/leave from senlinclient
Remove node join/leave from senlinclient

Change-Id: Iad829753df418e5fe236d8d3f2a7c5151ce3cc02
2016-01-15 12:19:41 +08:00
Haiwei Xu
251e1c9be3 Remove 'permission' from senlin client
Change-Id: I1f05dc05b06d6eb86e818180821b1b3cebeeb2ff
2016-01-15 01:38:28 +00:00
Haiwei Xu
5c654bdf9a Remove 'level', 'cooldown' and 'priority' properties in client
Change-Id: I2dc8f7da519a07e45e55f969cc53bedc8263a6bf
2016-01-15 09:15:03 +09:00
tengqm
b56affc657 Revise client to support new sorting option
This adapts the client shell to use the new sorting option. In future we
can do a client side parsing and validation of sorting keys/dirs.

Change-Id: Ifd619ba3382759f00efcb292ed59c21dc3e74162
2016-01-08 20:57:37 -05:00
tengqm
42867140cd Remove references to oslo incubator modules
oslo incubator project has graduated. The only impact on senlinclient is
that we are gonna maintain some functions from the 'cliutils.py' module
by ourselves. This is not a big deal though.

Change-Id: I141bb9bd99a7c2d12d34dca41d2ff4f2b5da207b
2016-01-07 03:28:08 -05:00
Jenkins
9a25f13533 Merge "Make sort keys work for node-list and action-list" 2016-01-04 07:54:37 +00:00
Haiwei Xu
df9cbca298 Make sort keys work for node-list and action-list
Some sort_keys columns are not shown in node-list,
and action-list, which will make sort keys meanless,
so add those keys into list fields.

Change-Id: I6dd93a9f9d01dad4b81b43792d88f8495c75264c
Closes-bug: #1528103
2016-01-04 16:47:18 +09:00
tengqm
c00408632e Fix cluster-policy-list command
After switching to SDK calls, we are not properly showing the name and
type of policies bound to a cluster. This patch fixes the problem.

Change-Id: Ie5549ba6c8c67943c0595469d9fc1d7094e6825b
2016-01-04 01:43:24 -05:00
tengqm
d14f733765 Switch to use SDK calls in client
This patch revises more calls from client side to use SDK interface.

Change-Id: I3ec4c3e7315f204d4eb6022bed63abd6b28e8157
2016-01-04 01:36:36 -05:00
Jenkins
6bcf949e5b Merge "Put 'policy' out of params for do_cluster_policy_attach" 2016-01-04 06:34:23 +00:00
Haiwei Xu
414ad237b6 Put 'policy' out of params for do_cluster_policy_attach
In openstackSDK cluster_attach_policy method has 'cluster'
and 'policy' parameters out of **params, so senlinclient
should do the same thing for calling SDK.

Change-Id: I18d3c499467daf371f64c2a883af7c710d16db87
Closes-bug: #1530751
2016-01-04 12:04:36 +09:00
Jenkins
2dfdc8188f Merge "Fix redundent paginated in senlinclient" 2016-01-04 02:48:47 +00:00
tengqm
ec375cf551 Rename timestamp fields according to server change
This is a follow up to the server side changes.

Change-Id: I41819cfba550c6832fc536cb88d26e01351d0dec
2016-01-03 11:12:23 -05:00
Jenkins
e4df9991ef Merge "Remove 'show-deleted' from command line options" 2016-01-03 15:41:15 +00:00
Jenkins
26760a95ad Merge "Make cluster action calls use SDK interface" 2016-01-03 13:15:24 +00:00
Jenkins
4dc82390d3 Merge "Fix formatters used for listing actions" 2016-01-03 12:19:05 +00:00
tengqm
c6dde15701 Remove 'show-deleted' from command line options
This patch removes the 'show-deleted' option from command line because
it is no longer available from senlin api.

Change-Id: I4395727ece8d677c16a7055038e3dd6de0e7246b
2016-01-03 06:33:36 -05:00
tengqm
32535578c5 Make cluster action calls use SDK interface
Switch to use SDK interface directly for cluster action calls.

Change-Id: I79f4c281f9ec4393f91e81de7548ac523158f221
2016-01-01 10:36:29 -05:00
Jenkins
90e9622764 Merge "Make cluster CRUD calls invoke SDK" 2016-01-01 15:16:14 +00:00
Cindia-blue
aa71300a6d Fix redundent paginated in senlinclient
This patch fixes argument of paginated to resolve TypeError when list
profile type.

Change-Id: I1144e994a46cc542c5ba9f1e786f515c0696c5fa
Closes-bug: #1530019
2015-12-31 10:06:53 +08:00
tengqm
9d80e939d5 Fix formatters used for listing actions
This patch fixes the formatters used for listing actions.

Change-Id: I4670caf08424afc5531a269c219381d352fe2be3
2015-12-29 23:40:12 -05:00
tengqm
5754dafe5a Fix shell message for action list
Fix some typos in shell messages.

Change-Id: I8b435315a138d8c11335ba74978bac6eb50d2838
2015-12-29 23:25:07 -05:00
tengqm
36b28a22a8 Make cluster CRUD calls invoke SDK
Switching cluster CRUD operations to call SDK interfaces directly.

Change-Id: Iba5ce951be0577b21c1b11dbea05b7f8d69041a2
2015-12-29 19:52:44 -05:00
Jenkins
58f3bbe41c Merge "Unit test for /v1/shell.py part3" 2015-12-26 13:58:21 +00:00
tengqm
64e9afa470 Directly use SDK calls in client (1)
Switch to use SDK calls from senlinclient.

Change-Id: I26383e44c2c8e59a3265846a172b22cf9a6d0f2a
2015-12-22 00:43:56 -05:00
Haiwei Xu
408f0e8dbe Unit test for /v1/shell.py part3
Change-Id: I6d8e2c6bb0ea278f540b6ea2d39668f519636942
2015-12-21 20:43:45 +09:00
tengqm
7dbf6250d9 Client support to receivers
This patch adds client side support to receivers.

Change-Id: Ifc15a524a8a7de1a7e283119385bfd2a5cf43481
partial-blueprint: support-general-receiver-abstraction
Depends-On: I400f9d34737d443e1cc4b7f4fcc6f6241ff96bd2
2015-12-21 04:14:33 -05:00
Jenkins
d705ef0c10 Merge "Replace inner methods with lambda function" 2015-12-21 09:13:41 +00:00
Haiwei Xu
ce8345259d Make event-list sort_keys all workable
Currently when listing events, user can sort events by keys like
'user' and 'obj_name', but these columns are not in the list which
makes the sorting meanless.
Because 'user' is almost always keeping the same, so don't use it
as a sort key, adding 'level' as a sort key.

Change-Id: I3b298f660faf81e69431320248bc6b342faff3b2
Closes-bug: #1528103
2015-12-21 16:14:12 +09:00
Haiwei Xu
d308b94896 Replace inner methods with lambda function
Some inner methods can be simplified by using lambda function.

Change-Id: I6e9286fe9346e35c3852e2bdb945783ac121d2b2
2015-12-21 09:24:03 +09:00
Haiwei Xu
2c525e9178 Don't show show_deleted column in node-list when not needed
If user wants to show the nodes which are already deleted they
can use '-D' in node-list, but if '-D' is not set, 'show_deleted'
column should not shown in node-list. 'show_deleted' option should
always be True/False, not None.

Change-Id: I83ace7515f31bcb30c83b9f0147f33dd94c72baf
Closes-bug: #1526177
2015-12-16 17:51:30 +09:00
Haiwei Xu
48cc6337c3 Make cluster-policy-update help message clear
Current help message of cluster-policy-update may make
user feel updating a policy attached to a cluster.
In fact, only policy's properties are about to be updated.

Change-Id: Id0560d146539f2807dbab8cc4cb9abb62dcbfe56
Closes-bug: #1524261
2015-12-11 22:57:15 +09:00
Jenkins
55a2b3d722 Merge "Fix pep8 error about D300" 2015-12-11 13:39:01 +00:00
zhangguoqing
0edbcd5cc1 Fix pep8 error about D300
This patch fix the pep8 error D300 about symbol that
D300  Use """triple double quotes""" (found '''-quotes)
when execute run_tests.sh.

Change-Id: I79076b0d2a02eea59a47f263ad6bb30e48c6d1b7
2015-12-09 21:26:55 +08:00
Jenkins
d4fb076b6c Merge "Try to show policy after policy created" 2015-12-09 02:58:49 +00:00
Ethan Lynn
6239b97712 Try to show policy after policy created
Try to show policy after policy created, like what we do after
profile created, so that we can display created_time.

Closes-Bug: #1522324
Change-Id: I85eb5c7335315fb2f0a10b79ceaa4f228e4d7d2d
2015-12-09 19:09:36 +08:00
lvdongbing
bdd003b02a Cluster's timeout is in seconds not minutes
In the help msg of cluster_create and cluster_update, timeout is
described in minutes, but actually it's in seconds, this patch
fixes the issue.

Closes-Bug: #1523791
Change-Id: I8bb1f1da59aad902f2bb5068dc941f09e17cc638
2015-12-08 03:03:50 -05:00
Jenkins
4d99908c36 Merge "Make desired_capacity default to min_size if min_size specified" 2015-12-08 04:19:31 +00:00
lvdongbing
7a00707cbb Make desired_capacity default to min_size if min_size specified
This patch makes desired_capacity default to min_size if min_zize
specified but desired_capacity not when creating cluster, it would
be more friendly to user.

Change-Id: Ie498f128bbd410d116abdf759d65adec0488dcec
2015-12-07 21:55:50 -05:00
Jenkins
9fe5571b7d Merge "Add choices to -F argument" 2015-12-07 09:18:03 +00:00
Ethan Lynn
dd0f6974a2 Add choices to -F argument
Add choices to -F argument

Closes-Bug: #1523373
Change-Id: Ic51004d0afd910d432e18920ad2ee62426b04f5e
2015-12-08 01:02:45 +08:00
Jenkins
114e2af6e5 Merge "Fix profile/policy schema calls" 2015-12-07 09:17:54 +00:00
tengqm
ceebe98a79 Fix profile/policy schema calls
This patch is the client side fix for profile-type-schema and
policy-type-schema.

Depends-On: I61a406ec941f902cb88e4ec521a42af05bb5a93a
Change-Id: I3a932c47b3f72bc256ad49d1994301714e7df398
2015-12-06 23:52:43 -05:00
lvdongbing
d528bf136a Fix nit in the help msg of cluster-node-del
Change-Id: I3a67824b6449ed7f9832c5deee4ebd1b62754e96
2015-12-03 02:26:30 -05:00