[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-944) Parallel root conversations with dynamic conversation entries
by Christian Bauer (JIRA)
Parallel root conversations with dynamic conversation entries
-------------------------------------------------------------
Key: JBSEAM-944
URL: http://jira.jboss.com/jira/browse/JBSEAM-944
Project: JBoss Seam
Issue Type: Feature Request
Components: Core
Reporter: Christian Bauer
Priority: Minor
The use case here is two navigation links are visible on all pages and they are supposed to start new root conversations whenever they are clicked (not nest, not join). Navigation via conversation list/switcher.
<s:link action="doFoo" propagation="none"/>
<s:link action="doBar" propagation="none"/>
Mapping:
<page view-id="/mypage.xhtml">
<rule if-outcome="foo">
<begin-conversation flush-mode="MANUAL"/>
<redirect view-id="/fooConversation.xhtml"/>
</rule>
<rule if-outcome="bar">
<begin-conversation flush-mode="MANUAL"/>
<redirect view-id="/barConversation.xhtml"/>
</rule>
<page>
<page view-id="/fooConversation.xhtml">
My Name is #{fooBackingBean.name}
</page>
<page view-id="/barConversation.xhtml">
My Name is #{barBackingBean.name}
</page>
The issue is how page descriptions in conversation entries are stored, in the SeamPhaseListener after RENDER RESPONSE.
Sequence:
1. Call /mypage.xhtml and click on 'foo', a conversation is created and /fooConversation.xhtml is rendered
2. Click on 'doBar', a request is send to /fooConversation.xhtml?actionOutcome=doBar - no conversation is propagated
3. The navigation rule kicks in and does the redirect, before that happens, AFTER RENDER RESPONSE is executed and the prepareBackswitch() stores the conversation entries, /barConversation.xhtml is rendered
4. Click on 'doFoo', a request is send to /barConversation.xhtml?actionOutcome=doFoo - no conversation is propagated
5. The navigation rule kicks in and does the redirect, before that happens, AFTER RENDER RESPONSE is executed and the prepareBackswitch() stores the conversation entries, I GET EXCEPTIONS in the log because "My name is #{fooBackingBean.name}' triggers create() of fooBackingBean which can't be created without the right request parameters - the interesting part is that I still get the name from somewhere, I see it in the conversation switcher
So this could either be a bug (because visually it's working, I see the correct conversation description in the switcher UI) that involves resolving of view-id descriptions or I need a different approach to get new root conversations in parallel on every click.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
19 years
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1088) Application Framework doesn't play well with valueChangeListeners and rendered attributes
by Guy Veraghtert (JIRA)
Application Framework doesn't play well with valueChangeListeners and rendered attributes
-----------------------------------------------------------------------------------------
Key: JBSEAM-1088
URL: http://jira.jboss.com/jira/browse/JBSEAM-1088
Project: JBoss Seam
Issue Type: Bug
Components: Core, Documentation, Framework
Environment: JSF RI 1.2_04
Reporter: Guy Veraghtert
Fix For: 1.2.1.GA
When following Chapter 10 of the reference documentation (EntityHome + page parameters), strange/unwanted behavior is seen.
1) ValueChangeListeners are always invoked, even if the value didn't change (old value is always null, or the default value)
2) In some cases, fields are not update when they have a rendered attribute.
In the attached example:
- the entered lastname (only shown when the entity is already persisted) will never be persisted: the input component is not decoded because in this phase the "rendered value expression" evaluates to false (the EntityHome object has not yet an id (page parameter) injected, so it returns a new SeamTestClass).
- the valueChangeListener is always invoked because in the Process Validations Phase the EntityHome object returns a new SeamTestClass instead of the entity we are editing.
Or the documentation must be updated to clarify this issue (or to use the PageScope as suggested by Gavin (see forum)), or the implementation must be adapted so that the page parameters are injected earlier (maybe indicate in pages.xml when they must be injected?) or ...
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
19 years
[jbossseam-issues] [JBoss JIRA] Commented: (JBSEAM-265) Inject via method parameters
by Bruno E. Grossi (JIRA)
[ http://jira.jboss.com/jira/browse/JBSEAM-265?page=comments#action_12357721 ]
Bruno E. Grossi commented on JBSEAM-265:
----------------------------------------
It can be interesting in constructors, or create methods (and other methods called by seam, and not by programmer), to access other components in that restricted scope avoiding the long time association and use of those other components.
Example:
@Name("important")
@Scope(ScopeType.CONVERSATION)
public class MyMostImportantComponent {
@In(value="componentUsedOnlyToCreate", scope=ScopeType.EVENT)
private ComponentTwo componentTwo;
@Create
public void init() {
//unique location where ComponentTwo is used
}
}
That code causes instanciation of ComponentTwo for every request/event of a conversation that use MyMostImportantComponent, but this is only necessary for the creation of this second.
With this new feature, we can use:
@Name("important")
@Scope(ScopeType.CONVERSATION)
public class MyMostImportantComponent {
@Create
public void init(@In(value="componentUsedOnlyToCreate", scope=ScopeType.EVENT) ComponentTwo componentTwo) {
//use of componentTwo
}
}
> Inject via method parameters
> ----------------------------
>
> Key: JBSEAM-265
> URL: http://jira.jboss.com/jira/browse/JBSEAM-265
> Project: JBoss Seam
> Issue Type: Feature Request
> Components: Core
> Reporter: Gavin King
> Assigned To: Gavin King
>
> public void login(@In("user") User user) {
> ...
> }
> is ugly, but we should support it anyway.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
19 years