常用應用程式屬性
各種屬性可以在您的 application.properties 檔案、application.yml 檔案中指定,或作為命令列開關。本附錄提供了常見的 Spring Cloud Bus 屬性列表以及引用使用它們的底層類。
| 屬性貢獻可能來自您 classpath 中的其他 jar 檔案,因此您不應將其視為詳盡列表。此外,您還可以定義自己的屬性。 |
| 名稱 | 預設值 | 描述 |
|---|---|---|
spring.cloud.bus.ack.destination-service |
希望偵聽確認的服務。預設為 null(表示所有服務)。 |
|
spring.cloud.bus.ack.enabled |
|
關閉確認的標誌(預設開啟)。 |
spring.cloud.bus.content-type |
Bus 的 MIME 型別。 |
|
spring.cloud.bus.destination |
用於訊息的 Spring Cloud Stream 目標名稱。 |
|
spring.cloud.bus.enabled |
|
指示 Bus 是否已啟用的標誌。 |
spring.cloud.bus.env.enabled |
|
關閉環境變更事件的標誌(預設開啟)。 |
spring.cloud.bus.id |
|
此應用程式例項的識別符號。 |
spring.cloud.bus.refresh.enabled |
|
關閉重新整理事件的標誌(預設開啟)。 |
spring.cloud.bus.shutdown.enabled |
|
關閉關機事件的標誌(預設開啟)。 |
spring.cloud.bus.trace.enabled |
|
開啟確認跟蹤的標誌(預設關閉)。 |