Skip to content
This repository has been archived by the owner on Jul 27, 2023. It is now read-only.

Add CatalogOptions to KeyValueClient, or add Datacenter to QueryOptions #187

Closed
dtertman opened this issue Dec 1, 2016 · 1 comment
Closed

Comments

@dtertman
Copy link

dtertman commented Dec 1, 2016

Sometimes it is necessary to query a Key/Value from another data center. The most visible use-case is a developer working locally on the laptop/desktop, but wanting to act like a QA or PROD server. Rather than running a local Consul instance, changing its datacenter, and redoing all of its joins, it would be much better to just tap into a consistent web API endpoint and use the existing WAN gossip.

The KeyValueClient currently doesn't support this, even though the underlying Consul API does. QueryOptions does not have a datacenter parameter, and CatalogOptions, which has a datacenter, isn't accepted by any of the KeyValueClient methods.

HealthClient, on the other hand, does support this method, through CatalogOptions.

@rickfast
Copy link
Owner

rickfast commented Dec 1, 2016

Hmmm surprised I never added that. Also surprised it hasn't come up as an issue. Fixed by ef3ca72

@rickfast rickfast closed this as completed Dec 1, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants