You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2018/08/10 07:30:30 UTC

[myfaces-tobago] branch master updated: Using SessionScoped, because Singleton is not passivation capable. Needed to work with WELD

This is an automated email from the ASF dual-hosted git repository.

lofwyr pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git


The following commit(s) were added to refs/heads/master by this push:
     new e3b67dd  Using SessionScoped, because Singleton is not passivation capable. Needed to work with WELD
e3b67dd is described below

commit e3b67dd3cc72d05255c296ba60aaa02211d42b17
Author: Udo Schnurpfeil <lo...@apache.org>
AuthorDate: Fri Aug 10 09:29:40 2018 +0200

    Using SessionScoped, because Singleton is not passivation capable.
    Needed to work with WELD
---
 .../main/java/org/apache/myfaces/tobago/example/demo/AstroData.java  | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/AstroData.java b/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/AstroData.java
index 152298f..46447ee 100644
--- a/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/AstroData.java
+++ b/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/AstroData.java
@@ -24,8 +24,8 @@ import com.google.gson.GsonBuilder;
 import com.google.gson.reflect.TypeToken;
 import org.apache.myfaces.tobago.model.SelectItem;
 
+import javax.enterprise.context.SessionScoped;
 import javax.inject.Named;
-import javax.inject.Singleton;
 import javax.swing.tree.DefaultMutableTreeNode;
 import java.io.InputStreamReader;
 import java.io.Serializable;
@@ -37,7 +37,8 @@ import java.util.Map;
 import java.util.stream.Collectors;
 import java.util.stream.Stream;
 
-@Singleton
+//XXX Using SessionScoped, because Singleton is not passivation capable.
+@SessionScoped
 @Named
 public class AstroData implements Serializable {