```Caused by: java.lang.IllegalArgumentException: ...
# spring
t
Copy code
Caused by: java.lang.IllegalArgumentException: Type to record invocations on must not be final!
	at org.springframework.util.Assert.isTrue(Assert.java:118) ~[spring-core-5.2.1.RELEASE.jar:5.2.1.RELEASE]
	at org.springframework.data.util.MethodInvocationRecorder.forProxyOf(MethodInvocationRecorder.java:76) ~[spring-data-commons-2.2.1.RELEASE.jar:2.2.1.RELEASE]
	at org.springframework.data.rest.core.config.EntityLookupConfiguration$RepositoriesEntityLookup.lambda$new$2(EntityLookupConfiguration.java:200) ~[spring-data-rest-core-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at java.util.Optional.flatMap(Optional.java:241) ~[na:1.8.0_202]
	at org.springframework.data.rest.core.config.EntityLookupConfiguration$RepositoriesEntityLookup.<init>(EntityLookupConfiguration.java:200) ~[spring-data-rest-core-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.data.rest.core.config.EntityLookupConfiguration.lambda$getEntityLookups$0(EntityLookupConfiguration.java:156) ~[spring-data-rest-core-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193) ~[na:1.8.0_202]
	at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1382) ~[na:1.8.0_202]
	at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481) ~[na:1.8.0_202]
	at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471) ~[na:1.8.0_202]
	at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708) ~[na:1.8.0_202]
	at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) ~[na:1.8.0_202]
	at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499) ~[na:1.8.0_202]
	at org.springframework.data.rest.core.config.EntityLookupConfiguration.getEntityLookups(EntityLookupConfiguration.java:157) ~[spring-data-rest-core-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.data.rest.core.config.RepositoryRestConfiguration.getEntityLookups(RepositoryRestConfiguration.java:654) ~[spring-data-rest-core-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.data.rest.webmvc.config.RepositoryRestMvcConfiguration.getEntityLookups(RepositoryRestMvcConfiguration.java:747) ~[spring-data-rest-webmvc-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.data.rest.webmvc.config.RepositoryRestMvcConfiguration.repositoryInvokerFactory(RepositoryRestMvcConfiguration.java:647) ~[spring-data-rest-webmvc-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.data.rest.webmvc.config.RepositoryRestMvcConfiguration$$EnhancerBySpringCGLIB$$bf97371a.CGLIB$repositoryInvokerFactory$25(<generated>) ~[spring-data-rest-webmvc-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.data.rest.webmvc.config.RepositoryRestMvcConfiguration$$EnhancerBySpringCGLIB$$bf97371a$$FastClassBySpringCGLIB$$efc869d4.invoke(<generated>) ~[spring-data-rest-webmvc-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:244) ~[spring-core-5.2.1.RELEASE.jar:5.2.1.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:363) ~[spring-context-5.2.1.RELEASE.jar:5.2.1.RELEASE]
	at org.springframework.data.rest.webmvc.config.RepositoryRestMvcConfiguration$$EnhancerBySpringCGLIB$$bf97371a.repositoryInvokerFactory(<generated>) ~[spring-data-rest-webmvc-3.2.1.RELEASE.jar:3.2.1.RELEASE]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_202]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_202]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_202]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_202]
	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154) ~[spring-beans-5.2.1.RELEASE.jar:5.2.1.RELEASE]
	... 77 common frames omitted