cloudfoundry / cli

The official command line client for Cloud Foundry
https://docs.cloudfoundry.org/cf-cli
Apache License 2.0
1.75k stars 929 forks source link

Error on creating a database with mapping to other spaces #2369

Closed 4CaDlqr2aU closed 1 month ago

4CaDlqr2aU commented 1 year ago

Describe the bug and the command you saw an issue with I am trying to create a database that includes a mapping to another space by specifying the "databaseMappings" property.

What happened Creation failed with error "provision could not be completed: Service broker error: Service broker hana-cloud failed with: invalid Parameter (databaseMappings): array must contain a single entry [ref 2KiptiuNe5Q9tvxYnJkpfHziifb]"

Expected behavior Expected the database to be created successfully, including an additional mapping to the other space.

Exact Steps To Reproduce Steps to reproduce the behavior; include the exact CLI commands and verbose output:

  1. create service instance: cf8 create-service hana-cloud hana test_create_mapping -c "<json>"
    {
    "data": {
    "systempassword": "<pass>",
    "edition": "cloud",
    "memory": 30,
    "databaseMappings": [{
        "organization_guid": "<organization_guid>",
        "space_guid": "<space_guid>"
      },
      {
        "organization_guid": "<organization_guid>",
        "space_guid": "<space_guid> of the other space"
      }
    ]
    }
    }
  2. See error: provision could not be completed: Service broker error: Service broker hana-cloud failed with: invalid Parameter (databaseMappings): array must contain a single entry [ref 2KiptiuNe5Q9tvxYnJkpfHziifb]" FAILED

Provide more context

Notes regarding V6 and V7 CLI support:

blgm commented 1 year ago

Hi @4CaDlqr2aU. I see that the error message contains Service broker error. This normally means that the error comes from the service broker. So the CF CLI has successfully sent a message to the Cloud Controller, the Cloud Controller has successfully sent a message to the Service Broker, and the Service Broker has failed with an error.

On the surface, it seems that this error relates to hana-cloud rather than to the CLI.

gururajsh commented 1 month ago

If you still run into this issue with the latest CLI v8, please open a new ticket with the necessary information mentioned in our issue template.