openstackgerrit | Qiming Teng proposed openstack/senlin: Fix receiver test case to make it stable https://review.openstack.org/268782 | 00:17 |
---|---|---|
*** xuhaiwei has joined #senlin | 00:28 | |
*** Yanyanhu has joined #senlin | 01:47 | |
openstackgerrit | Qiming Teng proposed openstack/senlin: Fix zone test case to make it stable https://review.openstack.org/268781 | 02:00 |
*** yuanying has quit IRC | 02:04 | |
*** elynn has joined #senlin | 02:05 | |
*** yuanying has joined #senlin | 02:05 | |
openstackgerrit | Qiming Teng proposed openstack/senlin: Fix receiver test case to make it stable https://review.openstack.org/268782 | 02:06 |
*** Qiming has joined #senlin | 02:06 | |
*** elynn_ has joined #senlin | 02:12 | |
*** elynn has quit IRC | 02:12 | |
openstackgerrit | Qiming Teng proposed openstack/senlin: Unit test for base profile https://review.openstack.org/268752 | 02:14 |
Qiming | lixinhui, thanks for reviewing/approving https://review.openstack.org/268781 | 02:27 |
openstackgerrit | Merged openstack/senlin: Unit test for base profile https://review.openstack.org/268752 | 02:27 |
Qiming | however, that patch depends on https://review.openstack.org/268752 | 02:27 |
Qiming | and it is depended by https://review.openstack.org/268782 | 02:28 |
lixinhui | Qiming, I found it and just pass it | 02:28 |
Qiming | there is a critical error I want to discuss with you | 02:28 |
lixinhui | please | 02:28 |
Qiming | check this patch: https://review.openstack.org/#/c/268752/ | 02:29 |
Qiming | it took me a **long** time to find out the issue | 02:29 |
Qiming | the problem turns out to be in a test case here: https://review.openstack.org/#/c/268752/13/senlin/tests/unit/policies/test_vSphereDRSPolicy.py | 02:29 |
Qiming | in 'test_attach_with_profile_info()' method | 02:30 |
Qiming | the first line is replacing the 'load' method of the Profile class, this is becoming permanent | 02:31 |
Qiming | it is not the right way to mock a method call | 02:31 |
Qiming | it is REPLACING the method call with a mock | 02:32 |
Qiming | the difference is a little bit subtle | 02:33 |
lixinhui | okay, we need to induce load testing | 02:35 |
lixinhui | instead of direct asisignment of profile id | 02:35 |
Qiming | well, the lesson learnt is | 02:35 |
Qiming | don't change the behavior of a class method in that way | 02:36 |
Qiming | it is okay to use mock.patch.object annotation | 02:36 |
Qiming | it is also okay to do self.patchobject() | 02:36 |
Qiming | because testtools will take care of the temporary behavior change | 02:36 |
Qiming | the line 'profile_base.Profile.load = mock.Mock()' is not a mock operation, it is permanently changing the class behavior | 02:37 |
lixinhui | you mean, not only the return value is used, but some temporary change will cause the test failure | 02:37 |
lixinhui | okay | 02:38 |
Qiming | I mean don't do direct assignment on a method, do a mock patch | 02:38 |
Qiming | it will forever change the behavior of the class | 02:38 |
lixinhui | I see | 02:39 |
Qiming | so when other tests are executed after this one, they will get wrong behavior | 02:39 |
Qiming | it is still fine to do something like this: | 02:40 |
Qiming | obj = mock.Mock() | 02:40 |
Qiming | obj.get_hypervisors = mock.Mock(return_value=something) | 02:40 |
Qiming | because in the two lines above, you are changing the behavior of a mocked object | 02:41 |
lixinhui | but load is a behaviour | 02:43 |
Qiming | yes | 02:43 |
Qiming | it is a behavior you want to mock | 02:43 |
lixinhui | so once we made assgi ment, the class behaviour will change forever | 02:43 |
Qiming | yes | 02:43 |
lixinhui | ot it | 02:44 |
lixinhui | got it | 02:44 |
lixinhui | Thanks, Qiming | 02:44 |
*** yuanying has quit IRC | 03:00 | |
openstackgerrit | Qiming Teng proposed openstack/senlin: Fix zone test case to make it stable https://review.openstack.org/268781 | 03:00 |
*** yuanying has joined #senlin | 03:01 | |
Qiming | gate is stalling due to dependencies | 03:01 |
Qiming | elynn_, there? | 03:02 |
Qiming | helps needed on reviewing this: https://review.openstack.org/#/c/268563/ | 03:06 |
Qiming | it is needed by https://review.openstack.org/268782 | 03:07 |
openstackgerrit | Merged openstack/senlin: Fix zone test case to make it stable https://review.openstack.org/268781 | 03:15 |
*** yuanying has quit IRC | 03:20 | |
elynn_ | Hi Qiming | 03:20 |
Qiming | hi, elynn_ | 03:20 |
elynn_ | looking ~ | 03:20 |
Qiming | about making 'senlin-api' and 'senlin-engine' a console script entry point | 03:20 |
Qiming | https://review.openstack.org/#/c/267375/1 | 03:20 |
Qiming | https://review.openstack.org/#/c/267376/1 | 03:21 |
elynn_ | yes | 03:21 |
Qiming | can you help check the reason behind the changes? | 03:21 |
Qiming | I know that some other projects are doing this | 03:21 |
Qiming | but we should know why this is recommended | 03:22 |
elynn_ | Maybe because pbr can handle it better? Let me check. | 03:22 |
Qiming | great | 03:22 |
Qiming | it looks like a tradeoff | 03:23 |
elynn_ | Why do you think so? | 03:23 |
Qiming | keeping service 'binaries' under 'bin' looks more intuitive | 03:23 |
Qiming | however, when service is installed | 03:23 |
Qiming | for example, using devstack | 03:23 |
Qiming | we are getting some 'binaries' under /usr/bin | 03:24 |
Qiming | those new binaries are pointing to the scripts we have under senlin/bin | 03:24 |
Qiming | if that is always the practice, then we can safely remove the senlin/bin directory | 03:25 |
Qiming | and even the monkey patch thing in those scripts | 03:25 |
Qiming | just curious if this is the right direction to go | 03:25 |
elynn_ | I think it is, but I don't know why, let me google it :) | 03:27 |
Qiming | we are already hitting mitaka 2 milestone: http://docs.openstack.org/releases/schedules/mitaka.html | 03:27 |
Qiming | if it is the RIGHT thing to do, maybe we should get it in NOW | 03:27 |
openstackgerrit | Merged openstack/senlin: Add unit tests for receiver in engine https://review.openstack.org/268563 | 03:28 |
elynn_ | Heat also add deprecation warning to binaries in bin/, so eventually bin will be removed. | 03:29 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Fix receiver test case to make it stable https://review.openstack.org/268782 | 03:29 |
Qiming | okay? | 03:29 |
Qiming | one thing I'd like to advocate across the team is that we don't do things simple because other projects are doing that | 03:30 |
Qiming | we do the right things | 03:30 |
Qiming | so if we are making some changes, we'd better know the reason, :) | 03:30 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Fix receiver params string generation https://review.openstack.org/268782 | 03:32 |
elynn_ | yes, agree | 03:32 |
*** dixiaoli has joined #senlin | 03:34 | |
openstackgerrit | Liuqing Jing proposed openstack/senlin: Ensure that jsonutils.%(fun)s must be used instead of json.%(fun)s https://review.openstack.org/262646 | 03:35 |
openstackgerrit | Merged openstack/senlin: Fix receiver params string generation https://review.openstack.org/268782 | 03:41 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Update text strings https://review.openstack.org/268853 | 03:42 |
openstackgerrit | Liuqing Jing proposed openstack/senlin: Ensure that jsonutils.%(fun)s must be used instead of json.%(fun)s https://review.openstack.org/262646 | 03:49 |
elynn_ | Hi Qiming, I don't find much evidence that we must move bin/ to console_scripts, but moving to console_scripts can take the advantage of setuptools and help us to avoid much errors according to https://review.openstack.org/#/c/190304/ . | 03:52 |
*** Liuqing has joined #senlin | 03:54 | |
elynn_ | And we can also define wsgi_scripts in [entry_points] later if we want. | 04:02 |
*** yuanying has joined #senlin | 04:06 | |
elynn_ | Some more info can be found here. http://docs.openstack.org/developer/pbr/#entry-points . Using pbr to handle console_scripts is more easy. | 04:06 |
*** elynn_ has quit IRC | 04:20 | |
Liuqing | Hello, when i run `senlin profile-list`, the client raise error `AttributeError: 'Proxy' object has no attribute 'profiles'` | 04:41 |
Liuqing | LOG is here : AttributeError: 'Proxy' object has no attribute 'profiles' | 04:41 |
Liuqing | when i run another cmd `senlin cluster-list`, it raise `senlinclient.common.exc.HTTPInternalServerError: ERROR(500): 'Session' object has no attribute 'get_token'` | 04:42 |
Qiming | Liuqing, your openstack version is too old | 04:43 |
Qiming | please use master | 04:43 |
Liuqing | you mean openstack sdk ? | 04:44 |
Qiming | yes | 04:44 |
Liuqing | ok | 04:44 |
Qiming | git clone it | 04:44 |
Qiming | then do a git install -e . | 04:44 |
Qiming | sorry, 'sudo pip install -e .' | 04:45 |
*** elynn_ has joined #senlin | 04:45 | |
Liuqing | OK, thanks | 04:45 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Revise version json format https://review.openstack.org/268862 | 04:54 |
Qiming | elynn_, checked the links | 05:00 |
Qiming | let's go deprecate the bin dir | 05:01 |
Qiming | and we can remove the monkey patching logic lines then | 05:01 |
elynn_ | ok, I will submit a patch to deprecate it at last. | 05:01 |
elynn_ | ok, let me modify my patches and leave monkey to last patch. | 05:02 |
openstackgerrit | Merged openstack/senlin: Ensure that jsonutils.%(fun)s must be used instead of json.%(fun)s https://review.openstack.org/262646 | 05:09 |
Qiming | ok | 05:10 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Move app controller into dedicated module https://review.openstack.org/268869 | 05:23 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Add version controller for V1 API https://review.openstack.org/268874 | 05:54 |
openstackgerrit | Merged openstack/senlin: Move app controller into dedicated module https://review.openstack.org/268869 | 06:01 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Add version controller for V1 API https://review.openstack.org/268874 | 06:40 |
openstackgerrit | Yanyan Hu proposed openstack/senlin: Fix a bug in profile base module https://review.openstack.org/268895 | 06:40 |
openstackgerrit | Yanyan Hu proposed openstack/senlin: Fix a bug in profile base module https://review.openstack.org/268895 | 06:44 |
*** Qiming has quit IRC | 07:00 | |
*** Qiming_ has joined #senlin | 07:00 | |
openstackgerrit | Merged openstack/senlin: Fix a bug in profile base module https://review.openstack.org/268895 | 07:01 |
openstackgerrit | Merged openstack/senlin: Add version controller for V1 API https://review.openstack.org/268874 | 07:14 |
openstackgerrit | Liuqing Jing proposed openstack/python-senlinclient: The param endpoint in doc string is deprecated https://review.openstack.org/268903 | 07:29 |
*** elynn_ has quit IRC | 07:35 | |
*** Qiming_ has quit IRC | 07:36 | |
*** elynn_ has joined #senlin | 07:37 | |
*** Qiming has joined #senlin | 07:42 | |
openstackgerrit | Qiming Teng proposed openstack/python-senlinclient: Unit test for v1 client https://review.openstack.org/268912 | 08:03 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Remove purge_deleted from senlin-manage https://review.openstack.org/268915 | 08:08 |
openstackgerrit | Qiming Teng proposed openstack/senlin: Add 'cooldown' for scaling policy https://review.openstack.org/268918 | 08:15 |
lixinhui | Qiming | 08:48 |
lixinhui | there? | 08:48 |
Qiming | yes | 08:48 |
lixinhui | The action in node_check should be check real status of node and set the DB? | 08:48 |
Qiming | yes | 08:48 |
lixinhui | okay | 08:49 |
Qiming | it will be left to users whether they want a recovery or not | 08:49 |
lixinhui | okay, once user call cluster-recover, we will help to recover all ndoes of status "ERROR" | 08:50 |
lixinhui | right? | 08:50 |
Qiming | yes | 08:50 |
lixinhui | okay, thanks. | 08:50 |
Qiming | hi, cores | 08:57 |
Qiming | please help review https://review.openstack.org/#/c/268912 ? | 08:57 |
Qiming | need it to fix get_node with details | 08:58 |
Qiming | thx | 08:58 |
Yanyanhu | got it | 08:58 |
elynn_ | +2 ;) | 08:59 |
Yanyanhu | this is a patch in client side? | 08:59 |
Qiming | yip | 08:59 |
Yanyanhu | ok | 09:00 |
xuhaiwei | just reviewing it | 09:00 |
Qiming | :) | 09:03 |
openstackgerrit | Merged openstack/python-senlinclient: Unit test for v1 client https://review.openstack.org/268912 | 09:04 |
Yanyanhu | hi, Qiming, just registered a bp for reworking action data transmission logic, e.g. the usage of action.data, action.input and action.output | 09:13 |
Yanyanhu | https://blueprints.launchpad.net/senlin/+spec/rework-data-transmission-in-action-execution | 09:13 |
Yanyanhu | still not very clear about some places, e.g. how to treat those builtin policies, considering them as part of action execution or treat them as customized policies | 09:15 |
openstackgerrit | Qiming Teng proposed openstack/python-senlinclient: Add back show_details for node-show https://review.openstack.org/268938 | 09:16 |
Qiming | sigh ... | 09:16 |
Yanyanhu | this is not a emergent work, just think the current action data transmission logic is still confusing when I worked on bp of policy check reworking | 09:17 |
Qiming | we won't get a chance to land everything before mitaka-3 | 09:17 |
Yanyanhu | hmm, we don't have to finish this job in Mitaka cycle I think | 09:17 |
Qiming | since we are getting ride of priroity too early | 09:17 |
Qiming | policy checking becomes a big problem now | 09:18 |
Qiming | even if we rework all cluster actions and node actions to do hard-coded policy checking, as you are experimenting with LB policy | 09:18 |
Qiming | we will still need to refactor the cluster_actions module to make it clear | 09:19 |
Yanyanhu | yes, do need some thinking about this issue I think | 09:19 |
Qiming | with more and more checkings being added to the module, the code is becoming very complex | 09:19 |
Yanyanhu | right, maybe we shouldn't just hard code those builtin check to address current issues | 09:20 |
Qiming | one way of simplifying this would be to add subclasses of cluster actions | 09:20 |
Qiming | each action is split into an individual class | 09:20 |
Qiming | then we focus on each action, making sure each action is doing exactly what it should do, including the policy checks and action logic itself | 09:20 |
Yanyanhu | so you mean each action class has its own policy_check logic | 09:22 |
Qiming | yes | 09:22 |
Qiming | that would be an action-centric view | 09:22 |
Qiming | currently we are working on a policy-centric view | 09:22 |
Yanyanhu | let me see | 09:22 |
Yanyanhu | yes, that's the point | 09:22 |
Qiming | i.e. for each policy, which action should be handled, how to handle it | 09:23 |
Qiming | action-centric view would be dirty, there would be a lot of duplication of code, but it is much much more easier to understand and maintain | 09:24 |
Yanyanhu | yes, it is | 09:24 |
Qiming | this is the root difference between haiwei and me about handling deletion across regions | 09:24 |
Yanyanhu | just worried there will be lots of duplicated code logic | 09:25 |
Qiming | action centric view would be difficult to document as well | 09:25 |
Qiming | for each action, we have to document which policy would be checked and how | 09:25 |
Yanyanhu | right | 09:25 |
Yanyanhu | need to think about this issue thoroughly | 09:25 |
Qiming | yes | 09:26 |
Qiming | before doing that | 09:26 |
Yanyanhu | understand | 09:26 |
Qiming | let's think about what we can accomplish in THIS WEEK | 09:26 |
Qiming | can we release something usable? | 09:26 |
Yanyanhu | actually I'm now very hesitated to do the work about rework-built-in policy bp | 09:26 |
Yanyanhu | sorry, rework builtin policy check bp | 09:26 |
Qiming | yes, it is very dirty | 09:27 |
Yanyanhu | yes, it is | 09:27 |
Qiming | a compromise would be this | 09:27 |
Qiming | stick to the original design | 09:27 |
Qiming | assign each "builtin" policy a hard-coded priority | 09:28 |
Qiming | LB policy is an exception, it needs to be checked at both ends | 09:28 |
Yanyanhu | ok, maybe this is an acceptable interim solution for the first release | 09:29 |
Qiming | and we can make that an exception because 'priority' or 'precedence' is an implementation detail now | 09:29 |
Yanyanhu | yes | 09:29 |
Qiming | I'm not that optimistic that we can rework all those actions for hard-coded policies | 09:30 |
Qiming | I'm even not sure that is the right thing | 09:30 |
Yanyanhu | I see. | 09:30 |
Qiming | inside senlin-engine | 09:30 |
Qiming | we can have scaling-policy carry a built in priority of 100, placement policy 200, lb policy 300 | 09:31 |
Yanyanhu | ok, let me try to use hard-code priority to address lb_policy's issue before this friday | 09:31 |
Yanyanhu | then we rethink out policy design | 09:31 |
Yanyanhu | before starting any further refactoring | 09:31 |
Qiming | agreed | 09:31 |
Yanyanhu | ok, will work following this way | 09:32 |
Qiming | I was reading the cluster_actions module this afternoon, between occasional patches here and there | 09:33 |
Qiming | there is no clean way to get the things right quickly | 09:34 |
Yanyanhu | understand | 09:34 |
Qiming | maybe we should spend some time together tomorrow, to work out a plan on this | 09:43 |
Yanyanhu | sure, that's also what I'm thinking | 09:44 |
Qiming | 10:00-11:30 ? | 09:45 |
Yanyanhu | ok | 09:45 |
Qiming | we can continue during lunch and coffee time if our brains can last that long | 09:45 |
Yanyanhu | sure :) | 09:45 |
*** Qiming has quit IRC | 10:04 | |
*** Yanyanhu has quit IRC | 10:04 | |
*** elynn__ has joined #senlin | 10:36 | |
*** elynn_ has quit IRC | 10:36 | |
*** elynn__ has quit IRC | 10:51 | |
*** Qiming has joined #senlin | 11:30 | |
*** dixiaoli has quit IRC | 13:16 | |
*** elynn__ has joined #senlin | 13:35 | |
*** gongysh has joined #senlin | 13:37 | |
openstackgerrit | Liuqing Jing proposed openstack/senlin: Method's default argument shouldn't be mutable https://review.openstack.org/269053 | 13:49 |
*** Liuqing has quit IRC | 13:54 | |
*** gongysh has quit IRC | 14:48 | |
*** elynn__ has quit IRC | 14:53 | |
*** Qiming has quit IRC | 15:09 | |
*** elynn has joined #senlin | 15:53 | |
*** elynn has quit IRC | 15:54 | |
*** jdandrea has quit IRC | 16:12 | |
*** zhenguo has joined #senlin | 16:48 | |
-openstackstatus- NOTICE: Gerrit is restarting quickly as a workaround for performance degradation | 16:50 | |
*** pratikma_ has joined #senlin | 16:54 | |
*** pratikma_ has quit IRC | 17:57 | |
*** pratikmallya has joined #senlin | 19:05 | |
*** pratikmallya has quit IRC | 21:32 | |
*** pratikmallya has joined #senlin | 21:54 | |
*** Qiming has joined #senlin | 23:41 | |
*** pratikmallya has quit IRC | 23:43 | |
*** yuanying has quit IRC | 23:54 | |
*** yuanying has joined #senlin | 23:56 |
Generated by irclog2html.py 2.14.0 by Marius Gedminas - find it at mg.pov.lt!