{"action":"created","issue":{"url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource/issues/20","repository_url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource","labels_url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource/issues/20/labels{/name}","comments_url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource/issues/20/comments","events_url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource/issues/20/events","html_url":"https://github.com/patrickcrocker/cf-cli-resource/issues/20","id":297916577,"number":20,"title":"create-user-provided-service failing when creating a service of the same name in different spaces within a single org","user":{"login":"gm2552","id":904770,"avatar_url":"https://avatars1.githubusercontent.com/u/904770?v=4","gravatar_id":"","url":"https://api.github.com/users/gm2552","html_url":"https://github.com/gm2552","followers_url":"https://api.github.com/users/gm2552/followers","following_url":"https://api.github.com/users/gm2552/following{/other_user}","gists_url":"https://api.github.com/users/gm2552/gists{/gist_id}","starred_url":"https://api.github.com/users/gm2552/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gm2552/subscriptions","organizations_url":"https://api.github.com/users/gm2552/orgs","repos_url":"https://api.github.com/users/gm2552/repos","events_url":"https://api.github.com/users/gm2552/events{/privacy}","received_events_url":"https://api.github.com/users/gm2552/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-02-16T20:53:14Z","updated_at":"2018-02-23T12:41:39Z","closed_at":null,"author_association":"NONE","body":"I have 2 spaces (staging and prod) within a single organization: \r\n\r\nMy pipeline creates a user defined service in each of these spaces using the same service name in each space.  The service is created without issue in the first space, but fails when creating the service in the second space stating that a service with the same name already exists.  I have verified that the service does not exist in the second space, and the correct space name is being used when creating the service in the second space.  NOTE: it may not matter, but the services are created in 2 separated jobs within the pipeline.\r\n\r\n**Staging Space**\r\n_[INFO] Executing create-user-provided-service: luna\r\napi endpoint:   https://api.sys.prod.us-west-2.cernercf.io\r\napi version:    2.98.0\r\nuser:          <redacted>\r\norg:            CernerDirect\r\nspace:          staging\r\nCreating user provided service luna in org CernerDirect / space staging as cernerdirect-bot...\r\nOK_\r\n\r\n**Prod Space**\r\n_[INFO] Executing create-user-provided-service: luna\r\napi endpoint:   https://api.sys.prod.us-west-2.cernercf.io\r\napi version:    2.98.0\r\nuser:           <redacted>\r\norg:            CernerDirect\r\nspace:          prod\r\n[INFO] Service luna already exists_\r\n\r\nThis can be easily reproduced by creating 2 spaces in an org and attempting to create a user defined service of the same name in the two different spaces."},"comment":{"url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource/issues/comments/367998982","html_url":"https://github.com/patrickcrocker/cf-cli-resource/issues/20#issuecomment-367998982","issue_url":"https://api.github.com/repos/patrickcrocker/cf-cli-resource/issues/20","id":367998982,"user":{"login":"gm2552","id":904770,"avatar_url":"https://avatars1.githubusercontent.com/u/904770?v=4","gravatar_id":"","url":"https://api.github.com/users/gm2552","html_url":"https://github.com/gm2552","followers_url":"https://api.github.com/users/gm2552/followers","following_url":"https://api.github.com/users/gm2552/following{/other_user}","gists_url":"https://api.github.com/users/gm2552/gists{/gist_id}","starred_url":"https://api.github.com/users/gm2552/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gm2552/subscriptions","organizations_url":"https://api.github.com/users/gm2552/orgs","repos_url":"https://api.github.com/users/gm2552/repos","events_url":"https://api.github.com/users/gm2552/events{/privacy}","received_events_url":"https://api.github.com/users/gm2552/received_events","type":"User","site_admin":false},"created_at":"2018-02-23T12:41:39Z","updated_at":"2018-02-23T12:41:39Z","author_association":"NONE","body":"Let me know if you need more:\r\n---------------------------------\r\n\r\nresource_types:\r\n\r\n- name: cf-cli-resource\r\n  type: docker-image\r\n  source:\r\n    repository: pivotalpa/cf-cli-resource\r\n    tag: latest\r\n\r\nresources: \r\n.\r\n.\r\n.\r\n# PCF resource for performing tasks in dev cloud foundry instance\r\n- name: cf-cli-prod\r\n  type: cf-cli-resource\r\n  source: \r\n    api: ((cf-prod-api))\r\n    username: ((cf-prod-username))\r\n    password: ((cf-prod-password))\r\n    skip_cert_check: true  \r\n.\r\n.\r\n.\r\njobs:\r\n                                         \r\n- name: pave-staging-space\r\n  build_logs_to_retain: 10\r\n  plan:       \r\n    - put: create-staging-services\r\n      resource: cf-cli-prod\r\n      params:\r\n         commands:  \r\n         - command: create-user-provided-service\r\n           org: ((cf-org)) \r\n           space: ((cf-space-staging))    \r\n           credentials: ((cf-staging-luna-config))\r\n           service_instance: luna  \r\n.\r\n.\r\n.\r\n- name: pave-prod-space\r\n  build_logs_to_retain: 10\r\n  plan:       \r\n    - put: create-staging-services\r\n      resource: cf-cli-prod\r\n      params:\r\n         commands:   \r\n         - command: create-user-provided-service\r\n           org: ((cf-org)) \r\n           space: ((cf-space-prod))    \r\n           credentials: ((cf-prod-luna-config))\r\n           service_instance: luna    "}}
{"actor":{"display_login":"gm2552"}}