Skip to content

ThreadCtx.cleanup(): when to call? #94

Closed
@rototor

Description

I got a Tomcat warning because the ThreadLocal of ThreadCtx where not destroyed when my webapp unloaded. To silence this warning (and remove the potential memory leak) I call ThreadCtx.cleanup(); in my code after I generated the PDF.

Should PdfBoxRenderer.cleanup() also remove the ThreadLocal? And should we document this somewhere, i.e. that you should call PdfBoxRenderer.cleanup() - at least in a web application?

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions