B
Bob Johnson
I would appreciate your thoughts, perspectives, and opinions on the two
design alternatives described below for the following requirement (to be
implemented in a distributed system with both a Windows Forms and an ASP.NET
client (Framework 2.0).
I have a requirement to enable users to start a series of steps, complete x
of y of the steps, then come back and finish the series at some later time.
More specifically, the users can submit a work request. The request must
then be approved by a manager. After preliminary approval, users can proceed
to add further details to the request, then submit for final approval. Once
final approval is obtained - the data can be stored in a database. The
customer wants no "incomplete requests in the database."
I am considering the following two solution designs:
DESIGN 1 ------------------
have some sort of "flag" in the database that indicates the current status
of the work request. The client app can then account for the current value
of the flag and respond accordingly (i.e., presenting the user with the
appropriate "next step" given the current flag value).
DESIGN2 ------------------
Have no such "flag" (as described in option 1 above), and instead model the
work request - in the database - as if it is always in a
final/completed/approved state. In fact, the request never makes it into the
normalized database tables until it is in the final/approved state. Before
requests reach that final/approved state, however, all of the client objects
comprising work requests that are "in progress" get serialized (perhaps in a
binary stream written to a BLOB column). So in action it would look like
this:
STEP 1 - end-user creates a new work request and inters
preliminary/required data. Client objects are then serialized when end-user
session ends. Manger is notified of pending work request needing preliminary
approval.
STEP 2 - manager fires up application; client objects comprising the work
request are deserialized. Manager then approves and updates object state.
Objects are then serialized.
STEP 3 - end-user then opens approved work request; objects are
deserialized. Final state changes are made; then objects are serialized.
STEP 4 - Objects are deserialized; manager gives final approval and makes
final state changes to the objects. This final/approved work request is then
saved to the normalized database tables.
So withi Design 2, the first time the normalized database tables see this
work request, it is in a final/approved state, with all required values in
place.
Thanks for your time and consideration.
-Bob
design alternatives described below for the following requirement (to be
implemented in a distributed system with both a Windows Forms and an ASP.NET
client (Framework 2.0).
I have a requirement to enable users to start a series of steps, complete x
of y of the steps, then come back and finish the series at some later time.
More specifically, the users can submit a work request. The request must
then be approved by a manager. After preliminary approval, users can proceed
to add further details to the request, then submit for final approval. Once
final approval is obtained - the data can be stored in a database. The
customer wants no "incomplete requests in the database."
I am considering the following two solution designs:
DESIGN 1 ------------------
have some sort of "flag" in the database that indicates the current status
of the work request. The client app can then account for the current value
of the flag and respond accordingly (i.e., presenting the user with the
appropriate "next step" given the current flag value).
DESIGN2 ------------------
Have no such "flag" (as described in option 1 above), and instead model the
work request - in the database - as if it is always in a
final/completed/approved state. In fact, the request never makes it into the
normalized database tables until it is in the final/approved state. Before
requests reach that final/approved state, however, all of the client objects
comprising work requests that are "in progress" get serialized (perhaps in a
binary stream written to a BLOB column). So in action it would look like
this:
STEP 1 - end-user creates a new work request and inters
preliminary/required data. Client objects are then serialized when end-user
session ends. Manger is notified of pending work request needing preliminary
approval.
STEP 2 - manager fires up application; client objects comprising the work
request are deserialized. Manager then approves and updates object state.
Objects are then serialized.
STEP 3 - end-user then opens approved work request; objects are
deserialized. Final state changes are made; then objects are serialized.
STEP 4 - Objects are deserialized; manager gives final approval and makes
final state changes to the objects. This final/approved work request is then
saved to the normalized database tables.
So withi Design 2, the first time the normalized database tables see this
work request, it is in a final/approved state, with all required values in
place.
Thanks for your time and consideration.
-Bob