在 glassfish 4.0 中,我有一个使用 @flowscope 的有效 JSF 应用程序。流定义的示例如下:
package flow;
import javax.enterprise.inject.Produces;
import javax.faces.flow.Flow;
import javax.faces.flow.builder.FlowBuilder;
import javax.faces.flow.builder.FlowBuilderParameter;
import javax.faces.flow.builder.FlowDefinition;
import javax.inject.Named;
@Named("sintesitransiti")
public class SintesiTransitiFlow {
private static final long serialVersionUID = -7623501087369765218L;
@Produces @FlowDefinition
public Flow defineFlow(@FlowBuilderParameter FlowBuilder flowBuilder) {
String flowId = "sintesitransiti";
flowBuilder.id("", flowId);
flowBuilder.viewNode("sintesitransiti", "/dir1/sintesitransiti/sintesitransiti.xhtml").markAsStartNode();
flowBuilder.viewNode("SintesitransitiResult", "/dir1/sintesitransiti/List.xhtml");
flowBuilder.returnNode("taskFlowReturn1").
fromOutcome("/index.xhtml");
return flowBuilder.getFlow();
}
}
我升级到 glassfish 4.1 附带的 netbeans 8.02。在源代码中我不得不更改一些导入,没有其他更改。流量镜不再工作了。我没有注意到服务器日志中的任何相关错误。在我看来,流注释被简单地丢弃了。有什么建议吗?
谢谢