Description of problem: After stopping idled app, the app still can be accessed. Version-Release number of selected component (if applicable): devenv_4890 How reproducible: always Steps to Reproduce: 1. Create an app rhc app create crb9 ruby-1.9 --no-git 2. SSH into instance and idle the app oo-admin-ctl-gears idlegear UUID 3. Stop the idled app and check the app state rhc app stop crb9 rhc app show crb9 --state 4. Access the app via browser 5. Check the status of app rhc app show crb9 --state Actual results: at step 3: Cartridge ruby-1.9 is stopped at step 4: the app can be accessed at step 5: Cartridge ruby-1.9 is started Expected results: Should stop idled app successfully Additional info:
it also can be reproduced for "oo-admin-ctl-gears stopgear" command.
Checked on devenv_stage_883, it's reproduced. we missed the scenario before, QE will add cases to cover it.
Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/26053a96424c25b331a135fee4c5424fbbc4c49f Bug 1111077 - Ensure frontend and state in sync * When stopping an idled application update http frontend configuration
Checked on devenv_4909, the issue is not fixed. I find below cases: 1. When trying to stop the idled app, the app will be started, and the app can be accessed; 2. Trying to stop idled app, will take many time about 2 minutes since less 15 seconds for stopping a started app. Please refer to the following results: 1. Create an app rhc app create cpl2 perl-5.10 --no-git 2. SSH into instance and idle the app oo-admin-ctl-gears idlegear UUID 3. Stop the idled app and check the app state 1) time rhc app stop cpl2 2) rhc app show cpl2 --state 4. Access the app via browser Results: at step 3: 1) RESULT: cpl2 stopped real 1m53.669s user 0m0.710s sys 0m0.062s 2) Cartridge perl-5.10 is started at step 4: the app can be accessed.
Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/bfad149a7bf3625a03fc23c4a50ef1a18efeb9c5 Revert "Bug 1111077 - Ensure frontend and state in sync"
Fixed in https://github.com/openshift/origin-server/pull/5561 Because of a design flaw, this condition cannot be prevented. Rather GearStatePlugin of Watchman has been enhanced to set the Http Front Server server to honor the .state file.
Commits pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/d3834dff3f59cafac545abb5f02982f82c3ce1a7 Bug 1111077 - Enforce FrontendHttpServer state to match .state file * Update GearStatePlugin to enforce stopped state on Frontend Http Server configuration https://github.com/openshift/origin-server/commit/8f1389d6ccb843783d263af1817768a1db05feba Bug 1111077 - Enforce FrontendHttpServer state to match .state file * Update tests
All issues have been fixed, verified on devenv_4925, please refer to the following results: 1. Create an app rhc app create cpl2 perl-5.10 --no-git 2. SSH into instance and idle the app oo-admin-ctl-gears idlegear UUID 3. Stop the idled app and check the app state 1) time rhc app stop cpl2 2) rhc app show cpl2 --state 4. Access the app via browser Results: at step 3: 1) RESULT: cpl2 stopped real 0m5.006s user 0m0.703s sys 0m0.052s 2) Cartridge perl-5.10 is stopped at step 4: the app can NOT be accessed and get 503 page.