Skip to content

Concurrent petition overlaps json response object #2

@wideawakening

Description

@wideawakening

HI,

First thanks for the Java connector schema for elFinder, it's a nice work to start with.

We're having some problems with the 'AbstractConnectorServlet' implementation, due to the class scope 'json' variable being used over multiple petitions.

This can be easily tested with the 'reload' command on elFinder (2.0-rc1), because it triggers an 'open' and 'parent' command in parallel while most of the commands are sequential. Don't know if this could be a bug but, however, the problem will also exist on concurrent environments.

To solve this we just have to provide the command's json output object when writing the result.

/ / AbstractConnectorServlet#processRequest
output(response, command.isResponseTextHtml(), command.getJson(), command.getResponseWriter());

After creating

AbstractCommand#getJSON()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions