Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Won't Fix
-
1.0.4
-
None
Description
Currently the XMLFlowRegistrar will register all flows into the root namespace. The registrar should be able to take an explicit namespace mapping for a collection of flows and register all flows in that connection with the proper namespace. This ability should be extended to the <flow:registry/> element in the XML namespace configuration. For example:
<flow:registry>
<location path="sellitem-flow.xml"/>
</flow:registry>
would register the `sellitem-flow` flow in the root or `` namespace. Wildcards are still acceptable in the location tag.
<flow:registry>
<namespace name="/account">
<location path="/WEB-INF/account/show.xml"/>
<location path="/WEB-INF/account/delete.xml"/>
</namespace>
</flow:registry>
would register a collection of flows explicitly to a namespace. In this example there would be a `show` and a `delete` flow in the `account` namespace. Wildcards are still acceptable in the location tag.
<flow:registry>
<namespace name="/booking">
<location path="/WEB-INF/booking/main/main.xml"/>
<location path="/WEB-INF/booking/seatassignment/seatassignment.xml"/>
<location path="/WEB-INF/booking/checkout/checkout.xml"/>
</namespace>
</flow:registry>
would register `main`, `seatassignment`, and `checkout` flows in the `booking` namespace.
<flow:registry>
<namespace root="/WEB-INF"/>
</flow:registry>
/WEB-INF/
+ account/
+ show.xml
+ delete.xml
+ booking/
+ main/
+ main.xml
+ seatassignment/
+ seatassignment.xml
would register all flows in the subdirectories of `/WEB-INF/flows` to a namespace of their directories and a name of the file. In this example there would be a `show` and a `delete` flow in the `account` namespace. TODO: Decide what happens with the booking directory