Uploaded image for project: 'OpenWebBeans'
  1. OpenWebBeans
  2. OWB-589

" ... requires a passivation capable dependency ..." for producer method with return type String and non serializable injected dependency

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.1.0
    • 1.1.2
    • Injection and Lookup
    • None
    • OWB 1.1.1-SNAPSHOT

    Description

      For @Produces method like:

      @Produces
      @MyOwnQualifier
      public String getSomeString(NonserializableDependency dependency) {
      return dependency.getSomeString();
      }

      I've got exception:

      "If a producer method or field of scope @Dependent returns an serializable object for injection into an injection point Method Injection Point, method name : getSomeString, Bean Owner : [String, Name:null, WebBeans Type:PRODUCERMETHOD, API Types:[java.lang.Object,java.lang.Comparable,java.io.Serializable,java.lang.CharSequence,java.lang.String], Qualifiers:[javax.enterprise.inject.Any,MyOwnQualifier]] that requires a passivation capable dependency"

      I don't understand much what does it say , but with some help from debugger OWB validates for Serializable the injected parameter in producer method - NonserializableDependency dependency in this case.

      I checked the same with WELD 1.1.1 and it works without exception.

      Attachments

        1. OWB-589-test.patch
          6 kB
          Markus Mueller

        Activity

          People

            struberg Mark Struberg
            markoc50 Martin Kočí
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: