jasonmimick / atlas-osb

DEPRECATED: See https://github.com/mongodb/atlas-osb

Home Page:https://github.com/mongodb/atlas-osb

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

broker allows 2 plans with same name

jasonmimick opened this issue · comments

I can deploy the broker with 2 plan template with the same value for the name.
This will break provisioning.

{"level":"info","ts":1594218354.0032568,"caller":"broker/services.go:242","msg":"Parsed plan: name: basic-plan\ndescription: \"This is the `Basic Plan` template for 1 project, 1 cluster, 1 dbuser, and 1 secure connection.\"\nfree: true\napiKey: {}\nproject:\n  name: <no value>\n  desc: Created from a template\n  orgId: <no value>\ncluster:\n  name: <no value>\n  providerSettings:\n    providerName: AWS\n    instanceSizeName: M20\n    regionName: US_EAST_1\n    replicationSpecs:\n    - numShards: 1,\n      zoneName: \"Zone 1\",\n      regionsConfig:\n        US_CENTRAL:\n          analyticsNodes: 0\n          electableNodes: 1\n          priority: 6,\n          readOnlyNodes: 0\n        US_EAST_2:\n          analyticsNodes: 0\n          electableNodes: 2\n          priority: 7\n          readOnlyNodes: 0\n        US_WEST:\n          analyticsNodes: 0\n          electableNodes: 2\n          priority: 5\n          readOnlyNodes: 0\ndatabaseUsers:\n- username: test-user\n  password: test-password\n  databaseName: admin\n  roles:\n  - roleName: readWrite\n    databaseName: test\nipWhitelists:\n- ipAddress: \"0.0.0.0/1\"\n  comment: \"everything\"\n- ipAddress: \"128.0.0.0/1\"\n  comment: \"everything\"\n"}
{"level":"info","ts":1594218354.0043626,"caller":"broker/services.go:242","msg":"Parsed plan: name: basic-plan\ndescription: \"This is the `Basic Plan` template for 1 project, 1 cluster, 1 dbuser, and 1 secure connection.\"\nfree: true\napiKey: {}\nproject:\n  name: <no value>\n  desc: Created from a template\n  orgId: <no value>\ncluster:\n  name: <no value>\n  providerSettings:\n    providerName: AWS\n    instanceSizeName: M20\n    regionName: US_EAST_1\ndatabaseUsers:\n- username: test-user\n  password: test-password\n  databaseName: admin\n  roles:\n  - roleName: readWrite\n    databaseName: test\nipWhitelists:\n- ipAddress: \"0.0.0.0/1\"\n  comment: \"everything\"\n- ipAddress: \"128.0.0.0/1\"\n  comment: \"everything\"\n"}
{"level":"info","ts":1594218354.0052798,"caller":"broker/services.go:76","msg":"Built service","provider":"template"}
{"level":"info","ts":1594218354.0061862,"caller":"atlas-osb-YMLPLANS/main.go:234","msg":"Starting API server","releaseVersion":"a33a2ee-dirty","host":"0.0.0.0","port":4000,"tls_enabled":false}

CF detects this and prevents broker creation. @jasonmimick do we need to fix that for potential non-CF environments?

Yes, we should it will break provisioning bare bones deploys, plus not sure how k8s service catalog will behave

moving to sprint 3 bug fixing