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

InfluxDB 2.0: The "/sources/{sourceID}/buckets" response type is defined as "Buckets" but returns a list of "Bucket" [area/api] #12674

Closed
bednar opened this issue Mar 18, 2019 · 1 comment · Fixed by #12677
Assignees

Comments

@bednar
Copy link
Contributor

bednar commented Mar 18, 2019

The /sources/{sourceID}/buckets response type is defined as Buckets:

/sources/{sourceID}/buckets:
    get:
      tags:
        - Sources
        - Buckets
      summary: Get a sources buckets (will return dbrps in the form of buckets if it is a v1 source)
      parameters:
          - $ref: '#/components/parameters/TraceSpan'
          - in: path
            name: sourceID
            schema:
              type: string
            required: true
            description: ID of the source
          - in: query
            name: org
            description: specifies the organization of the resource
            required: true
            schema:
              type: string
      responses:
        '200':
          description: a source
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Buckets"
        '404':
          description: source not found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
        default:
          description: unexpected error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"

but HTTP response returns an array of Bucket:

-> GET 
-> http://127.0.0.1:9999/api/v2/sources/039042392f62d000/buckets

<- 200 
<- OK
<- [{
	"name": "telegraf",
	"rp": "autogen",
	"retentionPeriod": 0
}, {
	"name": "_internal",
	"rp": "monitor",
	"retentionPeriod": 604800000000000
}]
@bednar bednar changed the title InfluxDB 2.0: The "/sources/{sourceID}/buckets" response type is defined as "Buckets" but return a list of "Bucket" [area/api] InfluxDB 2.0: The "/sources/{sourceID}/buckets" response type is defined as "Buckets" but returns a list of "Bucket" [area/api] Mar 18, 2019
@kelwang
Copy link
Contributor

kelwang commented Mar 18, 2019

cc @bthesorceror

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants