Uploaded image for project: 'RESTEasy'
  1. RESTEasy
  2. RESTEASY-2459

MonoRxInvoker should be lazy

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 4.5.0.Final
    • None
    • None
    • None

      MonoRxInvoker was originally created by following SingleRxInvoker (RxJava2); however, it turns out that it is doing eager processing.  In Reactor, unless there is a specific reason, the pipeline should be lazy.

       
      For instance, the following code starts making the http call before a subscription starts:

       

      final Mono<Response> mono = client.target(generateURL("/hello")).request().rx(MonoRxInvoker.class).get();
      

       

      It should instead wait for the subscription to start the http call:

      mono.subscribe();
      

              rhn-support-asoldano Alessio Soldano
              gurselan Anil Gursel (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: