コード例 #1
0
 @Test
 public void statistics() {
   this.applicationId
       .then(this::uploadAndStartApplication)
       .then(
           applicationId ->
               this.cloudFoundryClient
                   .applicationsV2()
                   .statistics(
                       ApplicationStatisticsRequest.builder().applicationId(applicationId).build())
                   .map(
                       instanceStatistics ->
                           instanceStatistics.get("0").getStatistics().getName()))
       .subscribe(testSubscriber().assertEquals(TEST_APPLICATION_NAME));
 }
コード例 #2
0
 private static Mono<ApplicationStatisticsResponse> requestApplicationStats(
     CloudFoundryClient cloudFoundryClient, String applicationId) {
   return cloudFoundryClient
       .applicationsV2()
       .statistics(ApplicationStatisticsRequest.builder().applicationId(applicationId).build());
 }