Hi Igniters,

There is an issue that IgniteSpringBean deadlocks when there is CacheStore,
Service, you name it with @SpringResource annotated fields
https://issues.apache.org/jira/browse/IGNITE-6555. The issue appeared after
moving the logic for starting statically configured caches to operate in
the same way as for dynamic ones: from GridDhtPartitionsExchangeFuture.
Deadlock occurs because IgniteSpringBean having acquired internal Spring
lock waits for a GridDhtPartitionsExchangeFuture which is executed in a
separate thread and which in turn tries to inject @SpringResource annotated
fields using the passed Spring application context what leads to an attempt
to acquire the same internal Spring lock that is already being held by the
main thread.

A possible solution is to remove IgniteSpringBean#afterPropertiesSet, make
IgniteSpringBean implement SmartInitializingSingleton and start Ignite
instance inside afterSingletonsInstantiated.
The only possible problem here is that an Ignite bean cannot be
referenced from init-like methods: afterPropertiesSet, @PostConstruct etc.

Any thoughts? Suggestions?

Kind regards,
Alex.

Reply via email to