!!! WARNING !!!
TL;DR: Users of plugin version 2.6.1 through 2.6.3 should upgrade to version 2.6.5.
Plugin versions 2.6.1 to 2.6.3 are incompatible with the "autowatch" feature in JIRA 7+. If you are unable to update to a newer version, disable the "autowatch" feature in JIRA 7+. A user with "autowatch" enabled can cause users to be unable to be removed as watchers. This issue was fixed in version 2.6.5.
Welcome to the JIRA Watcher Field Plugin Wiki. This plugin adds a custom field type that allows watchers to be modified on issue creation/modification.
- Install the plugin via the Atlassian Marketplace
- Add a new custom field of type "Watcher Field", fill out the custom field details, and add it to some screens.
For more detailed instruction, follow the Atlassian guide for adding a custom field.
Note: It is recommended to test upgrading in a testing/staging environment first before upgrading production installations.
Here are the steps I recommend when upgrading JIRA:
Check add-on compatibility with application updates guide to check for compatibility. If you find that the plugin is not compatible and upgrading fails, try disabling the plugin for the upgrade. See issue 32 for more info.
I recommend, with any kinda of mission critical JIRA installation, to follow the instructions in the Upgrading JIRA with a Fallback Method guide. Otherwise, I would follow the directions in the Upgrading JIRA guide that best apply to your install.
Update and re-enable the plugin, if needed.
This field acts the same as any old "Multi User Picker" field, except it contains a list of all the watchers on an issue. When creating an issue, it will be blank. When modifying an issue, it will be populated with the watchers of that issue, if they exist. Removing names from the field will also remove them as watchers on update. Only users that have the "Manage Watcher List" permission have access to this field. If a user does not have permissions, they will only see the message "You do not have permission to manage the watcher list." with a list of the current watchers.
The watcher field plugin as a few configuration options available. To access...
- Click on the cog in the top right corner ("Administration").
- Click on the "Add-ons" tab.
- Under the "WATCHER FIELD" section on the left, click on "Watcher Field Settings".
You will find the following settings:
- Allow JIRA to add watchers independently.
- Useful for adding watchers to issues without using a logged in user. I.e., email processing.
- Allow users to be added as watchers regardless of Browse Issue permissions
- This settings allows users to be added as watcher regardless of their permission.
- Allow deactivated users to be added/ignored as watchers.
- This setting allows inactive users to be added to new issues or ignored if editing an existing issue
Below you'll find information on specific versions of the plugin. Please read before upgrading between revisions. Some major changes have been made between revisions.
Enabled ability to set default value.
Fixed issue where custom field would always cause an update even if field was not updated.
- Can be used to search for watchers. Inspiration from http://confluence.atlassian.com/display/JIRAEXT/Voters+and+Watchers+Custom+Field.
- Can be used anywhere else a custom user field can be used (issue security, project roles, permissions/notification scheme, etc).
- Fixed issue where field would prevent progressing in a transition when used in a transition screen. See https://developer.atlassian.com/jira/browse/JWF-4 for more info.
- Fixed issue where field would be recorded as edited in history even if no change was made. See https://developer.atlassian.com/jira/browse/JWF-5 for more info.
Made compatible with JIRA 3.13.3-3.13.5
Be Careful This is for existing users of the JIRA Watcher Field Plugin. If you are a new user and are using JIRA 4.0, please use version 2.0 of the plugin.
Made compatible with JIRA 4.0
Be Careful This is for new users of the JIRA Watcher Field Plugin. If you are an existing user and are using JIRA 4.0, please use version 1.4.0 of the plugin.
Made compatible with JIRA 4.0
Be Careful If you are a new user or upgrading from version 2.0, use version 2.1. Made compatible with JIRA 4.1 Added REST call to query watchers of an issue. Dynamically updates an issue when modifying the watcher list.
Be Careful If you are a upgrading from version 1.4.0, use version 1.4.1. Made compatible with JIRA 4.1 Added REST call to query watchers of an issue. Dynamically updates an issue when modifying the watcher list.
- Made compatible with JIRA 4.2
Please read if using version 1.x of the plugin
I can't seem to be able to create a 1.x version of the plugin (for users of the plugin from back in 3.13.x) because it seems that Atlassian does not allow for 3rd party plugins to share the same namespace as theirs in version 4.2. I suppose it was inevitable at some point.
So, if you need to upgrade and you are using a version 1.x then you have a few options that I can think of: Note: BACKUP YOUR DATA FIRST and remember to ALWAYS test upgrading in a sandbox (or test) environment first.
Recreate the watcher field
This will require you to have to recreate the watcher field and everywhere it is used. There should be no reason for this to mess up any of your watcher settings. 1. Remove the old watcher field 1. Delete the old plugin 1. Install the new one.
Change the namespace in an XML backup.
This could require a lot of downtime depending on the size of your installation. Remember it's always best to modify a copy...not the original.
- Turn off the ability for users to login (remove jira-users from the global permissions section, I think). This makes sure that your XML backup is up to date.
- Make an XML backup of JIRA
- Using your favorite text editor, replace all references of "com.atlassian.jira.issue.customfields.impl.jira-watcher-field:watcherfieldtype" with "com.burningcode.jira.issue.customfields.impl.jira-watcher-field:watcherfieldtype".
- Re-import the XML backup.
- Turn on ability for users to login
Sorry everyone. I understand that this is frustrating, but, my hands are tied. Feel free to download the source yourself and see if you can get it working with the old namespace.
Change the namespace in the database (dangerous!)
This "should" change the namespace everywhere so you can use your existing watcher field. That being said...I can't promise anything. If you play around in the database and break something then I'm not responsible. Do yourself a favor and test this first in a test environment. Please.
A great way to find out what records you'll have to change is to find all references in an XML backup for "com.atlassian.jira.issue.customfields.impl.jira-watcher-field:watcherfieldtype". The XML node for the record is usually a good indication of the table where the change needs to be made and the node should have an "id" attribute of the record in the table.
- Shutdown JIRA
- Find the "CustomField" table in the database and change all references to "com.atlassian.jira.issue.customfields.impl.jira-watcher-field:watcherfieldtype" to "com.burningcode.jira.issue.customfields.impl.jira-watcher-field:watcherfieldtype". If you find any other references, you should change those too.
- Install new version of the plugin and start JIRA.
- Cross fingers.
- Updated plugin to support JIRA 4.3
- See version 2.3 for information on upgrading from using version 1.x of the plugin.
Resolves JWFP-19; https://studio.plugins.atlassian.com/browse/JWFP-19.
- Updated plugin to support JIRA 5.0
- Resolves JWFP-19; https://studio.plugins.atlassian.com/browse/JWFP-13 (Please read if generating issues via email)
- Fixed an issue where a InvalidPropertyTypeException exception was being thrown when viewing the field.
- Resolves JWFP-26|https://studio.plugins.atlassian.com/browse/JWFP-26
A big difference in this release is the field checks that watchers have the ability to browse the issue/project before being added. This is the way JIRA does it and the field was being used as a workaround for this (JWFP-22).
This release is also a bit different in that the watcher field is no longer displayed when viewing an issue (or screen). The reason for this is JIRA already provides a good way to view watchers. Also, trying to get the watcher field to be wired up when toggling watchers or inline editing was causing headaches with little benefit.
#4, #5: Added setting for enabling adding users as watchers that do not have browse issue permissions. Off by default.
- Re-added the watcher field to be included in the issue screen.
- Improved and fixed bugs in the watcher validation
- Add compatibility for JIRA 6
- Fix the Watcher Field Settings link not being displayed.
- Updated to support JIRA 6.2.
- Added "#disable_html_escaping()" to the velocity templates.
Run the following command from the command line to download a copy of the source.
git clone https://bitbucket.org/rbarham/jira-watcher-field-plugin.git