java - chunking XML and loading it into relational tables -


i work credit union (roughly 60k accounts). statement process '70s , tightly coupled data layout. in short, run job , produces text file contains statement each account. i've modified mainframe config , instead of getting text out, xml so:

<statements>     <statement account='1'>        ...statement info checking/savings/certificate/visa/loan/heloc shares     </statement>     <statement account='n'>        ...statement info checking/savings/certificate/visa/loan/heloc shares     </statement> </statements> 

i wrote java code pull data relational table(s) , build pdfs on fly itext. of data shows on statement calculated data in xml. instance, xml contains transactions on share. on statement, want show number of credits , number of debits. once loaded db, can use view calculate these values on fly , provide data java app.

this xml file ~900mb , going grow add more members.

i want process xml 1 "statement" @ time. http://mrico.eu/entry/parsing_chunks_of_xml_documents

can jaxb parse large xml files in chunks)

once have individual statement, want load it's shares (checking, savings, visa, etc) corresponding db tables.

seems simplest way accomplish bind statement pojo , each complex element (share or transaction or loan) in pojo, insert.

what combination of parser / binder / persistence tools guys recommend?

personally, i'd favor raw jdbc inserts, question of parser , binder more important.

note: create schema xml, might fragile due way mainframe builds xml file. using fiserv's spectrum software feels pain.

have @ stax streaming api xml.


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -