I want to integrate the springbootadmin monitoring detail page into our own management system, how can I get the instanceId of the detail page? for example localhost:8020/instances/5f3d1f8ee6a0/details,I want to know how can I get 5f3d1f8ee6a0
Asked
Active
Viewed 891 times
1 Answers
0
With ApplicationRegistrator
class, you can create a route on the client exposing the registered id:
@RestController
@RequestMapping("api/instance")
class InstanceController {
@Autowired
ApplicationRegistrator applicationRegistrator
@GetMapping("/")
String get() {
return applicationRegistrator.getRegisteredId();
}
}

Nimantha
- 6,405
- 6
- 28
- 69

Éverton Mengotti
- 16
- 2