0

So I want to override some settings for all my microservices, so I create a git repo and an application.yml file for that.

  1. Download registry jar from jhipster.
  2. run it with the following command.

    java -jar jhipster-registry-5.0.2.jar --spring.profiles.active=prod --spring.security.user.password=xxx --jhipster.security.authentication.jwt.secret=abcde --spring.cloud.config.server.composite[0].type=git --spring.cloud.config.server.composite[0].uri=https://github.com/xxx --spring.cloud.config.server.composite[0].username=xxx --spring.cloud.config.server.composite[0].password=xxx

The services communicate through feign client which takes its data from the application.yml. The settings look like this:

application:
    external:
        services:
            service-name:
                base-url: local

But when I run the jhipster registry pointing to this repo. I get the following error.

Origin: ...
Reason: The elements [] are left unbound

I tried using all kinds of combos for the file name. application.yml, application-prod.yml, application-dev.yml, service-name.yml and also application.yml

There doesn't seem to be a problem for other properties, such as for database password and url. Or even arbitrary chains like abc.abc.abc.abc="data", these work. I even played around and simply messed up the spellings like mistyping external, services and application.

When I misspelled application like aaaaplication. It doesnt give an error. Only when I include "application:" in my yml file jhipster throws an error.

Please confirm if I am correct in assuming that jhipster won't allow application to be overriden. And if yes then how can I override this?

I don't think its optimal to change all the services for this. So is there a workaround for this?

Zàf Mohammed
  • 127
  • 1
  • 9

0 Answers0