spring-webflow icon indicating copy to clipboard operation
spring-webflow copied to clipboard

Get max-executions param value from Java code [SWF-1547]

Open spring-operator opened this issue 12 years ago • 2 comments

Nicolas Romanetti opened SWF-1547 and commented

From my Java code, I need to know the max-executions value as I keep track of active flows from a listener. Here is how I retrieve it currently. Could you please provide a more 'standard' way:

@Inject
public void setFlowExecutor(FlowExecutor fe) {
    // _HACK_ to retrieve the "max-executions" param present in webflow.xml conf. It is used to manage our flow menu as a FIFO.
    SessionBindingConversationManager sbcm = (SessionBindingConversationManager) ((DefaultFlowExecutionRepository) ((FlowExecutorImpl) fe)
            .getExecutionRepository()).getConversationManager();
    maxExecutions = sbcm.getMaxConversations();
}

Affects: 2.3.1

Issue Links:

  • #731 Provide a Java config alternative to the webflow-config XML namespace

spring-operator avatar May 30 '12 00:05 spring-operator

Rossen Stoyanchev commented

Added code tags.

spring-operator avatar May 30 '12 05:05 spring-operator

Rossen Stoyanchev commented

#731 may have some impact on this issue.

spring-operator avatar May 30 '12 07:05 spring-operator