Make agent support new endpoint for gathering data #163
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This adds support for the new form of the endpoint that gathers data.
It introduces significant changes in the configuration, but everything should be backward compatible.
These changes are:
Schedulefield is not optional, as we are using the period flag at the moment.Tokenstring is also optional, as it should not be specified when using OAuth2.Endpointis being deprecated, as in the future you won't configure the endpoint for uploading data, just preflight server. At the moment it is still being used if specified, but ignored and defaulting to/api/v1/datareadingsotherwise.Serverproperty that points to the Preflight server. Defaults tohttps://preflight.jetstack.ioif not specified.OrganizationIDwhich will be used with the new endpoint.ClusterID. To be left empty if using agent tokens (as they already point to a cluster).Signed-off-by: Jose Fuentes jsfuentescastillo@gmail.com