konrad-kaminski / spring-kotlin-coroutine

Kotlin coroutine support for Spring.
448 stars 69 forks source link

Issues using with Kotlin Coroutine 0.30.1 #37

Open x0a1b opened 5 years ago

x0a1b commented 5 years ago

Just updated my coroutine package to 0.30.1 and now I am getting this exception:

Caused by: java.lang.IllegalAccessError: tried to access field kotlinx.coroutines.experimental.Dispatchers.Default from class org.springframework.kotlin.experimental.coroutine.context.CoroutineContexts
    at org.springframework.kotlin.experimental.coroutine.context.CoroutineContexts.defaultDispatcher(CoroutineContexts.kt:29)
    at org.springframework.kotlin.experimental.coroutine.context.CoroutineContexts$$EnhancerBySpringCGLIB$$f8f15d29.CGLIB$defaultDispatcher$0(<generated>)
    at org.springframework.kotlin.experimental.coroutine.context.CoroutineContexts$$EnhancerBySpringCGLIB$$f8f15d29$$FastClassBySpringCGLIB$$1814e945.invoke(<generated>)
    at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)
    at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:365)
    at org.springframework.kotlin.experimental.coroutine.context.CoroutineContexts$$EnhancerBySpringCGLIB$$f8f15d29.defaultDispatcher(<generated>)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
    ... 25 common frames omitted

It might be a breaking change from coroutines itself but bug fixes they have are critical.