Bug 811500 - Massive error massage when create a scalable app while reaching gear limit via REST-API.
Summary: Massive error massage when create a scalable app while reaching gear limit v...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OKD
Classification: Red Hat
Component: Pod
Version: 2.x
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
: ---
Assignee: Abhishek Gupta
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-04-11 09:31 UTC by yquan
Modified: 2015-05-15 01:50 UTC (History)
2 users (show)

Fixed In Version: devenv_1814
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-08 17:59:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description yquan 2012-04-11 09:31:57 UTC
Description of problem:
When trying to create a scalable app while reaching gear limit via REST-API, 
There will be  massive error massage which is annoying

Version-Release number of selected component (if applicable):
devenv_1713

How reproducible:
Always

Steps to Reproduce:
1.Create an domain.
2.Create two non-scalable app
3.Using REST-API Create another scalable app (which will reach gear limit)

Actual results:
Return massive error massages.

Expected results:
The error massages should be friendly. 

Additional info:

Comment 1 Abhishek Gupta 2012-06-04 21:08:24 UTC
Seems like this issue has already been fixed. 



[root@ip-10-72-79-0 ~]# curl -k -u 'agupta:p' -d 'scale=true' -d 'name=app3' -d 'cartridge=php-5.3' https://localhost/broker/rest/domains/agupta110/applications

{"data":null,"version":"1.0","messages":[{"text":"Failed to create application app3 due to:Failed: Either application limit has already reached or domain doesn't exist for 'agupta'","field":null,"severity":"error","exit_code":null}],"supported_api_versions":["1.0"],"type":null,"status":"internal_server_error"}




[root@ip-10-72-79-0 ~]# curl -k -u 'agupta:p' -d 'scale=true' -d 'name=app3' -d 'cartridge=php-5.3' https://localhost/broker/rest/domains/agupta110/applications.xml

<?xml version="1.0" encoding="UTF-8"?>
<response>
  <data>
    <datum nil="true"></datum>
  </data>
  <version>1.0</version>
  <messages>
    <message>
      <text>Failed to create application app3 due to:Failed: Either application limit has already reached or domain doesn't exist for 'agupta'</text>
      <field nil="true"></field>
      <severity>error</severity>
      <exit-code nil="true"></exit-code>
    </message>
  </messages>
  <supported-api-versions>
    <supported-api-version>1.0</supported-api-version>
  </supported-api-versions>
  <status>internal_server_error</status>
  <type nil="true"></type>
</response>

Comment 2 yquan 2012-06-05 05:23:15 UTC
It is fixed on devenv_1815.

Output:


[root@localhost ~]# curl -k -H "Accept: application/xml" --user "yquan:asdfasdf1"  https://ec2-23-22-159-8.compute-1.amazonaws.com/broker/rest/domains/domaintest0005/applications/ -X POST -d name=app3 -d scale=true -d cartridge=php-5.3
<?xml version="1.0" encoding="UTF-8"?>
<response>
  <data>
    <datum nil="true"></datum>
  </data>
  <supported-api-versions>
    <supported-api-version>1.0</supported-api-version>
  </supported-api-versions>
  <version>1.0</version>
  <messages>
    <message>
      <exit-code nil="true"></exit-code>
      <field nil="true"></field>
      <text>Failed to create application app3 due to:Failed: Either application limit has already reached or domain doesn't exist for 'yquan'</text>
      <severity>error</severity>
    </message>
  </messages>
  <status>internal_server_error</status>
  <type nil="true"></type>
</response>


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