commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Herre (JIRA)" <>
Subject [jira] Created: (CLI-209) OptionBuilder is not thread-safe
Date Mon, 27 Sep 2010 14:27:33 GMT
OptionBuilder is not thread-safe

                 Key: CLI-209
             Project: Commons CLI
          Issue Type: Bug
          Components: CLI-1.x
    Affects Versions: 1.2, 1.1, 1.0
         Environment: Windows XP, Java 6
            Reporter: Thomas Herre

Class OptionBuilder is not thread-safe.
It uses one OptionBuilder instance without synchronizing access to it.
If more than one thread uses OptionBuilder, that can result in invalid Options (suppose a
scheduler component).

Don't know if this should be fixed. At least the Javadoc should mention the fact that the
class is not thread-safe.
As a workaround, use constructor of class Option.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message