-
Notifications
You must be signed in to change notification settings - Fork 38.6k
Closed
Labels
theme: aotAn issue related to Ahead-of-time processingAn issue related to Ahead-of-time processingtype: documentationA documentation taskA documentation task
Milestone
Description
Affects: 6.1.3
A bean definition that uses non-common value types like this:
@Override
public void postProcessBeanDefinitionRegistry(BeanDefinitionRegistry registry) throws BeansException {
RootBeanDefinition beanDefinition = new RootBeanDefinition(MyBean.class);
beanDefinition.getConstructorArgumentValues().addGenericArgumentValue(new MyBeanRecord("Bob", 12));
registry.registerBeanDefinition("MyBean", beanDefinition);
}
will cause a ValueCodeGeneration
exception.
Since this use case is intentionally unsupported (see #32214 (comment)), a helpful error message saying "ConstructorArgumentValues
do not support code generation for arguments of type (MyBeanRecord)" should be thrown instead, similar to what happens with instance suppliers.
Metadata
Metadata
Assignees
Labels
theme: aotAn issue related to Ahead-of-time processingAn issue related to Ahead-of-time processingtype: documentationA documentation taskA documentation task