Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Plugin Settings Exception

Jorge Jerez
Contributor
March 7, 2019

Hello

 

I'm developing a Jira plugin, and using Jira Plugin Setting, upposedly I can save setting ussing a key and an Object, but actually this make an exception 

 

String[] sta = {"Cheese", "Pepperoni", "Black Olives"};
ps.put("ARRAY_DATA", sta);

 

 

 

2 answers

1 accepted

0 votes
Answer accepted
Jorge Jerez
Contributor
March 7, 2019

Yeah, I use this class, anyway, I discovered the problem isn't in the plugin, It's because Jira only save Integer, Long, double and String , so when I try to save an Array just get an exception

0 votes
Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 7, 2019

Hello,

Do you mean that you use this class?

https://docs.atlassian.com/sal-api/2.11.2-m01/sal-api/apidocs/com/atlassian/sal/api/pluginsettings/PluginSettings.html

If so, then try to make it as a List not as an Array.

List<String> sta = Arrays.asList("Cheese", "Pepperoni", "Black Olives");
Jorge Jerez
Contributor
March 7, 2019

Yeah, I use this class, anyway, I discovered the problem isn't in the plugin, It's because Jira only save Integer, Long, double and String , so when I try to save an Array just get an exception

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, loom, AI, meeting recording, community

[NEW] Record your meetings with Loom

Welcome to great meetings, with less work. Automatically record, summarize, and share instant recaps of your meetings with Loom AI.

Learn more
AUG Leaders

Atlassian Community Events