@Test public void getByNotExistingContext(){ Iterator iterator = testSubject.getByComponent("Component", "Dummy").iterator(); assertFalse(iterator.hasNext()); }
@GetMapping("components/{component}/queries") public Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context){ return new ComponentItems<>(component, context, new DefaultQueries(registrationCache)); }
QueryRestController { @GetMapping("components/{component}/queries") public Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context){ return new ComponentItems<>(component, context, new DefaultQueries(registrationCache)); } }
QueryRestController { @GetMapping("components/{component}/queries") public Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context){ return new ComponentItems<>(component, context, new DefaultQueries(registrationCache)); } QueryRestController(QueryRegistrationCache registrationCache,
                               QueryDispatcher queryDispatcher); }
QueryRestController { @GetMapping("components/{component}/queries") public Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context){ return new ComponentItems<>(component, context, new DefaultQueries(registrationCache)); } QueryRestController(QueryRegistrationCache registrationCache,
                               QueryDispatcher queryDispatcher); @GetMapping("components/{component}/queries") Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context); @GetMapping("queries") List<JsonQueryMapping> get(); @PostMapping("queries/run") @ApiImplicitParams({ @ApiImplicitParam(name = TOKEN_PARAM, value = "Access Token", required = false, dataType = "string", paramType = "header") }) SseEmitter execute(
            @RequestHeader(value = CONTEXT_PARAM, defaultValue = Topology.DEFAULT_CONTEXT, required = false) String context,
            @RequestBody @Valid QueryRequestJson query); }
QueryRestController { @GetMapping("components/{component}/queries") public Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context){ return new ComponentItems<>(component, context, new DefaultQueries(registrationCache)); } QueryRestController(QueryRegistrationCache registrationCache,
                               QueryDispatcher queryDispatcher); @GetMapping("components/{component}/queries") Iterable<Query> getByComponent(@PathVariable("component") String component, @RequestParam("context") String context); @GetMapping("queries") List<JsonQueryMapping> get(); @PostMapping("queries/run") @ApiImplicitParams({ @ApiImplicitParam(name = TOKEN_PARAM, value = "Access Token", required = false, dataType = "string", paramType = "header") }) SseEmitter execute(
            @RequestHeader(value = CONTEXT_PARAM, defaultValue = Topology.DEFAULT_CONTEXT, required = false) String context,
            @RequestBody @Valid QueryRequestJson query);  }