@@ -25,6 +25,7 @@ namespace Elastic.Clients.Elasticsearch.Cluster;
25
25
26
26
internal sealed partial class ClusterStatsResponseConverter : System . Text . Json . Serialization . JsonConverter < Elastic . Clients . Elasticsearch . Cluster . ClusterStatsResponse >
27
27
{
28
+ private static readonly System . Text . Json . JsonEncodedText PropCcs = System . Text . Json . JsonEncodedText . Encode ( "ccs" ) ;
28
29
private static readonly System . Text . Json . JsonEncodedText PropClusterName = System . Text . Json . JsonEncodedText . Encode ( "cluster_name" ) ;
29
30
private static readonly System . Text . Json . JsonEncodedText PropClusterUuid = System . Text . Json . JsonEncodedText . Encode ( "cluster_uuid" ) ;
30
31
private static readonly System . Text . Json . JsonEncodedText PropIndices = System . Text . Json . JsonEncodedText . Encode ( "indices" ) ;
@@ -36,6 +37,7 @@ internal sealed partial class ClusterStatsResponseConverter : System.Text.Json.S
36
37
public override Elastic . Clients . Elasticsearch . Cluster . ClusterStatsResponse Read ( ref System . Text . Json . Utf8JsonReader reader , System . Type typeToConvert , System . Text . Json . JsonSerializerOptions options )
37
38
{
38
39
reader . ValidateToken ( System . Text . Json . JsonTokenType . StartObject ) ;
40
+ LocalJsonValue < Elastic . Clients . Elasticsearch . Cluster . CCSStats > propCcs = default ;
39
41
LocalJsonValue < string > propClusterName = default ;
40
42
LocalJsonValue < string > propClusterUuid = default ;
41
43
LocalJsonValue < Elastic . Clients . Elasticsearch . Cluster . ClusterIndices > propIndices = default ;
@@ -45,6 +47,11 @@ public override Elastic.Clients.Elasticsearch.Cluster.ClusterStatsResponse Read(
45
47
LocalJsonValue < long > propTimestamp = default ;
46
48
while ( reader . Read ( ) && reader . TokenType is System . Text . Json . JsonTokenType . PropertyName )
47
49
{
50
+ if ( propCcs . TryReadProperty ( ref reader , options , PropCcs , null ) )
51
+ {
52
+ continue ;
53
+ }
54
+
48
55
if ( propClusterName . TryReadProperty ( ref reader , options , PropClusterName , null ) )
49
56
{
50
57
continue ;
@@ -92,6 +99,7 @@ public override Elastic.Clients.Elasticsearch.Cluster.ClusterStatsResponse Read(
92
99
reader . ValidateToken ( System . Text . Json . JsonTokenType . EndObject ) ;
93
100
return new Elastic . Clients . Elasticsearch . Cluster . ClusterStatsResponse ( Elastic . Clients . Elasticsearch . Serialization . JsonConstructorSentinel . Instance )
94
101
{
102
+ Ccs = propCcs . Value ,
95
103
ClusterName = propClusterName . Value ,
96
104
ClusterUuid = propClusterUuid . Value ,
97
105
Indices = propIndices . Value ,
@@ -105,6 +113,7 @@ public override Elastic.Clients.Elasticsearch.Cluster.ClusterStatsResponse Read(
105
113
public override void Write ( System . Text . Json . Utf8JsonWriter writer , Elastic . Clients . Elasticsearch . Cluster . ClusterStatsResponse value , System . Text . Json . JsonSerializerOptions options )
106
114
{
107
115
writer . WriteStartObject ( ) ;
116
+ writer . WriteProperty ( options , PropCcs , value . Ccs , null , null ) ;
108
117
writer . WriteProperty ( options , PropClusterName , value . ClusterName , null , null ) ;
109
118
writer . WriteProperty ( options , PropClusterUuid , value . ClusterUuid , null , null ) ;
110
119
writer . WriteProperty ( options , PropIndices , value . Indices , null , null ) ;
@@ -130,6 +139,17 @@ internal ClusterStatsResponse(Elastic.Clients.Elasticsearch.Serialization.JsonCo
130
139
_ = sentinel ;
131
140
}
132
141
142
+ /// <summary>
143
+ /// <para>
144
+ /// Cross-cluster stats
145
+ /// </para>
146
+ /// </summary>
147
+ public
148
+ #if NET7_0_OR_GREATER
149
+ required
150
+ #endif
151
+ Elastic. Clients . Elasticsearch . Cluster . CCSStats Ccs { get ; set ; }
152
+
133
153
/// <summary>
134
154
/// <para>
135
155
/// Name of the cluster, based on the cluster name setting.
0 commit comments