私はEurekaサーバスプリングブートアプリケーションを作成しました。正しくロードされています。その後、私はユーレカのクライアントを作成しようとしています。しかし、ユーレカのサーバーのUIには載っていません。クライアントアプリケーションの詳細を追加しています。ユーレカサーバUIで名前が「UNKNOWN」で実行されているユーレカクライアント
私のメインコントローラクラスファイルは以下の通りです、
@SpringBootApplication
@EnableDiscoveryClient
public class ZEurekaClientServiceApplication {
public static void main(String[] args) {
SpringApplication.run(ZEurekaClientServiceApplication.class, args);
}
}
そして、私のpom.xmlが含まれ、
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-eureka</artifactId>
</dependency>
そして
<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>
そして、私のapplication.propertiesファイルが含ま、
eureka.client.serviceUrl.defaultZone=http://localhost:8071/eureka
eureka.client.register-with-eureka=true
eureka.client.fetch-registry=true
クライアントが実行されている場合、ユーレカサーバーのUIにはその名前が表示されません。アプリケーションとしてUNKNOWNを示しています。そのスクリーンショットを以下に追加しています。
ユーリカのサーバーのUIに「UNKNOWN」の代わりにアプリケーション名を表示する必要はありますか?アプリケーション名を追加する追加の設定はありますか?誰も私はこの問題を明確に助けることができますか?
はい。私はそれを得た。働いている。ご回答いただきありがとうございます。 – Jacob