This commit updates ConstructorOrFactoryMethodResolver to throw an exception if no constructor or factory method can be found for a given bean definition. This prevents code generation to happen on an incomplete view of the bean to instantiate. Closes gh-29052