Bug 838862

Summary: add events to application dose not check the domain name in the URL via REST api
Product: OKD Reporter: Meng Bo <bmeng>
Component: MasterAssignee: Lili Nader <lnader>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 2.xCC: mfisher, rmillner
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-07-13 23:43:15 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Meng Bo 2012-07-10 10:18:29 UTC
Description of problem:
Using REST api to add events to application, whatever the domain name is, it will add the event successfully.

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

How reproducible:
always

Steps to Reproduce:
1.create a domain.
# rhc domain create -n bmengdev
2.create an app.
3.add event to this app via rest api where the domain name is non-exist one.
# curl -k -H 'Accept: application/xml' --user bmeng:123123 https://localhost/broker/rest/domains/whateverhere/applications/ruby19/events/ -XPOST -d event=remove-alias -d alias=test.com
  
Actual results:
the event can be added to the app successfully.

Expected results:
it should return error message like, "domain does not exist"

Additional info:

Comment 1 Meng Bo 2012-07-11 06:16:57 UTC
Seems the change does not merge into devenv_1884, will check it in the next build.

Comment 2 Meng Bo 2012-07-12 08:15:25 UTC
Checked on devenv-stage_233, this issue has been fixed.

It returns "Domain not found" for a wrong domain name when adding events to application.