Skip to content
This repository was archived by the owner on Apr 15, 2018. It is now read-only.
This repository was archived by the owner on Apr 15, 2018. It is now read-only.

Reduce code path through Synchronized blocks methods #11

Open
@sirinath

Description

@sirinath

When synchronised is used in a multi threaded context there will be always 1 thread in which you can perform the task without synchronisation, hence it might be better through put to store the most likely accessed in a variable called safeThread and check this before entering synchronisation block. If it is the safe thread execute without synchronized wrapper otherwise use the wrapper.

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