Hello,
in an application, I open some files and try to save them. After those changes take place, I get a bunch of NotSerializableExceptions. They don’t seem to have much impact besides that the session is lost (-> reload application). Because this is getting annoying, I started some research and activated a more detailed output. It seems like the Exception is thrown, because Vaadin tries to store an object, which is just added to a to a “Select” (at least, the HashMap in this output has 3 values, which are shown in a Select on the UI):
Caused by: java.io.NotSerializableException: defaultPackage.FileChanger
- custom writeObject data (class "java.util.HashMap")
- object (class "java.util.HashMap", {defaultPackage.FileChanger@14f16cf=JSON Schema, defaultPackage.FileChanger@16271bb=JSON Object, defaultPackage.FileChanger@18cb79=Wsdl})
- field (class "com.vaadin.ui.AbstractSelect", name: "itemCaptions", type: "class java.util.HashMap")
- object (class "com.vaadin.ui.OptionGroup", null)
- custom writeObject data (class "java.util.HashMap")
- object (class "java.util.HashMap", {null=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@1f49560, null=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@7ad6bb, com.vaadin.ui.HorizontalLayout@ffa991=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@a79b8b})
- field (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", name: "childData", type: "class java.util.HashMap")
- object (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState@84854a)
- field (class "com.vaadin.server.AbstractClientConnector", name: "sharedState", type: "class com.vaadin.shared.communication.SharedState")
- object (class "com.vaadin.ui.VerticalLayout", com.vaadin.ui.VerticalLayout@1d8dce9)
- custom writeObject data (class "java.util.HashMap")
- object (class "java.util.HashMap", {com.vaadin.ui.HorizontalLayout@8f4f2d=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@19de19a, com.vaadin.ui.VerticalLayout@1d8dce9=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@4686ea})
- field (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", name: "childData", type: "class java.util.HashMap")
- object (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState@18be6ec)
- field (class "com.vaadin.server.AbstractClientConnector", name: "sharedState", type: "class com.vaadin.shared.communication.SharedState")
- object (class "com.vaadin.ui.HorizontalLayout", com.vaadin.ui.HorizontalLayout@9714ab)
- custom writeObject data (class "java.util.HashMap")
- object (class "java.util.HashMap", {com.vaadin.ui.VerticalLayout@cdee08=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@5bc154, com.vaadin.ui.HorizontalLayout@9714ab=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@1f18dad})
- field (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", name: "childData", type: "class java.util.HashMap")
- object (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState@1ee42ad)
- field (class "com.vaadin.server.AbstractClientConnector", name: "sharedState", type: "class com.vaadin.shared.communication.SharedState")
- object (class "com.vaadin.ui.VerticalLayout", com.vaadin.ui.VerticalLayout@49bb18)
- field (class "com.vaadin.ui.AbstractSingleComponentContainer", name: "content", type: "interface com.vaadin.ui.Component")
- object (class "at.wmfsoftware.cct.ui.DevelopmentTab", at.wmfsoftware.cct.ui.DevelopmentTab@55e48d)
- custom writeObject data (class "java.util.ArrayList")
- object (class "java.util.ArrayList", [com.vaadin.ui.TabSheet@b2100c, at.wmfsoftware.cct.ui.UserInterfaceTab@1b6ad84, at.wmfsoftware.cct.ui.DevelopmentTab@55e48d, at.wmfsoftware.cct.ui.TestingTab@dca0c8]
)
- field (class "com.vaadin.ui.TabSheet", name: "components", type: "class java.util.ArrayList")
- object (class "com.vaadin.ui.TabSheet", com.vaadin.ui.TabSheet@608c64)
- custom writeObject data (class "java.util.HashMap")
- object (class "java.util.HashMap", {com.vaadin.ui.TabSheet@608c64=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@1a18b56, com.vaadin.ui.HorizontalLayout@1d18c85=com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState$ChildComponentData@c2f041})
- field (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", name: "childData", type: "class java.util.HashMap")
- object (class "com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState", com.vaadin.shared.ui.orderedlayout.AbstractOrderedLayoutState@111cd1b)
- field (class "com.vaadin.server.AbstractClientConnector", name: "sharedState", type: "class com.vaadin.shared.communication.SharedState")
- object (class "com.vaadin.ui.VerticalLayout", com.vaadin.ui.VerticalLayout@a108d0)
- field (class "com.vaadin.ui.AbstractSingleComponentContainer", name: "content", type: "interface com.vaadin.ui.Component")
- object (class "at.wmfsoftware.cct.ui.CCTUI", at.wmfsoftware.cct.ui.CCTUI@14d54de)
- custom writeObject data (class "java.util.HashMap")
- object (class "java.util.HashMap", {0=at.wmfsoftware.cct.ui.CCTUI@14d54de})
- field (class "com.vaadin.server.VaadinSession", name: "uIs", type: "interface java.util.Map")
- root object (class "com.vaadin.server.VaadinSession", com.vaadin.server.VaadinSession@13af2c0)
Why is that? It can’t be, that Vaadin stores everything used in the application and therefor has to be Serializable…
Thanks
Wolfgang