According to the Spring Cloud Consul documentation support for meta field is available and parsing of the tags field is deprecated and will be removed in a future version. There's also a configuration property spring.cloud.consul.discovery.tags-as-metadata which controls the behavior.
However, when the property is set to false not all auto generated meta data is written into the meta field. The property contextPath is still added as entry in tags field c.f. ConsulServletRegistrationCustomizer.
As a result I end up with a Consul service registration for my web application where some data can be found in meta and other in tags. This makes it unnecessarily complex for clients to consume those properties.
According to the Spring Cloud Consul documentation support for
meta
field is available and parsing of thetags
field is deprecated and will be removed in a future version. There's also a configuration propertyspring.cloud.consul.discovery.tags-as-metadata
which controls the behavior.However, when the property is set to
false
not all auto generated meta data is written into themeta
field. The propertycontextPath
is still added as entry intags
field c.f. ConsulServletRegistrationCustomizer.As a result I end up with a Consul service registration for my web application where some data can be found in
meta
and other intags
. This makes it unnecessarily complex for clients to consume those properties.