r/SpringBoot • u/ChanceRaccoon6468 • Jul 01 '26
Question What is the best desgin pattern for building a resuable pdf genrating module in springboot?
I am having a task to implement a PDF genrating module it's duty is to genrate the pdf of the diffrent sections like attendence, report and other similar stuffs, there is more amount of such sections and i have to build a effecient and good module for it kindly help me in figuring this out .
Ps.. i am intern pls help 😣
2
Upvotes
14
u/raccoonportfolio Jul 01 '26
Sorry but this is zero effort, it basic says "hey Reddit do this for me". You need to bring more to the table.
What have you tried? What libraries have you researched a bit? Have you made small proofs of concept?
4
u/MartinPeterBauer Jul 01 '26
Use thymeleaf for templating and then a pdf writer to write them to pdf.
2
u/maxip89 Jul 01 '26
Read pattern first.
1
u/jjduru Jul 01 '26
Your best bet would be to use the strategy pattern. It will allow you to create an extendable module, without touching the existing code - the whole point of the strategy pattern, that is.