Originally posted by Darya Akbari:
What benefits do I have using iText and not DocBook XML?
If I were you, I'd stick to DocBook XML as the source format for creating your PDFs. DocBook is an XML standard; iText also has (limited) XML2PDF functionality, but it's more suited in cases where you have custom XML, or when there's no XML involved at all.
For instance: at Ghent University, we have to generate a lot of large documents from a database with thousands of records. We have 27,000 students, and every year the database grows with about 250,000 curriculum records, one for each course following by these 27,000 students.
These documents are generated online, in a web application. Generating an XML file with such a large amount of data, and then converting this XML to PDF is very expensive in CPU, memory, and time. We can't afford this; especially in the short period between the examination of the last student and the proclamation of the results of the first student, we need to produce hundreds of thousands of pages. This is a very stressful period for all the administrators involved. They want their 100 page grading/deliberation/proclamation lists in a few seconds, not in a few minutes. That's when iText is at its best.
With DocBook, you can create a document that has hundreds of pages, but I assume that time isn't a critical element. I also assume that you don't need real PDF functionality, like Optional Content, forms, digital signatures,... You are just using PDF because it's a nice format for printing. But PDF is more than just that.
You could keep DocBook XML as the source to create your PDF (with another tool than iText), and use iText for post processing: to add encryption, to concatenate/split/burst PDFs, to sign a PDF document (digitally), to add a watermark,...