Hi ,

Spring boot 2.1.3.RELEASE Java 1.8 Spring Cloud version Greenwich.SR1

Eureka server is up. But, I am not able to view the Eureka server dashboard.

Comment From: spencergibb

Please provide details of the problem, including the version of Spring Cloud that you are using. If possible, please provide a test case or sample application that reproduces the problem. This makes it much easier for us to diagnose the problem and to verify that we have fixed it.

What url are you accessing? What is your configuration?

Comment From: duraikutty

Hi,

1.Spring boot 2.1.3.RELEASE 2.Java 1.8 3.Spring Cloud version - Greenwich.SR1

pom.xml `<?xml version="1.0" encoding="UTF-8"?> 4.0.0 org.springframework.boot spring-boot-starter-parent 2.1.3.RELEASE com.durai apps 0.0.1-SNAPSHOT apps Eureka Server for Spring Boot

<properties>
    <java.version>1.8</java.version>
    <spring-cloud.version>Greenwich.SR1</spring-cloud.version>
</properties>

<dependencies>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>
</dependencies>

<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-dependencies</artifactId>
            <version>${spring-cloud.version}</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>
    </dependencies>
</dependencyManagement>

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
        </plugin>
    </plugins>
</build>

`

`package com.durai.apps;

import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.cloud.netflix.eureka.server.EnableEurekaServer;

@EnableEurekaServer @SpringBootApplication public class ApplicationBootrap {

public static void main(String[] args) {
    SpringApplication.run(ApplicationBootrap.class, args);
}

}`

`server.port=8761

eureka.client.register-with-eureka=false eureka.client.fetch-registry=false

logging.level.com.netflix.eureka=OFF logging.level.com.netflix.discovery=OFF`

logs 2019-04-03 15:50:08.162 INFO 8200 --- [ Thread-13] o.s.c.n.e.server.EurekaServerBootstrap : Initialized server context 2019-04-03 15:50:08.178 INFO 8200 --- [ Thread-13] e.s.EurekaServerInitializerConfiguration : Started Eureka Server 2019-04-03 15:50:08.196 INFO 8200 --- [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat started on port(s): 8761 (http) with context path '' 2019-04-03 15:50:08.196 INFO 8200 --- [ main] .s.c.n.e.s.EurekaAutoServiceRegistration : Updating port to 8761 2019-04-03 15:50:08.198 INFO 8200 --- [ main] com.durai.apps.ApplicationBootrap : Started ApplicationBootrap in 6.106 seconds (JVM running for 7.333) 2019-04-03 15:50:22.743 INFO 8200 --- [nio-8761-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring DispatcherServlet 'dispatcherServlet' 2019-04-03 15:50:22.743 INFO 8200 --- [nio-8761-exec-1] o.s.web.servlet.DispatcherServlet : Initializing Servlet 'dispatcherServlet' 2019-04-03 15:50:22.750 INFO 8200 --- [nio-8761-exec-1] o.s.web.servlet.DispatcherServlet : Completed initialization in 7 ms

error

We are not able to view dashboard of eureka server. Whitelabel Error Page is showing.

Comment From: Tataraovoleti

I m having same issue. When i access http://localhost:8761/eureka/ getting 404 error

But my remaining services are able to register themselves with eureka registry. The only problem i could see dashboard is not coming up.

Comment From: OlgaMaciaszek

Hello, @duraikutty @Tataraovoleti I have tried recreating the issue against the provided versions of Spring Cloud and Spring Boot and it worked ok for me. Maybe there's sth more you've missed while providing us your setup? In order to verify what is happening, I would suggest to temporarily set the logging level for Spring to DEBUG and check if any more details for the 404 can be found there.

If that does not help, please provide a minimal, complete, verifiable example that reproduces the issue.

Comment From: Tataraovoleti

Hi @OlgaMaciaszek ,

build.gradle

` plugins { id 'org.springframework.boot' version '2.1.4.RELEASE' id 'java' }

apply plugin: 'io.spring.dependency-management'

group = 'com.tata.auth' version = '0.0.1-SNAPSHOT' sourceCompatibility = '1.8'

repositories { mavenCentral() }

ext { set('springCloudVersion', 'Greenwich.SR1') }

dependencies { implementation 'org.springframework.boot:spring-boot-starter-web' implementation 'org.springframework.cloud:spring-cloud-starter-netflix-eureka-server' implementation 'org.springframework.cloud:spring-cloud-starter-sleuth' testImplementation 'org.springframework.boot:spring-boot-starter-test' }

dependencyManagement { imports { mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}" } } `

application.yml

spring: application: name: eureka-server server: port: 8761 logging: level: org.springframework.security: DEBUG eureka: client: fetch-registry: false register-with-eureka: false serviceUrl: defaultZone: http://localhost:8761/eureka/

and main class is annotated with @SpringBootApplication @EnableEurekaServer

Comment From: OlgaMaciaszek

@Tataraovoleti I've recreated this setup (See the eureka-test-2.zip) and I can run it and launch the dashboard without any issues. We will really need either more info from the logs or a demo that reproduces the issue (github repo link or zip) to further verify it.

Comment From: spring-projects-issues

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

Comment From: spring-projects-issues

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.

Comment From: duckShooter

I'm using Spring Boot 2.2.0 M3 This what i a get when i set the logging level of spring web to DEBUG

java.io.FileNotFoundException: class path resource [templates/] cannot be resolved to absolute file path because it does not reside in the file system: jar:file:/C:/Users/xx/.m2/repository/org/springframework/cloud/spring-cloud-netflix-eureka-server/2.2.0.BUILD-SNAPSHOT/spring-cloud-netflix-eureka-server-2.2.0.BUILD-20190620.080605-611.jar!/templates/
    at org.springframework.util.ResourceUtils.getFile(ResourceUtils.java:217) ~[spring-core-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.core.io.AbstractFileResolvingResource.getFile(AbstractFileResolvingResource.java:154) ~[spring-core-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.ui.freemarker.FreeMarkerConfigurationFactory.getTemplateLoaderForPath(FreeMarkerConfigurationFactory.java:345) [spring-context-support-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.ui.freemarker.FreeMarkerConfigurationFactory.createConfiguration(FreeMarkerConfigurationFactory.java:297) [spring-context-support-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer.afterPropertiesSet(FreeMarkerConfigurer.java:120) [spring-webmvc-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1842) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1779) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:593) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) [spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:868) ~[spring-beans-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:877) ~[spring-context-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:549) ~[spring-context-5.2.0.M2.jar:5.2.0.M2]
    at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:142) ~[spring-boot-2.2.0.M3.jar:2.2.0.M3]
    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:782) ~[spring-boot-2.2.0.M3.jar:2.2.0.M3]
    at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:404) ~[spring-boot-2.2.0.M3.jar:2.2.0.M3]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:319) ~[spring-boot-2.2.0.M3.jar:2.2.0.M3]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1275) ~[spring-boot-2.2.0.M3.jar:2.2.0.M3]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1263) ~[spring-boot-2.2.0.M3.jar:2.2.0.M3]
    at prolog.sim.ducktap.discoveryservice.DiscoveryServiceApplication.main(DiscoveryServiceApplication.java:12) ~[classes/:na]

This happens when using the most recent build (24/6/2019) Downgrading to previous build versions works i.e. (10/6/2019)

Comment From: ryanjbaxter

Sounds like a bad jar, try cleaning your maven repo and try again

Comment From: avanish29

Hi @OlgaMaciaszek ,

build.gradle

` plugins { id 'org.springframework.boot' version '2.1.4.RELEASE' id 'java' }

apply plugin: 'io.spring.dependency-management'

group = 'com.tata.auth' version = '0.0.1-SNAPSHOT' sourceCompatibility = '1.8'

repositories { mavenCentral() }

ext { set('springCloudVersion', 'Greenwich.SR1') }

dependencies { implementation 'org.springframework.boot:spring-boot-starter-web' implementation 'org.springframework.cloud:spring-cloud-starter-netflix-eureka-server' implementation 'org.springframework.cloud:spring-cloud-starter-sleuth' testImplementation 'org.springframework.boot:spring-boot-starter-test' }

dependencyManagement { imports { mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}" } } `

application.yml

spring: application: name: eureka-server server: port: 8761 logging: level: org.springframework.security: DEBUG eureka: client: fetch-registry: false register-with-eureka: false serviceUrl: defaultZone: http://localhost:8761/eureka/

and main class is annotated with @SpringBootApplication @EnableEurekaServer

@Tataraovoleti I had the same issue after looking log file I can figure out the issue, you may have static and template folder inside your resource, Below is log highlighted for the same:

2019-07-22 15:40:22.623 DEBUG 24180 --- [nio-8080-exec-4] o.s.web.servlet.DispatcherServlet : GET "/", parameters={} 2019-07-22 15:40:22.624 DEBUG 24180 --- [nio-8080-exec-4] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped to org.springframework.cloud.netflix.eureka.server.EurekaController#status(HttpServletRequest, Map) 2019-07-22 15:40:22.627 DEBUG 24180 --- [nio-8080-exec-4] o.s.w.s.v.ContentNegotiatingViewResolver : Selected 'text/html' given [text/html, application/xhtml+xml, image/webp, image/apng, application/signed-exchange;v=b3, application/xml;q=0.9, /;q=0.8] 2019-07-22 15:40:22.627 DEBUG 24180 --- [nio-8080-exec-4] o.s.w.servlet.view.InternalResourceView : View name 'eureka/status', model {time=Mon Jul 22 15:40:22 CEST 2019, basePath=/, dashboardPath=, currentTime=2019-07-22T15:40:22 +0200, upTime=00:00, environment=test, datacenter=default, registry=org.springframework.cloud.netflix.eureka.server.InstanceRegistry@7609fcf4, isBelowRenewThresold=true, replicas=[localhost=http://localhost:8080/eureka/], apps=[], statusInfo=com.netflix.eureka.util.StatusInfo@4f4804ba, instanceInfo={ipAddr=10.222.38.14, status=UP}, applicationStats={registered-replicas=http://localhost:8080/eureka/, available-replicas=, unavailable-replicas=http://localhost:8080/eureka/,}, org.springframework.validation.BindingResult.registry=org.springframework.validation.BeanPropertyBindingResult: 0 errors, org.springframework.validation.BindingResult.statusInfo=org.springframework.validation.BeanPropertyBindingResult: 0 errors} 2019-07-22 15:40:22.627 DEBUG 24180 --- [nio-8080-exec-4] o.s.w.servlet.view.InternalResourceView : Forwarding to [eureka/status] 2019-07-22 15:40:22.628 DEBUG 24180 --- [nio-8080-exec-4] o.s.web.servlet.DispatcherServlet : "FORWARD" dispatch for GET "/eureka/status", parameters={} 2019-07-22 15:40:22.633 DEBUG 24180 --- [nio-8080-exec-4] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped to ResourceHttpRequestHandler ["classpath:/META-INF/resources/", "classpath:/resources/", "classpath:/static/", "classpath:/public/", "/"] 2019-07-22 15:40:22.636 DEBUG 24180 --- [nio-8080-exec-4] o.s.w.s.r.ResourceHttpRequestHandler : Resource not found 2019-07-22 15:40:22.636 DEBUG 24180 --- [nio-8080-exec-4] o.s.web.servlet.DispatcherServlet : Exiting from "FORWARD" dispatch, status 404 2019-07-22 15:40:22.636 DEBUG 24180 --- [nio-8080-exec-4] o.s.web.servlet.DispatcherServlet : Completed 404 NOT_FOUND 2019-07-22 15:40:22.637 DEBUG 24180 --- [nio-8080-exec-4] o.s.web.servlet.DispatcherServlet : "ERROR" dispatch for GET "/error", parameters={} 2019-07-22 15:40:22.637 DEBUG 24180 --- [nio-8080-exec-4] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped to org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController#errorHtml(HttpServletRequest, HttpServletResponse) 2019-07-22 15:40:26.268 DEBUG 24180 --- [nio-8080-exec-4] o.s.w.s.v.ContentNegotiatingViewResolver : Selected 'text/html' given [text/html, text/html;q=0.8] 2019-07-22 15:40:26.268 DEBUG 24180 --- [nio-8080-exec-4] o.s.web.servlet.DispatcherServlet : Exiting from "ERROR" dispatch, status 404 2019-07-22 15:40:32.975 INFO 24180 --- [a-EvictionTimer] c.n.e.registry.AbstractInstanceRegistry : Running the evict task with compensationTime 0ms

Comment From: JainNaveen94

Hi to all, I am facing the same issue, Could any one help me out there.

Resolved [feign.RetryableException: connect timed out executing GET http://currency-exchange-service/currency-exchange/from/USD/to/INR] occured

here, i didn't get why http://currency-exchange-service/currency-exchange/from/USD/to/INR called instead http://localhost:8000/currency-exchange/from/USD/to/INR

Comment From: kfrajtak

If you generate the Spring project using Spring Initializer the dashboard won't open ending in "Whitelabel Error Page". No need for MVP, just go there and generate it.

Comment From: komal3770

spring.freemarker.template-loader-path= classpath:/templates/ spring.freemarker.prefer-file-system-access= false

Add this lines in application.properties and error will be gone

Comment From: rahuldhangar02

@komal3770 thanks your solution is working

Comment From: zengqiangfang

Same issue to me, can access to url http://localhost:8761/ but cannot access to http://localhost:8761/eureka