File tree Expand file tree Collapse file tree 4 files changed +11
-7
lines changed
main/java/org/graylog/plugins/views/search/views
test/java/org/graylog2/contentpacks Expand file tree Collapse file tree 4 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 1+ type = " f"
2+ message = " Keep highlighting rules in saved searches in order."
3+
4+ pulls = [" 24347" ]
Original file line number Diff line number Diff line change 2222import com .google .auto .value .AutoValue ;
2323import org .graylog .plugins .views .search .views .formatting .highlighting .HighlightingRule ;
2424
25- import java .util .Collections ;
26- import java .util .Set ;
25+ import java .util .List ;
2726
2827@ AutoValue
2928@ JsonDeserialize (builder = FormattingSettings .Builder .class )
3029public abstract class FormattingSettings {
3130 static final String FIELD_HIGHLIGHTING = "highlighting" ;
3231
3332 @ JsonProperty (FIELD_HIGHLIGHTING )
34- public abstract Set <HighlightingRule > highlighting ();
33+ public abstract List <HighlightingRule > highlighting ();
3534
3635 public static Builder builder () {
3736 return Builder .create ();
@@ -40,13 +39,13 @@ public static Builder builder() {
4039 @ AutoValue .Builder
4140 public static abstract class Builder {
4241 @ JsonProperty (FIELD_HIGHLIGHTING )
43- public abstract Builder highlighting (Set <HighlightingRule > highlightingRules );
42+ public abstract Builder highlighting (List <HighlightingRule > highlightingRules );
4443
4544 public abstract FormattingSettings build ();
4645
4746 @ JsonCreator
4847 public static Builder create () {
49- return new AutoValue_FormattingSettings .Builder ().highlighting (Collections . emptySet ());
48+ return new AutoValue_FormattingSettings .Builder ().highlighting (List . of ());
5049 }
5150 }
5251}
Original file line number Diff line number Diff line change 137137import java .util .Collections ;
138138import java .util .HashMap ;
139139import java .util .HashSet ;
140+ import java .util .List ;
140141import java .util .Map ;
141142import java .util .Set ;
142143
@@ -547,7 +548,7 @@ private EntityV1 createTestViewEntity() {
547548 .widgets (ImmutableSet .of (widgetEntity ))
548549 .widgetMapping (ImmutableMap .of ())
549550 .widgetPositions (ImmutableMap .of ())
550- .formatting (FormattingSettings .builder ().highlighting (ImmutableSet .of ()).build ())
551+ .formatting (FormattingSettings .builder ().highlighting (List .of ()).build ())
551552 .displayModeSettings (DisplayModeSettings .empty ())
552553 .build ();
553554 final ViewEntity entity = ViewEntity .builder ()
Original file line number Diff line number Diff line change @@ -316,7 +316,7 @@ private EntityV1 createViewEntity() throws Exception {
316316 .widgets (Set .of ())
317317 .widgetMapping (Map .of ())
318318 .widgetPositions (Map .of ())
319- .formatting (FormattingSettings .builder ().highlighting (Set .of ()).build ())
319+ .formatting (FormattingSettings .builder ().highlighting (List .of ()).build ())
320320 .displayModeSettings (DisplayModeSettings .empty ())
321321 .build ();
322322 String newViewId = "5def958063303ae5f68edead" ;
You can’t perform that action at this time.
0 commit comments