Support separate consul discovery properties for grpc and http services
See original GitHub issueHello!
Starting from some version now grpc automatically registers itself on consul. I have TWO registrations now: <service name> and grpc-<service name> both with same set of tags. There is no way I can separate those two by tags or keep only <service name>. The only way is to filter by service name prefix grpc-, which is a very bad practice (what if I want to name my service grpc-something?). Currently I have to use awkward spring.autoconfigure.exclude (which doesn’t concat automatically if specified in several profiles, see https://stackoverflow.com/questions/41170316/combine-list-from-multiple-spring-boot-yaml-files).
Here are few suggestions I have:
- Add a separate setting for enabling grpc consul (and probably other servers) registration. See
OnConsulRegistrationEnabledConditionwhich requires bothspring.cloud.service-registry.enabledandspring.cloud.consul.service-registry.enabledflags. We can disable all auto registration or only consul auto registration this way. For grpc you might wanna check bothspring.cloud.service-registry.enabledandspring.cloud.grpc.discovery.service-registry.enabled - Add grpc service registration tags which override
spring.cloud.consul.discovery.tagswhen applied to grpc service registration likespring.cloud.grpc.discovery.tags - Extract
grpc-hardcode into config to something likespring.cloud.grpc.discovery.service-prefix
Issue Analytics
- State:
- Created 2 years ago
- Comments:9
Top Results From Across the Web
Register Services with Service Definitions | Consul
Define and register services and their health checks with Consul to make a service available for service discovery or service mesh access.
Read more >Spring Cloud Consul
Consul provides Service Discovery services via an HTTP API and DNS. ... property, management service will be registered as a separate service than...
Read more >grpc-spring-boot-starter/README.adoc at master - GitHub
Contribute to LogNet/grpc-spring-boot-starter development by creating an account ... is to externalize the transactional logic into separate service class :.
Read more >Configuring a gRPC service - Cloud Endpoints
To configure this in your service configuration, some parts of the service configuration, such as authentication and http , let you specify rules...
Read more >Configuration | grpc-spring-boot-starter - GitHub Pages
The properties for the channels are all prefixed with grpc.client.__name__. and grpc.client. ... Example: discovery:///service-name; self (Prio 0):
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@OverDrone , FYI, see #251 ,
4.5.8-SNAPSHOTshould be published in few minutesYes, that should do it for me, thx. I don’t require hotfix solution. I can live with spring.autoconfigure.exclude for some time. Take your time to build quality product 😃