-----Original Message-----
From: Mike Duffy [mailto:[EMAIL PROTECTED]
Sent: Wednesday, 5 July 2006 2:33 PM
To: MyFaces Discussion
Subject: Re: Backing Bean in Request Scope Persists Beyond Request

 

In a Google sarch I saw the following in a post from Craig:

 

You can accomplish that with standard managed beans my setting the <managed-bean-scope> on the

"businessDelegate" bean to be "none".  This is like the create-every-time mode of Spring ... you

always get a new instance each time the _expression_ is evaluated, and it is never placed into any

scope.

 

Craig

 

http://www.nabble.com/RE:-managed-properties-t1846249.html

 

This works; however, the only problem is that it seems like a new backing bean object is created

every time each component on the page is referenced (over twenty times for the page I am working

with).

 

Is there a better solution?

 

This is from the answer craig gave to a question I asked. It was regarding nesting managed beans inside other managed beans, certainly not for backing beans themselves (as you correctly point out it will generate a new bean on every call).

 

As far as I am aware a link is not allowed to make a POST. Therefore params should not be set this way (unless they are built into the URL which JSF does not cleanly allow for). Correct me if Im wrong, people.

 

What I think you’re attempting to do is to set a value in a backing bean based on which of your 5 links is clicked. If this is so, you should use the JSF actionListener binding.

 

If this answer is insufficient--can you post some of your jsp and faces-config source?

 

 

Dhanji.

 

Mike

 

 

This correspondence is for the named persons only.
It may contain confidential or privileged information or both.
No confidentiality or privilege is waived or lost by any mis transmission.
If you receive this correspondence in error please delete it from your system immediately and notify the sender.
You must not disclose, copy or relay on any part of this correspondence, if you are not the intended recipient.
Any opinions expressed in this message are those of the individual sender except where the sender expressly,
and with the authority, states them to be the opinions of the Department of Emergency Services, Queensland.

Reply via email to