Search in sources :

Example 1 with SoftwareCatalogService

use of com.khartec.waltz.service.software_catalog.SoftwareCatalogService in project waltz by khartec.

the class SoftwareCatalogHarness method main.

public static void main(String[] args) {
    AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(DIConfiguration.class);
    SoftwareCatalogService softwareCatalogService = ctx.getBean(SoftwareCatalogService.class);
    DSLContext dsl = ctx.getBean(DSLContext.class);
    EntityReference ref = ImmutableEntityReference.builder().kind(EntityKind.ORG_UNIT).id(20L).build();
    IdSelectionOptions options = ImmutableIdSelectionOptions.builder().entityReference(ref).scope(HierarchyQueryScope.CHILDREN).build();
    SoftwareSummaryStatistics stats = softwareCatalogService.findStatisticsForAppIdSelector(options);
    System.out.println("stats:" + stats);
}
Also used : AnnotationConfigApplicationContext(org.springframework.context.annotation.AnnotationConfigApplicationContext) SoftwareCatalogService(com.khartec.waltz.service.software_catalog.SoftwareCatalogService) DSLContext(org.jooq.DSLContext) SoftwareSummaryStatistics(com.khartec.waltz.model.software_catalog.SoftwareSummaryStatistics)

Aggregations

SoftwareSummaryStatistics (com.khartec.waltz.model.software_catalog.SoftwareSummaryStatistics)1 SoftwareCatalogService (com.khartec.waltz.service.software_catalog.SoftwareCatalogService)1 DSLContext (org.jooq.DSLContext)1 AnnotationConfigApplicationContext (org.springframework.context.annotation.AnnotationConfigApplicationContext)1