Uploaded image for project: 'Shiro'
  1. Shiro
  2. SHIRO-735

Shiro does not support servlet-3.1 void method(@Suspended AsyncResponse)

    XMLWordPrintableJSON

Details

    Description

      ++When calling a method which is async (available since servlet 3.1 or even earlier), some web servers like liberty will throw a NPE.

       

      example code:

      @GET
      public void getAction(final @Suspended AsyncResponse asyncResponse) {
        asyncResponse.resume(() -> Response.ok().build());
      }

      Even before the code is executed, shiro causes a NullPointerException in some application servers, because it does not advertise it is compatible with async servlets / methods.

       

      This happens when used with the dependency shiro-servlet.

       

      FIX (PR on the way): Add async to the web_fragment.xml.

      Attachments

        Activity

          People

            Unassigned Unassigned
            bmarwell Benjamin Marwell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 40m
                40m