Bug 1316749 - It's better to prompt clearly message that test deployment can't be scale up/down
It's better to prompt clearly message that test deployment can't be scale up/...
Status: CLOSED CURRENTRELEASE
Product: OpenShift Origin
Classification: Red Hat
Component: Deployments (Show other bugs)
3.x
Unspecified Unspecified
medium Severity low
: ---
: ---
Assigned To: Michail Kargakis
zhou ying
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-03-10 21:03 EST by zhou ying
Modified: 2016-05-12 13:12 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-05-12 13:12:32 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description zhou ying 2016-03-10 21:03:25 EST
Description of problem:
When try to scale the test DC or RC, the message prompt: deploymentconfig "hooks" scaled, actually the DC or RC didn't scale up. The message should clearly declare that test deployment not support to scale up or scale down.

Version-Release number of selected component (if applicable):
openshift v1.1.3-596-g5ce7a1d
kubernetes v1.2.0-origin-41-g91d3e75
etcd 2.2.5

How reproducible:
Always

Steps to Reproduce:
1. Start OpenShift and login;
2. Use the json to create the test deployment:
[root@ip-172-18-8-237 amd64]# more test.json 
{
    "kind": "DeploymentConfig",
    "apiVersion": "v1",
    "metadata": {
        "name": "hooks",
        "creationTimestamp": null,
        "labels": {
            "name": "mysql"
        }
    },
    "spec": {
        "strategy": {
            "type": "Recreate",
            "recreateParams": {
                "pre": {
                    "failurePolicy": "Retry",
                    "execNewPod": {
                        "command": [
                            "/bin/bash",
                            "-c",
                            "/usr/bin/sleep 10"
                        ],
                        "env": [
                            {
                                "name": "VAR",
                                "value": "pre-deployment"
                            }
                        ],
                        "containerName": "mysql-55-centos7"
                    }
                },
                "post": {
                    "failurePolicy": "Ignore",
                    "execNewPod": {
                        "command": [
                            "/bin/bash",
                            "-c",
                            "/usr/bin/sleep 20"
                        ],
                        "env": [
                            {
                                "name": "VAR",
                                "value": "post-deployment"
                            }
                        ],
                        "containerName": "mysql-55-centos7"
                    }
                }
            },
            "resources": {}
        },
        "triggers": [
            {
                "type": "ConfigChange"
            }
        ],
        "replicas": 1,
        "test": true,
        "selector": {
            "name": "mysql"
        },
        "template": {
            "metadata": {
                "creationTimestamp": null,
                "labels": {
                    "name": "mysql"
                }
            },
            "spec": {
                "containers": [
                    {
                        "name": "mysql-55-centos7",
                        "image": "openshift/mysql-55-centos7:latest",
                        "ports": [
                            {
                                "containerPort": 3306,
                                "protocol": "TCP"
                            }
                        ],
                        "env": [
                            {
                                "name": "MYSQL_USER",
                                "value": "user8Y2"
                            },
                            {
                                "name": "MYSQL_PASSWORD",
                                "value": "Plqe5Wev"
                            },
                            {
                                "name": "MYSQL_DATABASE",
                                "value": "root"
                            }
                        ],
                        "resources": {},
                        "terminationMessagePath": "/dev/termination-log",
                        "imagePullPolicy": "Always",
                        "securityContext": {
                            "capabilities": {},
                            "privileged": false
                        }
                    }
                ],
                "restartPolicy": "Always",
                "dnsPolicy": "ClusterFirst"
            }
        }
    },
    "status": {}
}
3. Wait for the deployment completed, try to scale up the DC.




Actual results:
The 'hooks' deployment not scale up, but the message prompt: deploymentconfig "hooks" created

Expected results:
It's better to prompt clearly message that test deployment can't be scale up/down



Additional info:
Comment 1 openshift-github-bot 2016-03-14 18:03:31 EDT
Commit pushed to master at https://github.com/openshift/origin

https://github.com/openshift/origin/commit/919dcabcfdc0198e66cb3b05cc887c9dbc4bd71e
Bug 1316749: prompt warning when scaling test deployments
Comment 2 zhou ying 2016-03-17 04:35:42 EDT
Confirmed on ami devenv_rhel_3734, When scale dc ,can prompt the message, but when scale rc, the scale doesn't no work,
 but still has message:
[root@ip-172-18-11-61 amd64]# oc scale rc hooks-1 --replicas=4
replicationcontroller "hooks-1" scaled
[root@ip-172-18-11-61 amd64]# oc get pods
[root@ip-172-18-11-61 amd64]# oc get rc
CONTROLLER   CONTAINER(S)       IMAGE(S)                            SELECTOR                                               REPLICAS   AGE
hooks-1      mysql-55-centos7   openshift/mysql-55-centos7:latest   deployment=hooks-1,deploymentconfig=hooks,name=mysql   0          2m
[root@ip-172-18-11-61 amd64]# oc get dc
NAME      REVISION   REPLICAS          TRIGGERED BY
hooks     1          3 (during test)   config
Comment 3 Michail Kargakis 2016-03-17 06:29:44 EDT
You shouldn't need to scale a rc for a dc. Everything should flow through the dc. I consider this bug fixed, if you want to have a warning for rcs open a different bug but it's not going to be fixed for this release. Also lower priority.
Comment 4 zhou ying 2016-03-18 01:51:06 EDT
ok, then will verify ,thanks.

Note You need to log in before you can comment on or make changes to this bug.