Error Serializing Object Class Wicket
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up JavaSerializer - Error serializing object -> wicket up vote 3 down vote favorite I have a home page(BasePage) with tabs, everything works fine,I don't have any problem with the functionality of my code. But this exception annoys me and I want to get rid of it. I looked at this Error serializing object class - when running Wicket and GAE and this Wicket: how to get rid of WicketNotSerializableException? but I didn't manage to solve my problem. Can anyone help me? public class BasePage extends WebPage { public static final String PATH = "base"; public BasePage() { final List tabs = new ArrayList<>(); //add Search Item Tab tabs.add(new AbstractTab(new Model<>("Search Item")) { @Override public WebMarkupContainer getPanel(String s) { return new SearchItem(s); } }); //add Search Domain Tab tabs.add(new AbstractTab(new Model<>("Search Domain")) { @Override public WebMarkupContainer getPanel(String s) { return new SearchDomain(s); } }); AjaxTabbedPanel ajaxTabbedPanel = new AjaxTabbedPanel("tabs", tabs); add(new AjaxTabbedPanel("tabs", tabs)); } } stacktrace: 2015-08-28 11:39:48,456 [http-bio-8080-exec-12] ERROR org.apache.wicket.serialize.java.JavaSerializer - Error serializing object class com.ui.homepage.BasePage [object=[Page class = com.ui.homepage.BasePage, id = 0, render count = 1]] org.apache.wicket.core.util.objects.checker.CheckingObjectOutputStream$ObjectCheckException: The object type is not Serializable! A problem occurred while checking object with type: com.persistence.RequestEntityDAOExtra Field hierarchy is: 0 [class=com.ui.homepage.BasePage, path=0] private java.lang.Object org.apache.wicket.MarkupContainer.children [class=org.apache.wicket.extensions.ajax.markup.html.tabs.AjaxTabbedPanel, path=0:tabs] private java.lang.Object org.apache.wicket.MarkupContainer.children [class=[Ljava.lang.Object;] private org.apache.wicket.markup.html.link.PopupSettings org.apache.wicket.markup.html.link.Link.popupSettings[1] [class=com.searchpages.SearchItem, path=0:tabs:panel] private java.lang.Object org.apache.wicket.Markup
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. http://stackoverflow.com/questions/32267082/javaserializer-error-serializing-object-wicket Join them; it only takes a minute: Sign up Object Serialization Issue With Wicket up vote 0 down vote favorite 1 I am trying to pass a searchService into a Form into Wicket to use. When I run this with out the searchService being final I get no issues but I have to make it final in order to http://stackoverflow.com/questions/15123319/object-serialization-issue-with-wicket use it inside the overwritten onSubmit. final SearchService searchService = new SearchService(); Form> form = new Form("searchForm") { public void onSubmit() { List
along with components : One of the solutions to the problem would be to either make the object in question "transient" or make its class implement "Serializable" interace. In error serializing this case the object of "TestDataServiceImpl" class needs to be declared with transient modifier or its class should implement the Serializable interface. Stacktrace : 22:53:33,267 WARN [org.apache.wicket.pageStore.DefaultPageStore] (http-localhost-127.0.0.1-8080-1) Page [Page class = com.testwebapp.web.TestPage, error serializing object id = 1, render count = 1] cannot be serialized. See previous logs for possible reasons. 22:53:33,791 ERROR [org.apache.wicket.serialize.java.JavaSerializer] (http-localhost-127.0.0.1-8080-1) Error serializing object class com.testwebapp.web.TestPage [object=[Page class = com.testwebapp.web.TestPage, id = 1, render count = 1]]: org.apache.wicket.core.util.objects.checker.CheckingObjectOutputStream$ObjectCheckException: The object type is not Serializable! A problem occurred while checking object with type: com.testwebapp.service.impl.TestDataServiceImpl Field hierarchy is: 1 [class=com.testwebapp.web.TestPage, path=1] private java.lang.Object org.apache.wicket.MarkupContainer.children [class=[Ljava.lang.Object;] private final org.apache.wicket.datetime.DateConverter org.apache.wicket.datetime.markup.html.form.DateTextField.converter[2] [class=com.testwebapp.web.panel.OpportunityDetailsPanel, path=1:opportunityDetailContainer] private java.lang.Object org.apache.wicket.MarkupContainer.children [class=[Ljava.lang.Object;] private java.lang.Object org.apache.wicket.MarkupContainer.children[0] [class=com.testwebapp.web.panel.TestDetailsPanel, path=1:opportunityDetailContainer:eventDetailPanel] private java.lang.Object org.apache.wicket.MarkupContainer.children [class=[Ljava.lang.Object;] java.lang.Object org.apache.wicket.Component.data[1] [class=com.testwebapp.web.panel.TestExportRawDataPanel, path=1:opportunityDetailContainer:eventDetailPanel:supRawDataContainer] com.testwebapp.service.impl.TestDataServiceImpl com.testwebapp.web.panel.TestExportRawDataPanel.TestDataService [class=com.testwebapp.service.impl.TestDataServiceImpl] <----- field that is causing the problem at org.apache.wicket.core.util.objects.checker.CheckingObjectOutputStream.internalCheck(CheckingObjectOutputStream.java:387) [wicket-core-6.10.0.jar:6.10.0] at