Skip to content

Commit

Permalink
Mention @RegisterReflectionForBinding in the docs
Browse files Browse the repository at this point in the history
Closes gh-32903
  • Loading branch information
mhalbritter committed Nov 18, 2022
1 parent fb5cdbd commit b7de402
Showing 1 changed file with 3 additions and 1 deletion.
Expand Up @@ -141,7 +141,9 @@ include::code:MyRuntimeHints[]

You can then use `@ImportRuntimeHints` on any `@Configuration` class (for example your `@SpringBootApplication` annotated application class) to activate those hints.


If you have classes which needs binding (mostly needed when serializing or deserializing JSON), you can use {spring-framework-docs}/core.html#aot-hints-register-reflection-for-binding[`@RegisterReflectionForBinding`] on any bean.
Most of the hints are automatically inferred, for example when accepting or returning data from a `@RestController` method.
But when you work with `WebClient` or `RestTemplate` directly, you might need to use `RegisterReflectionForBinding`.

[[native-image.advanced.custom-hints.testing]]
==== Testing custom hints
Expand Down

0 comments on commit b7de402

Please sign in to comment.