Skip to content

JavaPropsMapper doesn't close the .properties file properly after reading #179

@fcolmenarez

Description

@fcolmenarez

When I read an object from a .properties file I can't delete the file, access is held by the JVM. The input stream isn't closed properly unlike the regular JSON parser which does close.

This came up in a scenario when we read a properties file to create the object and later needed to delete the file.

Only seems to happen under Windows 10 (Linux is NOT impacted). Java version is 8 using Open JDK 8 u242 b08.

Attached a zip file with a small maven project created in IntelliJ demonstrating the issue. Run "compile" to ensure the resources (.json, .properties files) are copied to the target folder before each run.

jackson-testing.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    PropertiesIssue related to (Java) Properties format backend

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions