You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I initiate a remote call for initialization using a Feign API in the main thread, and perform similar operations using the same Feign API in an asynchronous thread in the initialization of another class.
I am following org.springframework.cloud.context.named.NamedContextFactory#getContext obtains the lock, there will be a call to the context.refresh(), which in turn will contain another lock. At certain times, due to uncontrollable sequence, the main thread may experience a deadlock and fail to start.
Sample
@ComponentClassA {
@PostConstructpublicvoidinit() {
// Feign Api remote call
}
}
@ComponentClassB {
@PostConstructpublicvoidinit() {
Executors.newSingleThreadExecutor().execute(() -> {
// Same feign API calls
});
}
}
The text was updated successfully, but these errors were encountered:
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.
Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.
When I initiate a remote call for initialization using a
Feign API
in the main thread, and perform similar operations using the same Feign API in an asynchronous thread in the initialization of another class.I am following
org.springframework.cloud.context.named.NamedContextFactory#getContext
obtains the lock, there will be a call to thecontext.refresh()
, which in turn will contain another lock. At certain times, due to uncontrollable sequence, the main thread may experience a deadlock and fail to start.Sample
The text was updated successfully, but these errors were encountered: