Uploaded image for project: 'Quarkus'
  1. Quarkus
  2. QUARKUS-6220

Infinispan cache doesn't propagate context

XMLWordPrintable

      Per cu.

       

      ~~~

      When using the infinispan cache extension with a RequestScoped bean, the propagation context doesn't seem to be propagated, and a ContextNotActiveException is thrown.

      We believe the issue stems from this code:

      https://github.com/quarkusio/quarkus/blob/3.20/extensions/infinispan-cache/runtime/src/main/java/io/quarkus/cache/infinispan/runtime/InfinispanCacheImpl.java#L83-L86

      The use of CompletionStages does not follow the documentation's recommendations for context propagation:

      https://quarkus.io/guides/context-propagation#usage-example-for-completionstage

      The identified code is likely not the only one affected. If the bug is confirmed, it will likely be necessary to review all uses of CompletionStage in this extension.

      Original use case:

      • We use a RequestScoped bean with various information whenever a REST request is called.
      • This bean is used in a REST client filter.

      Describe the impact to you or the business
      We cannot use infinispan cache when we use RequestScope bean behind

      ~~~

              karestig@redhat.com Katia Aresti
              rhn-support-asaji Anu Saji
              Michal Vavrik Michal Vavrik
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated:
                Resolved: