• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Saving data from form beans.

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is a struts project where a user logs in, and inputs data on a set of pages. For various reasons, incomplete data cannot go to the main database.
To handle the functionality of the user pausing and resuming per his convenience, these are the solutions under consideration:
1. The data can be put into a temporary table, and later pulled out to repopulate the form beans. The problem is that the number of fields is very high, and there would be a lot of xml mappings required to convert the data back and forth.
2. Or we can serialize entire form beans - except that this would be in binary format, and if need be, there wont be any easy way of just looking at/understanding the data.
So, what I need is this:
# Is there any other better way of doing this (like maybe a specific pattern that I need to learn about)
# Are there any other pros-cons of soln 1 & 2 that I am missing.
Looking forward to hearing your opinions on this. Thanks.
[ February 20, 2004: Message edited by: Anu Ram ]
 
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess this depends on what you mean by "pausing and resuming", but could you store the form bean in the session context instead of the request context?
 
Anu Ram
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Matthew, Thanx for the reply.
What I mean by pause and resume is that he can just stop entering data, log off, log in a week later, retrieve his data and continue with it.
This data cannot go to the main database, because none of the business rules validations would have been performed on it.
And the form beans are already in session context only.
 
Anu Ram
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
To add some more info: What I am looking for is something similar to what a site like monster.com has.
A candidate is required to enter various kinds of info. But he doesn't need to enter them all the same time. He can fill in pages 1,2,3, save his profile, log off and exit. And then log in at a later date, get his half-done application, make modifications to existing data, fill in new data and continue.
Hope this info helps clarify my requirement.
Thanks!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic