@@ -29,7 +29,6 @@ public class IndexLifecycleExplainResponse implements ToXContentObject, Writeabl
29
29
private static final ParseField INDEX_FIELD = new ParseField ("index" );
30
30
private static final ParseField MANAGED_BY_ILM_FIELD = new ParseField ("managed" );
31
31
private static final ParseField POLICY_NAME_FIELD = new ParseField ("policy" );
32
- private static final ParseField SKIP_FIELD = new ParseField ("skip" );
33
32
private static final ParseField LIFECYCLE_DATE_FIELD = new ParseField ("lifecycle_date" );
34
33
private static final ParseField PHASE_FIELD = new ParseField ("phase" );
35
34
private static final ParseField ACTION_FIELD = new ParseField ("action" );
@@ -47,22 +46,20 @@ public class IndexLifecycleExplainResponse implements ToXContentObject, Writeabl
47
46
(String ) a [0 ],
48
47
(boolean ) a [1 ],
49
48
(String ) a [2 ],
50
- (boolean ) (a [ 3 ] == null ? false : a [3 ]),
51
- (Long ) ( a [4 ]) ,
49
+ (Long ) (a [3 ]),
50
+ (String ) a [4 ],
52
51
(String ) a [5 ],
53
52
(String ) a [6 ],
54
53
(String ) a [7 ],
55
- (String ) a [8 ],
54
+ (Long ) ( a [8 ]) ,
56
55
(Long ) (a [9 ]),
57
56
(Long ) (a [10 ]),
58
- (Long ) (a [11 ]),
59
- (BytesReference ) a [12 ],
60
- (PhaseExecutionInfo ) a [13 ]));
57
+ (BytesReference ) a [11 ],
58
+ (PhaseExecutionInfo ) a [12 ]));
61
59
static {
62
60
PARSER .declareString (ConstructingObjectParser .constructorArg (), INDEX_FIELD );
63
61
PARSER .declareBoolean (ConstructingObjectParser .constructorArg (), MANAGED_BY_ILM_FIELD );
64
62
PARSER .declareString (ConstructingObjectParser .optionalConstructorArg (), POLICY_NAME_FIELD );
65
- PARSER .declareBoolean (ConstructingObjectParser .optionalConstructorArg (), SKIP_FIELD );
66
63
PARSER .declareLong (ConstructingObjectParser .optionalConstructorArg (), LIFECYCLE_DATE_FIELD );
67
64
PARSER .declareString (ConstructingObjectParser .optionalConstructorArg (), PHASE_FIELD );
68
65
PARSER .declareString (ConstructingObjectParser .optionalConstructorArg (), ACTION_FIELD );
@@ -90,23 +87,22 @@ public class IndexLifecycleExplainResponse implements ToXContentObject, Writeabl
90
87
private final Long phaseTime ;
91
88
private final Long actionTime ;
92
89
private final Long stepTime ;
93
- private final boolean skip ;
94
90
private final boolean managedByILM ;
95
91
private final BytesReference stepInfo ;
96
92
private final PhaseExecutionInfo phaseExecutionInfo ;
97
93
98
- public static IndexLifecycleExplainResponse newManagedIndexResponse (String index , String policyName , boolean skip , Long lifecycleDate ,
94
+ public static IndexLifecycleExplainResponse newManagedIndexResponse (String index , String policyName , Long lifecycleDate ,
99
95
String phase , String action , String step , String failedStep , Long phaseTime , Long actionTime , Long stepTime ,
100
96
BytesReference stepInfo , PhaseExecutionInfo phaseExecutionInfo ) {
101
- return new IndexLifecycleExplainResponse (index , true , policyName , skip , lifecycleDate , phase , action , step , failedStep , phaseTime ,
97
+ return new IndexLifecycleExplainResponse (index , true , policyName , lifecycleDate , phase , action , step , failedStep , phaseTime ,
102
98
actionTime , stepTime , stepInfo , phaseExecutionInfo );
103
99
}
104
100
105
101
public static IndexLifecycleExplainResponse newUnmanagedIndexResponse (String index ) {
106
- return new IndexLifecycleExplainResponse (index , false , null , false , null , null , null , null , null , null , null , null , null , null );
102
+ return new IndexLifecycleExplainResponse (index , false , null , null , null , null , null , null , null , null , null , null , null );
107
103
}
108
104
109
- private IndexLifecycleExplainResponse (String index , boolean managedByILM , String policyName , boolean skip , Long lifecycleDate ,
105
+ private IndexLifecycleExplainResponse (String index , boolean managedByILM , String policyName , Long lifecycleDate ,
110
106
String phase , String action , String step , String failedStep , Long phaseTime , Long actionTime ,
111
107
Long stepTime , BytesReference stepInfo , PhaseExecutionInfo phaseExecutionInfo ) {
112
108
if (managedByILM ) {
@@ -123,7 +119,6 @@ private IndexLifecycleExplainResponse(String index, boolean managedByILM, String
123
119
this .index = index ;
124
120
this .policyName = policyName ;
125
121
this .managedByILM = managedByILM ;
126
- this .skip = skip ;
127
122
this .lifecycleDate = lifecycleDate ;
128
123
this .phase = phase ;
129
124
this .action = action ;
@@ -141,7 +136,6 @@ public IndexLifecycleExplainResponse(StreamInput in) throws IOException {
141
136
managedByILM = in .readBoolean ();
142
137
if (managedByILM ) {
143
138
policyName = in .readString ();
144
- skip = in .readBoolean ();
145
139
lifecycleDate = in .readOptionalLong ();
146
140
phase = in .readOptionalString ();
147
141
action = in .readOptionalString ();
@@ -154,7 +148,6 @@ public IndexLifecycleExplainResponse(StreamInput in) throws IOException {
154
148
phaseExecutionInfo = in .readOptionalWriteable (PhaseExecutionInfo ::new );
155
149
} else {
156
150
policyName = null ;
157
- skip = false ;
158
151
lifecycleDate = null ;
159
152
phase = null ;
160
153
action = null ;
@@ -174,7 +167,6 @@ public void writeTo(StreamOutput out) throws IOException {
174
167
out .writeBoolean (managedByILM );
175
168
if (managedByILM ) {
176
169
out .writeString (policyName );
177
- out .writeBoolean (skip );
178
170
out .writeOptionalLong (lifecycleDate );
179
171
out .writeOptionalString (phase );
180
172
out .writeOptionalString (action );
@@ -200,10 +192,6 @@ public String getPolicyName() {
200
192
return policyName ;
201
193
}
202
194
203
- public boolean skip () {
204
- return skip ;
205
- }
206
-
207
195
public Long getLifecycleDate () {
208
196
return lifecycleDate ;
209
197
}
@@ -251,7 +239,6 @@ public XContentBuilder toXContent(XContentBuilder builder, Params params) throws
251
239
builder .field (MANAGED_BY_ILM_FIELD .getPreferredName (), managedByILM );
252
240
if (managedByILM ) {
253
241
builder .field (POLICY_NAME_FIELD .getPreferredName (), policyName );
254
- builder .field (SKIP_FIELD .getPreferredName (), skip );
255
242
if (builder .humanReadable ()) {
256
243
builder .field (LIFECYCLE_DATE_FIELD .getPreferredName (), new DateTime (lifecycleDate , ISOChronology .getInstanceUTC ()));
257
244
} else {
@@ -291,7 +278,7 @@ public XContentBuilder toXContent(XContentBuilder builder, Params params) throws
291
278
292
279
@ Override
293
280
public int hashCode () {
294
- return Objects .hash (index , managedByILM , policyName , skip , lifecycleDate , phase , action , step , failedStep , phaseTime , actionTime ,
281
+ return Objects .hash (index , managedByILM , policyName , lifecycleDate , phase , action , step , failedStep , phaseTime , actionTime ,
295
282
stepTime , stepInfo , phaseExecutionInfo );
296
283
}
297
284
@@ -307,7 +294,6 @@ public boolean equals(Object obj) {
307
294
return Objects .equals (index , other .index ) &&
308
295
Objects .equals (managedByILM , other .managedByILM ) &&
309
296
Objects .equals (policyName , other .policyName ) &&
310
- Objects .equals (skip , other .skip ) &&
311
297
Objects .equals (lifecycleDate , other .lifecycleDate ) &&
312
298
Objects .equals (phase , other .phase ) &&
313
299
Objects .equals (action , other .action ) &&
0 commit comments