Actions
Bug #3515
closedAssociated resources not found by ID causes 500 Internal Server Error
Description
Description of problem:
making call of hammer cli:
`hammer --output base subnet create --name "allparams" --network "251.10.10.11" --mask "255.255.255.0" --gateway "251.10.10.255" --dns-primary "251.10.11.255" --dns-secondary "251.10.12.255" --from "251.10.10.10" --to "251.10.10.12" --vlanid "2" --domain-ids "1"` just fails with: === Could not create the subnet: Error: 500 Internal Server Error
Actual results:
500 - ISE
Expected results:
no exception. subnet needs to be created. Even if there is any error: proper message should be returned back.
Foreman production.log:
Started POST "/foreman/api/subnets" for 127.0.0.1 at 2013-10-25 06:23:19 -0400 Processing by Api::V1::SubnetsController#create as JSON Parameters: {"subnet"=>{"dns_secondary"=>"251.10.12.255", "network"=>"251.10.10.11", "from"=>"251.10.10.10", "mask"=>"255.255.255.0", "vlanid"=>"2", "to"=>"251.10.10.12", "domain_ids"=>["1"], "gateway"=>"251.10.10.255", "dns_primary"=>"251.10.11.255", "name"=>"allparams"}} Authorized user admin(Admin User) Couldn't find Domain with id=1 (ActiveRecord::RecordNotFound)
Actions