title: Spring Cloud config client not picking endpoints from Config server
body: <p>Eureka configuration is pulled perfectly from the config server but the endpoints are not pulled from config-server.
  Please let me know if I am missing something.</p>
  <pre class="lang-java prettyprint-override"><code>@Service
  @RefreshScope
  public class OrderService {
  
      @Autowired
      private OrderRepo orderRepo;
  
      @Autowired
      @Lazy
      private RestTemplate restTemplate;
  
      @Value(&quot;${payment.endpoints}&quot;)
      private String DO_PAYMENT_URL;
  
      public TransactionResponse saveOrder(TransactionRequest request) {
          System.err.println(request);
          TransactionResponse response = new TransactionResponse();
          Order order = request.getOrder();
          Payment payment = request.getPayment();
          payment.setOrderId(order.getId());
          response.setOrder(orderRepo.save(order));
          // rest call
          Payment paymentResponse =
                  // restTemplate.postForObject(&quot;http://localhost:8083/payment/doPayment&quot;,payment,
                  // Payment.class);
                  // restTemplate.postForObject(&quot;http://PAYMENT-SERVICE/payment/doPayment&quot;,payment,
                  // Payment.class);
                  restTemplate.postForObject(DO_PAYMENT_URL + &quot;/doPayment&quot;, payment, Payment.class);
          response.setMessage(
                  paymentResponse.getStatus().equalsIgnoreCase(&quot;success&quot;) ? &quot;payment successful&quot; : &quot;payment failed&quot;);
          response.setTransactionId(paymentResponse.getTransactionId());
          return response;
      }
  }
  
  </code></pre>
  <pre class="lang-xml prettyprint-override"><code>&lt;parent&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
          &lt;version&gt;2.3.12.RELEASE&lt;/version&gt;
          &lt;relativePath /&gt; &lt;!-- lookup parent from repository --&gt;
      &lt;/parent&gt;
      &lt;groupId&gt;com.hk&lt;/groupId&gt;
      &lt;artifactId&gt;order-service&lt;/artifactId&gt;
      &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
      &lt;name&gt;order-service&lt;/name&gt;
      &lt;description&gt;order service&lt;/description&gt;
      &lt;properties&gt;
          &lt;java.version&gt;1.8&lt;/java.version&gt;
          &lt;spring-cloud.version&gt;Hoxton.SR11&lt;/spring-cloud.version&gt;
      &lt;/properties&gt;
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-data-jpa&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.cloud&lt;/groupId&gt;
              &lt;artifactId&gt;spring-cloud-starter-netflix-eureka-client&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.cloud&lt;/groupId&gt;
              &lt;artifactId&gt;spring-cloud-starter-config&lt;/artifactId&gt;
          &lt;/dependency&gt;
  </code></pre>
  <p><strong>git-config-file :</strong>
  <a href="https://gitlab.com/nickybesra/microservice-cloud-config/-/blob/main/application.yml" rel="nofollow noreferrer">https://gitlab.com/nickybesra/microservice-cloud-config/-/blob/main/application.yml</a></p>
  <p>ORDER-SERVICE bootstrap.yml:</p>
  <pre class="lang-yaml prettyprint-override"><code>spring:
    cloud:
      config:
        uri:
          - http://localhost:9196
  </code></pre>
  <p><strong>microservice code :</strong>
  <a href="https://gitlab.com/nickybesra/microservice-2021" rel="nofollow noreferrer">https://gitlab.com/nickybesra/microservice-2021</a></p>