You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Janap <ja...@gmail.com> on 2008/01/02 11:07:08 UTC

Status update - Re: TabbedPanel not refreshing values


Well, after I used the t:saveState for the detailbean it is being refreshed
with the new values.
But...I also get an exception when I use the saveState.

2008-01-02 11:03:18,611 [http-8090-Processor22] ERROR
org.apache.myfaces.application.jsp.JspStateManagerImpl - Exiting
serializeView - Could not serialize state: oracle.jdbc.driver.T4CConnection
java.io.NotSerializableException: oracle.jdbc.driver.T4CConnection
	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075)
	at
java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369)
	at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341)
	at
java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
	at
java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369)
	at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341)
	at
java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
	at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
	at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
	at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291)



I implemented Serializable for all my classes. any idea where the problem
could be?

best wishes for the New Year
J


Janap wrote:
> 
> thx,
> 
> I have all my beans declared in "request" scope. The detailBean is a
> member property(with getter setter methods) of my MainBean.
> 
> Yes I am using saveState for another property in my main bean. But they
> are declared in another jsp page
> 
> 
> 
> Gerald Müllan-3 wrote:
>> 
>> Hi,
>> 
>> which scope does the detail bean have; are you using the saveState tag
>> somewhere?
>> 
>> It seems that the bean is restored from anywhere.
>> 
>> cheers,
>> 
>> Gerald
>> 
>> On Dec 28, 2007 11:23 AM, Janap <ja...@gmail.com> wrote:
>>>
>>> Hello all,
>>>
>>> I use a Datatable backed by a dataModel(no savestate or preserveModel)
>>> to
>>> show the data on the main page.
>>> To go to the detail page the user has to click on the datatable..then he
>>> is
>>> sent to a tab on the same page.
>>>
>>> So the structure is #{MainBean.dataModel} for dataTable and
>>> #{Main.detailbean} for the detail Page. I set the values of the detail
>>> Bean
>>> using commandLink( without immediate=true). The problem is that the
>>> first
>>> time they are set but the second time when I goto Main page tab and
>>> click
>>> again..the detailbean values are not updated.
>>>
>>> And yes...the new values are updated if I use t:outputText instead of
>>> t:inputText.
>>> Also..the new values are updated when I point the navigation(detailPage)
>>> to
>>> another new page. Only in the tab case it doesnt work.
>>>
>>> I tried to reload the view by adding the navigation hnadler. Uses
>>> facesContext.renderresponse...nothing works.
>>>
>>> any more ideas...
>>>
>>> thx
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14524128.html
>>> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>>>
>>>
>> 
>> 
>> 
>> -- 
>> http://www.irian.at
>> 
>> Your JSF powerhouse -
>> JSF Consulting, Development and
>> Courses in English and German
>> 
>> Professional Support for Apache MyFaces
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14575917.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.


Re: Status update - Re: TabbedPanel not refreshing values

Posted by Richard Yee <ri...@gmail.com>.
I suggest that you also consider moving the SQL from your bean completely by
creating a DAO layer and  make your bean just a value object.

-R


On 1/2/08, Janap <ja...@gmail.com> wrote:
>
>
> Yes I do.. an object of type java.sql.Connection and also Oracledriver as
> an
> object.
> i will try making them both to transient ..see if it makes a difference
>
> thx
>
>
> Richard Yee wrote:
> >
> > Do you have a Connection as a attribute of one of your beans?
> >
> > -R
> >
> > Janap wrote:
> >> Well, after I used the t:saveState for the detailbean it is being
> >> refreshed
> >> with the new values.
> >> But...I also get an exception when I use the saveState.
> >>
> >> 2008-01-02 11:03:18,611 [http-8090-Processor22] ERROR
> >> org.apache.myfaces.application.jsp.JspStateManagerImpl - Exiting
> >> serializeView - Could not serialize state:
> >> oracle.jdbc.driver.T4CConnection
> >> java.io.NotSerializableException: oracle.jdbc.driver.T4CConnection
> >>      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java
> :1075)
> >>      at
> >> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java
> :1369)
> >>      at
> >> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java
> :1341)
> >>      at
> >> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java
> :1284)
> >>      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java
> :1073)
> >>      at
> >> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java
> :1369)
> >>      at
> >> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java
> :1341)
> >>      at
> >> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java
> :1284)
> >>      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java
> :1073)
> >>      at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java
> :1245)
> >>      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java
> :1069)
> >>      at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java
> :1245)
> >>      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java
> :1069)
> >>      at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java
> :291)
> >>
> >>
> >>
> >> I implemented Serializable for all my classes. any idea where the
> problem
> >> could be?
> >>
> >> best wishes for the New Year
> >> J
> >>
> >>
> >> Janap wrote:
> >>
> >>> thx,
> >>>
> >>> I have all my beans declared in "request" scope. The detailBean is a
> >>> member property(with getter setter methods) of my MainBean.
> >>>
> >>> Yes I am using saveState for another property in my main bean. But
> they
> >>> are declared in another jsp page
> >>>
> >>>
> >>>
> >>> Gerald Müllan-3 wrote:
> >>>
> >>>> Hi,
> >>>>
> >>>> which scope does the detail bean have; are you using the saveState
> tag
> >>>> somewhere?
> >>>>
> >>>> It seems that the bean is restored from anywhere.
> >>>>
> >>>> cheers,
> >>>>
> >>>> Gerald
> >>>>
> >>>> On Dec 28, 2007 11:23 AM, Janap <ja...@gmail.com> wrote:
> >>>>
> >>>>> Hello all,
> >>>>>
> >>>>> I use a Datatable backed by a dataModel(no savestate or
> preserveModel)
> >>>>> to
> >>>>> show the data on the main page.
> >>>>> To go to the detail page the user has to click on the
> datatable..then
> >>>>> he
> >>>>> is
> >>>>> sent to a tab on the same page.
> >>>>>
> >>>>> So the structure is #{MainBean.dataModel} for dataTable and
> >>>>> #{Main.detailbean} for the detail Page. I set the values of the
> detail
> >>>>> Bean
> >>>>> using commandLink( without immediate=true). The problem is that the
> >>>>> first
> >>>>> time they are set but the second time when I goto Main page tab and
> >>>>> click
> >>>>> again..the detailbean values are not updated.
> >>>>>
> >>>>> And yes...the new values are updated if I use t:outputText instead
> of
> >>>>> t:inputText.
> >>>>> Also..the new values are updated when I point the
> >>>>> navigation(detailPage)
> >>>>> to
> >>>>> another new page. Only in the tab case it doesnt work.
> >>>>>
> >>>>> I tried to reload the view by adding the navigation hnadler. Uses
> >>>>> facesContext.renderresponse...nothing works.
> >>>>>
> >>>>> any more ideas...
> >>>>>
> >>>>> thx
> >>>>>
> >>>>> --
> >>>>> View this message in context:
> >>>>>
> http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14524128.html
> >>>>> Sent from the MyFaces - Users mailing list archive at Nabble.com.
> >>>>>
> >>>>>
> >>>>>
> >>>>
> >>>> --
> >>>> http://www.irian.at
> >>>>
> >>>> Your JSF powerhouse -
> >>>> JSF Consulting, Development and
> >>>> Courses in English and German
> >>>>
> >>>> Professional Support for Apache MyFaces
> >>>>
> >>>>
> >>>>
> >>>
> >>
> >>
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14580860.html
> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>
>

Re: Status update - Re: TabbedPanel not refreshing values

Posted by Janap <ja...@gmail.com>.
Yes I do.. an object of type java.sql.Connection and also Oracledriver as an
object.
i will try making them both to transient ..see if it makes a difference

thx


Richard Yee wrote:
> 
> Do you have a Connection as a attribute of one of your beans?
> 
> -R
> 
> Janap wrote:
>> Well, after I used the t:saveState for the detailbean it is being
>> refreshed
>> with the new values.
>> But...I also get an exception when I use the saveState.
>>
>> 2008-01-02 11:03:18,611 [http-8090-Processor22] ERROR
>> org.apache.myfaces.application.jsp.JspStateManagerImpl - Exiting
>> serializeView - Could not serialize state:
>> oracle.jdbc.driver.T4CConnection
>> java.io.NotSerializableException: oracle.jdbc.driver.T4CConnection
>> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075)
>> 	at
>> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369)
>> 	at
>> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341)
>> 	at
>> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
>> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
>> 	at
>> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369)
>> 	at
>> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341)
>> 	at
>> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
>> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
>> 	at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
>> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
>> 	at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
>> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
>> 	at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291)
>>
>>
>>
>> I implemented Serializable for all my classes. any idea where the problem
>> could be?
>>
>> best wishes for the New Year
>> J
>>
>>
>> Janap wrote:
>>   
>>> thx,
>>>
>>> I have all my beans declared in "request" scope. The detailBean is a
>>> member property(with getter setter methods) of my MainBean.
>>>
>>> Yes I am using saveState for another property in my main bean. But they
>>> are declared in another jsp page
>>>
>>>
>>>
>>> Gerald Müllan-3 wrote:
>>>     
>>>> Hi,
>>>>
>>>> which scope does the detail bean have; are you using the saveState tag
>>>> somewhere?
>>>>
>>>> It seems that the bean is restored from anywhere.
>>>>
>>>> cheers,
>>>>
>>>> Gerald
>>>>
>>>> On Dec 28, 2007 11:23 AM, Janap <ja...@gmail.com> wrote:
>>>>       
>>>>> Hello all,
>>>>>
>>>>> I use a Datatable backed by a dataModel(no savestate or preserveModel)
>>>>> to
>>>>> show the data on the main page.
>>>>> To go to the detail page the user has to click on the datatable..then
>>>>> he
>>>>> is
>>>>> sent to a tab on the same page.
>>>>>
>>>>> So the structure is #{MainBean.dataModel} for dataTable and
>>>>> #{Main.detailbean} for the detail Page. I set the values of the detail
>>>>> Bean
>>>>> using commandLink( without immediate=true). The problem is that the
>>>>> first
>>>>> time they are set but the second time when I goto Main page tab and
>>>>> click
>>>>> again..the detailbean values are not updated.
>>>>>
>>>>> And yes...the new values are updated if I use t:outputText instead of
>>>>> t:inputText.
>>>>> Also..the new values are updated when I point the
>>>>> navigation(detailPage)
>>>>> to
>>>>> another new page. Only in the tab case it doesnt work.
>>>>>
>>>>> I tried to reload the view by adding the navigation hnadler. Uses
>>>>> facesContext.renderresponse...nothing works.
>>>>>
>>>>> any more ideas...
>>>>>
>>>>> thx
>>>>>
>>>>> --
>>>>> View this message in context:
>>>>> http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14524128.html
>>>>> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>>>>>
>>>>>
>>>>>         
>>>>
>>>> -- 
>>>> http://www.irian.at
>>>>
>>>> Your JSF powerhouse -
>>>> JSF Consulting, Development and
>>>> Courses in English and German
>>>>
>>>> Professional Support for Apache MyFaces
>>>>
>>>>
>>>>       
>>>     
>>
>>   
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14580860.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.


Re: Status update - Re: TabbedPanel not refreshing values

Posted by Richard Yee <ry...@cruzio.com>.
Do you have a Connection as a attribute of one of your beans?

-R

Janap wrote:
> Well, after I used the t:saveState for the detailbean it is being refreshed
> with the new values.
> But...I also get an exception when I use the saveState.
>
> 2008-01-02 11:03:18,611 [http-8090-Processor22] ERROR
> org.apache.myfaces.application.jsp.JspStateManagerImpl - Exiting
> serializeView - Could not serialize state: oracle.jdbc.driver.T4CConnection
> java.io.NotSerializableException: oracle.jdbc.driver.T4CConnection
> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075)
> 	at
> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369)
> 	at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341)
> 	at
> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
> 	at
> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369)
> 	at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341)
> 	at
> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
> 	at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
> 	at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
> 	at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291)
>
>
>
> I implemented Serializable for all my classes. any idea where the problem
> could be?
>
> best wishes for the New Year
> J
>
>
> Janap wrote:
>   
>> thx,
>>
>> I have all my beans declared in "request" scope. The detailBean is a
>> member property(with getter setter methods) of my MainBean.
>>
>> Yes I am using saveState for another property in my main bean. But they
>> are declared in another jsp page
>>
>>
>>
>> Gerald Müllan-3 wrote:
>>     
>>> Hi,
>>>
>>> which scope does the detail bean have; are you using the saveState tag
>>> somewhere?
>>>
>>> It seems that the bean is restored from anywhere.
>>>
>>> cheers,
>>>
>>> Gerald
>>>
>>> On Dec 28, 2007 11:23 AM, Janap <ja...@gmail.com> wrote:
>>>       
>>>> Hello all,
>>>>
>>>> I use a Datatable backed by a dataModel(no savestate or preserveModel)
>>>> to
>>>> show the data on the main page.
>>>> To go to the detail page the user has to click on the datatable..then he
>>>> is
>>>> sent to a tab on the same page.
>>>>
>>>> So the structure is #{MainBean.dataModel} for dataTable and
>>>> #{Main.detailbean} for the detail Page. I set the values of the detail
>>>> Bean
>>>> using commandLink( without immediate=true). The problem is that the
>>>> first
>>>> time they are set but the second time when I goto Main page tab and
>>>> click
>>>> again..the detailbean values are not updated.
>>>>
>>>> And yes...the new values are updated if I use t:outputText instead of
>>>> t:inputText.
>>>> Also..the new values are updated when I point the navigation(detailPage)
>>>> to
>>>> another new page. Only in the tab case it doesnt work.
>>>>
>>>> I tried to reload the view by adding the navigation hnadler. Uses
>>>> facesContext.renderresponse...nothing works.
>>>>
>>>> any more ideas...
>>>>
>>>> thx
>>>>
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/TabbedPanel-not-refreshing-values-tp14524128p14524128.html
>>>> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>>>>
>>>>
>>>>         
>>>
>>> -- 
>>> http://www.irian.at
>>>
>>> Your JSF powerhouse -
>>> JSF Consulting, Development and
>>> Courses in English and German
>>>
>>> Professional Support for Apache MyFaces
>>>
>>>
>>>       
>>     
>
>