Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 2.0.2
-
Fix Version/s: 3.0, EE-2.0.0.GA_P01
-
Component/s: Framework
-
Labels:None
-
Environment:Jboss 6 & 7
-
Assignee Priority:P1
Description
The sample project uses a EE 6 CDI @ConversationScoped bean. When uploading a file, the conversation is terminated rendering the conversation scoped bean unusable for the purpose. Passing the cid request parameter as an f:param in the commandButton results in the upload callback method not being called.
Activity
Tyler Johnson
created issue -
Tyler Johnson
made changes -
Field | Original Value | New Value |
---|---|---|
Salesforce Case | [5007000000I18Vg] | |
Description |
The sample project uses a EE 6 CDI @ConversationScoped bean. When uploading a file, the conversation is terminated rendering the conversation scoped bean unusable for the purpose. Passing the cid request parameter as an f:param in the commandButton results in the upload callback method not being called. |
The sample project uses a EE 6 CDI @ConversationScoped bean. When uploading a file, the conversation is terminated rendering the conversation scoped bean unusable for the purpose. Passing the cid request parameter as an f:param in the commandButton results in the upload callback method not being called. |
Tyler Johnson
made changes -
Attachment | test.zip [ 13481 ] |
Tyler Johnson
made changes -
Environment | - | Jboss 6 & 7 |
Ken Fyten
made changes -
Fix Version/s | EE-2.0.0.GA_P01 [ 10271 ] | |
Fix Version/s | 2.1 [ 10241 ] | |
Assignee Priority | P2 | |
Assignee | Mark Collette [ mark.collette ] |
Ken Fyten
made changes -
Assignee Priority | P2 | P1 |
Ken Fyten
made changes -
Assignee Priority | P1 | P2 |
Ken Fyten
made changes -
Assignee Priority | P2 | P3 |
Ken Fyten
made changes -
Assignee Priority | P3 | P2 |
Ken Fyten
made changes -
Assignee | Mark Collette [ mark.collette ] | Judy Guglielmin [ judy.guglielmin ] |
Ken Fyten
made changes -
Assignee Priority | P2 | P1 |
Ken Fyten
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
using <ace:fileEntry>
with a series of <h:commandButton> markup as follows:
{conversationBean.upload}<ice:form>
<ace:fileEntry id="fileEntryComp"
relativePath="/files/"
maxFileSize="6291456"
maxFileSizeMessage="Submitted file is too large."
maxTotalSize="18874368"
maxTotalSizeMessage="Total size of submitted files is too large."
required="true"
requiredMessage="The file is required to submit this form."
useOriginalFilename="true"
fileEntryListener="#
">
</ace:fileEntry>
<h:commandButton id="submitBtn" value="PlainSubmit" type="submit"/>
{javax.enterprise.context.conversation.id}"/><h:commandButton id="cmdAttr" value="submitWithAttr" type="submit">
<f:attribute name="convIdAttribute" value="#
</h:commandButton>
<br />
<h:commandButton value="UPLOAD THAT LOSES CID ON THE WAY"
action="#{conversationBean.uploadAction}">
</h:commandButton>
<h:commandButton
value="UPLOAD THAT RETAINS CID, BUT NEVER RUNS THE ACE:FILEENTRY LISTENER METHOD"
action="#{conversationBean.uploadAction}">
<f:param name="cid"
value="#{javax.enterprise.context.conversation.id}
" />
</h:commandButton>
</ice:form>
using 3.0.0.RC2...
none of the first 3 h:commandButton's will fire until after I have used the last one (???? is there something that limits only one submit per form now?).
Last one, retains the cid, but the File is empty for the upload (even when it is not)....has this component been tested with <f:param>?? Anyways, get the File is required for this component message, so no file is created when using f:param in this use-case.
All the other options (only working once I have used the last button on the form)....have problems with the conversation being null. Tested and it is null at the very beginning of the fileListener method. (checked it first thing). I would imagine that the context may be cleaned out .
it is stored in javax.enterprise.context.conversation which becomes null as soon as you trigger the method for the fileListener.
Files are all uploaded successfully with first 3 options, but conversation is null (problem for weld/CDI).
using ICEfaces-2.0.2 release:-
(package name changed for the file entry classes between this version and 3.0.0.RC2).
I don't have to fire the last button, I can fire any of them and they will work as above.
Again, the conversation is lost for the first three but not the last, but the file is empty for the last one.
question....
how do we want this to work??? Should whatever is in the request context (like conversation) be kept as this component moves through it's processing, or do we want to allow the use of <f:param> to ensure they can maintain their parameters . Either way, neither is working at this time, but probably should decide what is going to be supported for items like conversation id propagation.