openwebbeans-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "George Sapountzis (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (OWB-563) producers of passivating beans fail when the declared return type is not serializable but the actual return type is
Date Sun, 10 Apr 2011 09:03:05 GMT

     [ https://issues.apache.org/jira/browse/OWB-563?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

George Sapountzis updated OWB-563:
----------------------------------

    Description: 
The following case fails at runtime with "produce return type must be Serializable":

public class MBean implements MInterface, Serializable {
}

public class MBeanProducer {

  @Produces @ConversationScoped
  public MInterface produce() { 
    return new MBean();
  }
}

I don't know what the spec says but maybe owb should check the actual return type and allow
this case.


  was:
The following case fails during deployment:

public interface MSerializableInterface extends MInterface, Serializable {
}

public class MBean implements MSerializableInterface {
}

public class MBeanProducer {

  @Produces @ConversationScoped
  public MInterface produce() { 
    return new MBean();
  }
}

I don't know what the spec says and whether such a case can be identified statically but maybe
it should be allowed.


        Summary: producers of passivating beans fail when the declared return type is not
serializable but the actual return type is  (was: producers of passivating beans fail validation
when the declared return type is not serializable but the actual return type is)

> producers of passivating beans fail when the declared return type is not serializable
but the actual return type is
> -------------------------------------------------------------------------------------------------------------------
>
>                 Key: OWB-563
>                 URL: https://issues.apache.org/jira/browse/OWB-563
>             Project: OpenWebBeans
>          Issue Type: Bug
>          Components: Context and Scopes
>    Affects Versions: 1.1.0
>            Reporter: George Sapountzis
>            Assignee: Gurkan Erdogdu
>
> The following case fails at runtime with "produce return type must be Serializable":
> public class MBean implements MInterface, Serializable {
> }
> public class MBeanProducer {
>   @Produces @ConversationScoped
>   public MInterface produce() { 
>     return new MBean();
>   }
> }
> I don't know what the spec says but maybe owb should check the actual return type and
allow this case.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message