webwork1 "magic" for i18n is broken for v2 plugins

XMLWordPrintable

      NOTE: This suggestion is for JIRA Server. Using JIRA Cloud? See the corresponding suggestion.

      Plugins (such as the commit acceptance plugin), when converted to v2 plugins, have their i18n break if they use the "magic".

      The "magic" is that they have an action class Foo which extends JiraWebActionSupport, and a Foo.properties file right next to the class file in their jar with i18n keys, and no mention of it in code or plugin descriptor. This method of i18n "just works" for v1 plugins but breaks when you make them v2 plugins.

      When that happens, the following shows up in the logs for every key referenced:

      [INFO] [talledLocalContainer] 2011-02-16 21:52:23,785 http-2990-2 DEBUG admin 352x273x1 1wxv13h 0:0:0:0:0:0:0:1 /secure/CommitAcceptanceConfigure.jspa [commitacceptance.server.action.ConfigureAction] Cannot find key 'commitacceptance.prompt.unsavedConfig'
      

      You can reproduce this using the commit acceptance plugin source located here:
      http://svn.atlassian.com/svn/public/contrib/jira/jira-commitacceptance-plugin/trunk

      By applying the following patch:

      diff --git a/src/main/resources/atlassian-plugin.xml b/src/main/resources/atlassian-plugin.xml
      index eeefc70..d8bed9d 100644
      --- a/src/main/resources/atlassian-plugin.xml
      +++ b/src/main/resources/atlassian-plugin.xml
      @@ -1,4 +1,4 @@
      -<atlassian-plugin key="${project.groupId}.${project.artifactId}" name="${project.name}">
      +<atlassian-plugin key="${project.groupId}.${project.artifactId}" name="${project.name}" plugins-version="2">
      

      mrdon in #atlassiandev on freenode has confirmed that this should be a bug.

      Thanks!

            Assignee:
            Unassigned
            Reporter:
            Carl Myers
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: