Qore ElasticSearchDataProvider Module Reference 1.0
Loading...
Searching...
No Matches
ElasticSearchIndexCreateDataProvider.qc.dox.h
1// -*- mode: c++; indent-tabs-mode: nil -*-
3
28
31
32public:
35
37 const ProviderInfo = <DataProviderInfo>{
38 "name": "create",
39 "desc": "ElasticSearch index create API data provider",
40 "type": "ElasticSearchIndexCreateDataProvider",
42 "supports_request": True,
43 };
44
46 const ProviderSummaryInfo = cast<hash<DataProviderSummaryInfo>>(ProviderInfo{
47 AbstractDataProvider::DataProviderSummaryInfoKeys
48 });
49
52
55
57 const QueryArgs = ("wait_for_active_shards", "master_timeout", "timeout");
58
60 constructor(*hash<auto> options);
61
62
65
66
68 string getName();
69
70
72 *string getDesc();
73
74
76
81protected:
82 auto doRequestImpl(auto req, *hash<auto> request_options);
83public:
84
85
87
89protected:
91public:
92
93
95
97protected:
99public:
100
101
103 hash<DataProvider::DataProviderInfo> getStaticInfoImpl();
104
105};
106
109
110public:
111 constructor() ;
112
113};
114
117
118public:
119protected:
121 const Fields = {
122 // query parameters
123 "index": {
124 "type": StringType,
125 "desc": "The name of the index to create",
126 },
127 "wait_for_active_shards": {
128 "type": SoftStringOrNothingType,
129 "desc": "The number of shard copies that must be active before proceeding with the operation. "
130 "Set to `all` or any positive integer up to the total number of shards in the "
131 "index (number_of_replicas+1). Default: `1`, the primary shard.",
132 },
133 "master_timeout": {
134 "type": StringOrNothingType,
135 "desc": "Period to wait for a connection to the master node (default `30s`). If no response is "
136 "received before the timeout expires, the request fails and returns an error",
137 },
138 "timeout": {
139 "type": StringOrNothingType,
140 "desc": "Period to wait for a response (default `30s`). If no response is received before the "
141 "timeout expires, the request fails and returns an error",
142 },
143
144 # body parameters
145 "aliases": {
147 "desc": "The key is the alias name. Index alias names support date math",
148 },
149 "mappings": {
150 "type": AutoHashOrNothingType,
151 "desc": "Mapping for fields in the index. If specified, this mapping can include:\n"
152 "- Field names\n"
153 "- Field data types\n"
154 "- Mapping parameters",
155 },
156 "settings": {
157 "type": AutoHashOrNothingType,
158 "desc": "Configuration options for the index",
159 },
160 };
161
162public:
163
166
167};
168
171
172public:
173protected:
175 const Fields = {
176 "shards_acknowledged": {
177 "type": BoolType,
178 "desc": "Indicates whether the requisite number of shard copies were started for each shard in the "
179 "index before timing out",
180 },
181 "index": {
182 "type": StringType,
183 "desc": "The name of the index created",
184 },
185 };
186
187public:
188
191
192};
193};
The acknowledged response type.
Definition: ElasticSearchAcknowledgedDataType.qc.dox.h:28
const ConstructorOptions
Constructor options.
Definition: ElasticSearchDataProvider.qc.dox.h:64
Aliases data type.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:108
The ElasticSearch index create API data provider.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:30
const ProviderSummaryInfo
Provider summary info.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:46
constructor(RestClient::RestClient rest)
Creates the object from a REST connection.
const ResponseType
Response type.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:54
const RequestType
Request type.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:51
*DataProvider::AbstractDataProviderType getRequestTypeImpl()
Returns the description of a successful request message, if any.
constructor(*hash< auto > options)
Creates the object from constructor options.
*DataProvider::AbstractDataProviderType getResponseTypeImpl()
Returns the description of a response message, if this object represents a response message.
const QueryArgs
Query args.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:57
*string getDesc()
Returns the data provider description.
const ProviderInfo
Provider info.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:37
RestClient::RestClient rest
REST client connection.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:34
auto doRequestImpl(auto req, *hash< auto > request_options)
Makes a request and returns the response.
hash< DataProvider::DataProviderInfo > getStaticInfoImpl()
Returns data provider static info.
Create index request data type.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:116
const Fields
Field descriptions.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:121
Index create API response.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:170
const Fields
Field descriptions.
Definition: ElasticSearchIndexCreateDataProvider.qc.dox.h:175
Base data type for search request types.
Definition: ElasticSearchIndexDataTypeBase.qc.dox.h:28
Qore ElasticSearchDataProvider module definition.
Definition: ElasticSearchAcknowledgedDataType.qc.dox.h:26