Skip to content

Commit

Permalink
add logging for every Query
Browse files Browse the repository at this point in the history
  • Loading branch information
hknots committed Dec 13, 2023
1 parent a1a427f commit 7004e37
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions generate/graphql/query_resolver_tpl.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import reactor.core.publisher.Mono;
import java.util.concurrent.CompletionStage;
@Component("{{component .Package}}{{.Name}}QueryResolver")
@Slf4j
public class {{ .Name }}QueryResolver implements GraphQLQueryResolver {
@Autowired
Expand All @@ -24,6 +25,7 @@ public class {{ .Name }}QueryResolver implements GraphQLQueryResolver {
String {{ .Name }},
{{- end }}
DataFetchingEnvironment dfe) {
log.info("New Query for {{ .Name }}");
{{- range $i, $ident := .Identifiers }}
if (StringUtils.isNotEmpty({{ .Name }})) {
return service.get{{ $.Name }}ResourceById("{{ lowerCase .Name }}", {{.Name}}, dfe).toFuture();
Expand Down

0 comments on commit 7004e37

Please sign in to comment.