Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add extend ability to query external service for autoscaler #2279

Merged
merged 34 commits into from
May 6, 2020
Merged
Show file tree
Hide file tree
Changes from 28 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
84d388c
add external ability
Apr 23, 2020
0264a9a
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 23, 2020
c487611
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 23, 2020
af0e65d
update crds
Apr 23, 2020
361d5e4
Merge branch 'add_external_ability_for_auto_scaling' of https://githu…
Apr 23, 2020
0b397b8
fix vet
Apr 23, 2020
efa7e9c
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 26, 2020
c11a39e
Merge remote-tracking branch 'upstream/master' into add_external_abil…
Apr 26, 2020
7eb3725
update document
Apr 26, 2020
adb8749
fix ineffassign
Apr 26, 2020
7c63fa5
fix e2e case
Apr 26, 2020
c142d36
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 27, 2020
5246eb0
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 28, 2020
0946afa
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
93a809a
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
e33e021
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
5ecf760
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
197fb4b
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
d0deafb
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
056e730
Update pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go
Yisaer Apr 29, 2020
d270cf3
Update pkg/autoscaler/autoscaler/query/external.go
Yisaer Apr 29, 2020
c124405
Update pkg/autoscaler/autoscaler/query/external.go
Yisaer Apr 29, 2020
3653ee2
Update pkg/autoscaler/autoscaler/query/external.go
Yisaer Apr 29, 2020
8693d11
Update pkg/autoscaler/autoscaler/query/external.go
Yisaer Apr 29, 2020
ddfb173
Update pkg/autoscaler/autoscaler/tidb_autoscaler.go
Yisaer Apr 29, 2020
6af15a4
address the comment
Apr 29, 2020
9329b8f
add timeout
Apr 29, 2020
09dfd31
fix error
Apr 29, 2020
98fbe8d
Merge branch 'master' into add_external_ability_for_auto_scaling
DanielZhangQD Apr 29, 2020
42872f2
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 30, 2020
d8ffd1e
update crd
Apr 30, 2020
d34f40c
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer Apr 30, 2020
5a32f1b
Update pkg/autoscaler/autoscaler/query/external.go
Yisaer Apr 30, 2020
c669793
Merge branch 'master' into add_external_ability_for_auto_scaling
Yisaer May 6, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
109 changes: 109 additions & 0 deletions docs/api-references/docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -2329,6 +2329,21 @@ the auto-scaling would be performed.
If not set, the default value is 5.</p>
</td>
</tr>
<tr>
<td>
<code>externalEndpoint</code></br>
<em>
<a href="#externalendpoint">
ExternalEndpoint
</a>
</em>
</td>
<td>
<em>(Optional)</em>
<p>ExternalEndpoint makes the auto-scaler controller able to query the external service
to fetch the recommended replicas for TiKV/TiDB</p>
</td>
</tr>
</tbody>
</table>
<h3 id="basicautoscalerstatus">BasicAutoScalerStatus</h3>
Expand Down Expand Up @@ -3096,6 +3111,62 @@ imported from TiDB v3.1.0</p>
</tr>
</tbody>
</table>
<h3 id="externalendpoint">ExternalEndpoint</h3>
<p>
(<em>Appears on:</em>
<a href="#basicautoscalerspec">BasicAutoScalerSpec</a>)
</p>
<p>
<p>ExternalEndpoint describes the external service endpoint
which provides the ability to get the tikv/tidb auto-scaling recommended replicas</p>
</p>
<table>
<thead>
<tr>
<th>Field</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<code>host</code></br>
<em>
string
</em>
</td>
<td>
<p>Host indicates the external service&rsquo;s host</p>
</td>
</tr>
<tr>
<td>
<code>port</code></br>
<em>
int32
</em>
</td>
<td>
<p>Port indicates the external service&rsquo;s port</p>
</td>
</tr>
<tr>
<td>
<code>tlsSecret</code></br>
<em>
<a href="#secretref">
SecretRef
</a>
</em>
</td>
<td>
<em>(Optional)</em>
<p>TLSSecret indicates the Secret which stores the TLS configuration. If set, the operator will use https
to communicate to the external service</p>
</td>
</tr>
</tbody>
</table>
<h3 id="filelogconfig">FileLogConfig</h3>
<p>
(<em>Appears on:</em>
Expand Down Expand Up @@ -7287,6 +7358,44 @@ string
<p>
<p>S3StorageProviderType represents the specific storage provider that implements the S3 interface</p>
</p>
<h3 id="secretref">SecretRef</h3>
<p>
(<em>Appears on:</em>
<a href="#externalendpoint">ExternalEndpoint</a>)
</p>
<p>
<p>SecretRef indicates to secret ref</p>
</p>
<table>
<thead>
<tr>
<th>Field</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<code>name</code></br>
<em>
string
</em>
</td>
<td>
</td>
</tr>
<tr>
<td>
<code>namespace</code></br>
<em>
string
</em>
</td>
<td>
</td>
</tr>
</tbody>
</table>
<h3 id="security">Security</h3>
<p>
(<em>Appears on:</em>
Expand Down
62 changes: 62 additions & 0 deletions manifests/crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10653,6 +10653,37 @@ spec:
tidb:
description: TidbAutoScalerSpec describes the spec for tidb auto-scaling
properties:
externalEndpoint:
description: ExternalEndpoint describes the external service endpoint
which provides the ability to get the tikv/tidb auto-scaling recommended
replicas
properties:
host:
description: Host indicates the external service's host
type: string
path:
description: Path indicates the external service's path
type: string
port:
description: Port indicates the external service's port
format: int32
type: integer
tlsSecret:
description: SecretRef indicates to secret ref
properties:
name:
type: string
namespace:
type: string
required:
- name
- namespace
type: object
required:
- host
- port
- path
type: object
maxReplicas:
description: maxReplicas is the upper limit for the number of replicas
to which the autoscaler can scale out. It cannot be less than
Expand Down Expand Up @@ -10713,6 +10744,37 @@ spec:
tikv:
description: TikvAutoScalerSpec describes the spec for tikv auto-scaling
properties:
externalEndpoint:
description: ExternalEndpoint describes the external service endpoint
which provides the ability to get the tikv/tidb auto-scaling recommended
replicas
properties:
host:
description: Host indicates the external service's host
type: string
path:
description: Path indicates the external service's path
type: string
port:
description: Port indicates the external service's port
format: int32
type: integer
tlsSecret:
description: SecretRef indicates to secret ref
properties:
name:
type: string
namespace:
type: string
required:
- name
- namespace
type: object
required:
- host
- port
- path
type: object
maxReplicas:
description: maxReplicas is the upper limit for the number of replicas
to which the autoscaler can scale out. It cannot be less than
Expand Down
95 changes: 92 additions & 3 deletions pkg/apis/pingcap/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading