Bug 1625161 - apb provision failed in project which named by pure number
Summary: apb provision failed in project which named by pure number
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Service Broker
Version: 3.11.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 3.11.0
Assignee: Dylan Murray
QA Contact: Zihan Tang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-09-04 09:47 UTC by Zihan Tang
Modified: 2018-10-11 07:26 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-11 07:25:55 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:2652 0 None None None 2018-10-11 07:26:13 UTC

Description Zihan Tang 2018-09-04 09:47:58 UTC
Description of problem:
when provision in a pure number named project, provison failed as 'Bad Request'

TASK [mysql-apb : Set mysql objects state=present] *****************************
failed: [localhost] (item={u'name': u'service.yaml.j2'}) => {"changed": false, "error": 400, "item": {"name": "service.yaml.j2"}, "msg": "Failed to create object: {\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"Service in version \\\"v1\\\" cannot be handled as a Service: v1.Service.ObjectMeta: v1.ObjectMeta.Namespace: ReadString: expects \\\" or n, but found 7, error found in #10 byte of ...|espace\\\": 7879, \\\"name|..., bigger context ...|a663-b025-11e8-b30c-0a580a800006\\\"}, \\\"namespace\\\": 7879, \\\"name\\\": \\\"mysql-67e3a663-b025-11e8-b30c-0a580a|...\",\"reason\":\"BadRequest\",\"code\":400}\n", "reason": "Bad Request", "status": 400}
skipping: [localhost] => (item={u'apply': False, u'name': u'pvc.yaml.j2'

But provision in project like '50p-r' will succeed.


Version-Release number of selected component (if applicable):
asb: 1.3.14
postgresql-apb: v3.11.0-0.25.0.0
mariadb-apb: v3.11.0-0.25.0.0

openshift v3.11.0-0.25.0

How reproducible:
always

Steps to Reproduce:
1. provision postgresql-apb in project 3423
2.
3.

Actual results:
provision failed , logs in sandbox:
postgresql-apb:
TASK [postgresql-apb : Set postgresql objects state=present] *******************
failed: [localhost] (item={u'name': u'service.yaml.j2'}) => {"changed": false, "error": 400, "item": {"name": "service.yaml.j2"}, "msg": "Failed to create object: {\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"Service in version \\\"v1\\\" cannot be handled as a Service: v1.Service.ObjectMeta: v1.ObjectMeta.Namespace: ReadString: expects \\\" or n, but found 3, error found in #10 byte of ...|espace\\\": 3423, \\\"name|..., bigger context ...|739c-b024-11e8-b30c-0a580a800006\\\"}, \\\"namespace\\\": 3423, \\\"name\\\": \\\"postgresql-3b33739c-b024-11e8-b30c-0|...\",\"reason\":\"BadRequest\",\"code\":400}\n", "reason": "Bad Request", "status": 400}
failed: [localhost] (item={u'apply': True, u'name': u'pvc.yaml.j2'}) => {"changed": false, "error": 400, "item": {"apply": true, "name": "pvc.yaml.j2"}, "msg": "Failed to create object: {\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"PersistentVolumeClaim in version \\\"v1\\\" cannot be handled as a PersistentVolumeClaim: v1.PersistentVolumeClaim.ObjectMeta: v1.ObjectMeta.Namespace: ReadString: expects \\\" or n, but found 3, error found in #10 byte of ...|espace\\\": 3423, \\\"name|..., bigger context ...|}, \\\"apiVersion\\\": \\\"v1\\\", \\\"metadata\\\": {\\\"namespace\\\": 3423, \\\"name\\\": \\\"postgresql-3b33739c-b024-11e8-b30c-0|...\",\"reason\":\"BadRequest\",\"code\":400}\n", "reason": "Bad Request", "status": 400}
failed: [localhost] (item={u'name': u'deployment.yaml.j2'}) => {"changed": false, "error": 400, "item": {"name": "deployment.yaml.j2"}, "msg": "Failed to create object: {\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"DeploymentConfig in version \\\"v1\\\" cannot be handled as a DeploymentConfig: v1.DeploymentConfig.ObjectMeta: v1.ObjectMeta.Namespace: ReadString: expects \\\" or n, but found 3, error found in #10 byte of ...|espace\\\": 3423, \\\"name|..., bigger context ...|739c-b024-11e8-b30c-0a580a800006\\\"}, \\\"namespace\\\": 3423, \\\"name\\\": \\\"postgresql-3b33739c-b024-11e8-b30c-0|...\",\"reason\":\"BadRequest\",\"code\":400}\n", "reason": "Bad Request", "status": 400}

Expected results:
provision succeed.

Additional info:

mysql-apb provision failed log: 

TASK [mysql-apb : Set mysql objects state=present] *****************************
failed: [localhost] (item={u'name': u'service.yaml.j2'}) => {"changed": false, "error": 400, "item": {"name": "service.yaml.j2"}, "msg": "Failed to create object: {\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"Service in version \\\"v1\\\" cannot be handled as a Service: v1.Service.ObjectMeta: v1.ObjectMeta.Namespace: ReadString: expects \\\" or n, but found 7, error found in #10 byte of ...|espace\\\": 7879, \\\"name|..., bigger context ...|a663-b025-11e8-b30c-0a580a800006\\\"}, \\\"namespace\\\": 7879, \\\"name\\\": \\\"mysql-67e3a663-b025-11e8-b30c-0a580a|...\",\"reason\":\"BadRequest\",\"code\":400}\n", "reason": "Bad Request", "status": 400}
skipping: [localhost] => (item={u'apply': False, u'name': u'pvc.yaml.j2'}) 

failed: [localhost] (item={u'name': u'deployment.yaml.j2'}) => {"changed": false, "error": 400, "item": {"name": "deployment.yaml.j2"}, "msg": "Failed to create object: {\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"DeploymentConfig in version \\\"v1\\\" cannot be handled as a DeploymentConfig: v1.DeploymentConfig.ObjectMeta: v1.ObjectMeta.Namespace: ReadString: expects \\\" or n, but found 7, error found in #10 byte of ...|espace\\\": 7879, \\\"name|..., bigger context ...|a663-b025-11e8-b30c-0a580a800006\\\"}, \\\"namespace\\\": 7879, \\\"name\\\": \\\"mysql-67e3a663-b025-11e8-b30c-0a580a|...\",\"reason\":\"BadRequest\",\"code\":400}\n", "reason": "Bad Request", "status": 400}

Comment 3 Zihan Tang 2018-09-07 08:44:51 UTC
Verified
*-apb: v3.11.0-0.28.0

Comment 5 errata-xmlrpc 2018-10-11 07:25:55 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:2652


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