-
Notifications
You must be signed in to change notification settings - Fork 382
Move serviceBroker references to clusterServiceBroker in controllers #1911
Conversation
Investigating the travis failure. |
@@ -39,7 +39,7 @@ const ( | |||
errorFetchingCatalogReason string = "ErrorFetchingCatalog" | |||
errorFetchingCatalogMessage string = "Error fetching catalog. " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you removed trailing space below, do it there too?
@@ -39,7 +39,7 @@ const ( | |||
errorFetchingCatalogReason string = "ErrorFetchingCatalog" | |||
errorFetchingCatalogMessage string = "Error fetching catalog. " | |||
errorSyncingCatalogReason string = "ErrorSyncingCatalog" | |||
errorSyncingCatalogMessage string = "Error syncing catalog from ServiceBroker. " | |||
errorSyncingCatalogMessage string = "Error syncing catalog from ServiceBroker." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/ServiceBroker/ClusterServiceBroker
@@ -39,7 +39,7 @@ const ( | |||
errorFetchingCatalogReason string = "ErrorFetchingCatalog" | |||
errorFetchingCatalogMessage string = "Error fetching catalog. " | |||
errorSyncingCatalogReason string = "ErrorSyncingCatalog" | |||
errorSyncingCatalogMessage string = "Error syncing catalog from ServiceBroker. " | |||
errorSyncingCatalogMessage string = "Error syncing catalog from ServiceBroker." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also I suspect we will have the same reasons/messages for namespaced service brokers, so we should probably prefix the variable names with cluster-
too.
@@ -39,7 +39,7 @@ const ( | |||
errorFetchingCatalogReason string = "ErrorFetchingCatalog" | |||
errorFetchingCatalogMessage string = "Error fetching catalog. " | |||
errorSyncingCatalogReason string = "ErrorSyncingCatalog" | |||
errorSyncingCatalogMessage string = "Error syncing catalog from ServiceBroker. " | |||
errorSyncingCatalogMessage string = "Error syncing catalog from ServiceBroker." | |||
|
|||
errorListingClusterServiceClassesReason string = "ErrorListingServiceClasses" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably missed in #1910: should error reason and message have Cluster
?
@nilebox Updated a bunch of the reason/messages with |
@eriknelson looks good, but the tests are failing now, you need to update constants in them as well
|
21d9b64
to
bdbb550
Compare
bdbb550
to
3571c47
Compare
rebased |
errorDeletingClusterServiceClassMessage string = "Error deleting service class." | ||
errorDeletingClusterServicePlanReason string = "ErrorDeletingServicePlan" | ||
errorDeletingClusterServicePlanMessage string = "Error deleting service plan." | ||
errorFetchingClusterCatalogReason string = "ErrorFetchingClusterCatalog" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the error should still be ErrorFetchingCatalog
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same comment for the other errors
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same - I don't think these constants should change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think the constants should be changing here.
@@ -30,8 +30,8 @@ | |||
"type": "Ready", | |||
"status": "True", | |||
"lastTransitionTime": "2018-01-11T20:53:31Z", | |||
"reason": "FetchedCatalog", | |||
"message": "Successfully fetched catalog entries from broker." | |||
"reason": "FetchedClusterCatalog", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We shouldn't change this - it will break existing users of the API and I doubt this distinction needs to surface to users in any event.
"reason": "FetchedCatalog", | ||
"message": "Successfully fetched catalog entries from broker." | ||
"reason": "FetchedClusterCatalog", | ||
"message": "Successfully fetched cluster catalog entries from broker." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same thing with 'cluster' here - I don't think the additional wording is going to make a difference to users beyond confusing them.
contrib/jenkins/test_walkthrough.sh
Outdated
@@ -131,7 +131,7 @@ USER_PROVIDED_SERVICE_ID="4f6e6cf6-ffdd-425f-a2c7-3c9258ad2468" | |||
kubectl create -f "${ROOT}/contrib/examples/walkthrough/ups-broker.yaml" \ | |||
|| error_exit 'Error when creating ups-broker.' | |||
|
|||
wait_for_expected_output -e 'FetchedCatalog' \ | |||
wait_for_expected_output -e 'FetchedClusterCatalog' \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nope :)
docs/cli.md
Outdated
@@ -59,7 +59,7 @@ $ svcat get brokers | |||
|
|||
```console | |||
$ svcat sync broker ups-broker | |||
Successfully fetched catalog entries from the ups-broker broker | |||
Successfully fetched cluster catalog entries from the ups-broker broker |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nope :)
errorDeletingClusterServiceClassMessage string = "Error deleting service class." | ||
errorDeletingClusterServicePlanReason string = "ErrorDeletingServicePlan" | ||
errorDeletingClusterServicePlanMessage string = "Error deleting service plan." | ||
errorFetchingClusterCatalogReason string = "ErrorFetchingClusterCatalog" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same - I don't think these constants should change.
Status: Ready - Successfully fetched catalog entries from broker @ 2018-01-11 20:53:31 +0000 UTC | ||
Name: ups-broker | ||
URL: http://ups-broker-ups-broker.ups-broker.svc.cluster.local | ||
Status: Ready - Successfully fetched cluster catalog entries from broker @ 2018-01-11 20:53:31 +0000 UTC |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This still has 'cluster' in it, we should remove this.
3571c47
to
ceb3557
Compare
8fb113e
to
7860a5b
Compare
errorDeletingClusterServiceClassMessage string = "Error deleting service class." | ||
errorDeletingClusterServicePlanReason string = "ErrorDeletingServicePlan" | ||
errorDeletingClusterServicePlanMessage string = "Error deleting service plan." | ||
errorSyncingCatalogMessage string = "Error syncing catalog from ClusterServiceBroker." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also thought we agreed not to change these constants
* Updating broker messages/reasons with Cluster prefix
7c11a82
to
da2d2dd
Compare
@pmorie reversed the const changes and rebased again |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a couple minor nits and we're good on this one.
docs/walkthrough.md
Outdated
@@ -88,8 +88,8 @@ spec: | |||
status: | |||
conditions: | |||
- lastTransitionTime: 2017-11-01T14:12:30Z | |||
message: Successfully fetched catalog entries from broker. | |||
reason: FetchedCatalog | |||
message: Successfully fetched cluster catalog entries from broker. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now this doc should have the changes reverted and we'll be good to go.
@@ -38,9 +38,9 @@ import ( | |||
// be easily combined with a follow on specific message. | |||
const ( | |||
errorFetchingCatalogReason string = "ErrorFetchingCatalog" | |||
errorFetchingCatalogMessage string = "Error fetching catalog. " | |||
errorFetchingCatalogMessage string = "Error fetching catalog." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note the trailing spaces; those are intentional because these strings are use to construct error messages. Would you restore the trailing spaces?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Didn't realize those were deliberate; that makes sense.
* Update walkthrough doc to remove references to "cluster catalog" * Restore trailing spaces used in composite error messages
Thanks, I'll merge on green |
This PR renames
controller_broker.go
tocontroller_clusterservicebroker.go
and updates relevant controller references to make room for the namespacedservicebroker
controller.