At first I had a class along the lines of:
public class MyClass implements Serializable {
private List<Role> roles;
}
SonarQube pointed out that List
, a member of a serializable class, is not serializable itself. Fair enough, I'll switch to a serializable implementation of List
like ArrayList
.
public class MyClass implements Serializable {
private ArrayList<Role> roles;
}
At this point SonarQube is unhappy because "roles should use an interface such as 'List' rather than an implementation like 'ArrayList'" which brings me back to where I was originally.
Is there a way out of this loop?
It looks your issue was solved just two days ago.
https://jira.sonarsource.com/browse/SONARJAVA-808
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With