Skip to content

Commit

Permalink
add endpoint for export
Browse files Browse the repository at this point in the history
  • Loading branch information
guy-har committed Nov 4, 2020
1 parent 88f41e9 commit d35ed36
Show file tree
Hide file tree
Showing 2 changed files with 117 additions and 57 deletions.
88 changes: 59 additions & 29 deletions docs/assets/js/swagger.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
swagger: "2.0"

consumes:
- application/json
- application/json
info:
description: lakeFS HTTP API
title: lakeFS API
version: 0.1.0
produces:
- application/json
- application/json
schemes:
- http
- https
- http
- https
basePath: /api/v1


Expand All @@ -24,8 +24,8 @@ securityDefinitions:


security:
- basic_auth: []
- jwt_token: []
- basic_auth: [ ]
- jwt_token: [ ]

responses:
Unauthorized:
Expand Down Expand Up @@ -116,7 +116,7 @@ definitions:
format: int64
path_type:
type: string
enum: [common_prefix, object]
enum: [ common_prefix, object ]

underlying_object_properties:
type: object
Expand All @@ -130,12 +130,12 @@ definitions:
properties:
type:
type: string
enum: [added, removed, changed, conflict]
enum: [ added, removed, changed, conflict ]
path:
type: string
path_type:
type: string
enum: [common_prefix, object]
enum: [ common_prefix, object ]

revert_creation:
type: object
Expand All @@ -144,7 +144,7 @@ definitions:
properties:
type:
type: string
enum: [object, common_prefix, commit, reset]
enum: [ object, common_prefix, commit, reset ]
commit:
type: string
path:
Expand Down Expand Up @@ -279,7 +279,7 @@ definitions:
properties:
effect:
type: string
enum: [allow, deny]
enum: [ allow, deny ]
resource:
type: string
action:
Expand Down Expand Up @@ -318,12 +318,12 @@ definitions:
type: string
format: uri
x-nullable: false # Override https://github.com/go-swagger/go-swagger/issues/1188
# go-swagger totally not a bug. This causes the generated field
# *not* to be a pointer. Then the regular (incorrect, in this
# case) JSON parser parses it as an empty field, and validation
# verifies the value is non-empty. In *this particular case* it
# works because a URI cannot be empty (at least not an absolute
# URI, which is what we require).
# go-swagger totally not a bug. This causes the generated field
# *not* to be a pointer. Then the regular (incorrect, in this
# case) JSON parser parses it as an empty field, and validation
# verifies the value is non-empty. In *this particular case* it
# works because a URI cannot be empty (at least not an absolute
# URI, which is what we require).
description: export objects to this path
example: s3://company-bucket/path/to/export
exportStatusPath:
Expand All @@ -336,7 +336,7 @@ definitions:
items:
type: string
description: "list of regexps of keys to exported last in each prefix (for signalling)"
example: ["^SUCCESS$", ".*/_SUCCESS$"]
example: [ "^SUCCESS$", ".*/_SUCCESS$" ]

retention_policy:
type: object
Expand Down Expand Up @@ -369,7 +369,7 @@ definitions:
properties:
status:
type: string
enum: [enabled, disabled]
enum: [ enabled, disabled ]
filter:
type: object
properties:
Expand All @@ -389,8 +389,8 @@ definitions:
time_period:
type: object
description: |
a number of days, which can be broken up into a sum of weeks
and days
a number of days, which can be broken up into a sum of weeks
and days
properties:
weeks:
type: integer
Expand All @@ -401,10 +401,10 @@ definitions:
minProperties: 1

config:
type: object
properties:
blockstore.type:
type: string
type: object
properties:
blockstore.type:
type: string

paths:

Expand All @@ -414,7 +414,7 @@ paths:
- setup
operationId: setupLakeFS
summary: setup lakeFS and create the first user
security: []
security: [ ]
parameters:
- in: body
name: user
Expand Down Expand Up @@ -2011,12 +2011,42 @@ paths:
schema:
$ref: "#/definitions/error"

/repositories/{repository}/retention:
/repositories/{repository}/branches/{branch}/export-hook:
parameters:
- in: path
name: repository
required: true
type: string
- in: path
name: branch
required: true
type: string
post:
tags:
- export
- branches
operationId: executeContinuousExport
summary: hook to be called in order to execute continues export on branch
responses:
201:
description: continuous export successfully started
401:
$ref: "#/responses/Unauthorized"
404:
description: no branch defined at that repo
schema:
$ref: "#/definitions/error"
default:
description: generic error response
schema:
$ref: "#/definitions/error"

/repositories/{repository}/retention:
parameters:
- in: path
name: repository
required: true
type: string
put:
tags:
- retention
Expand Down Expand Up @@ -2057,14 +2087,14 @@ paths:
/healthcheck:
get:
operationId: healthCheck
security: []
security: [ ]
tags:
- healthCheck
description: check that the API server is up and running
responses:
204:
description: NoContent

/config:
get:
tags:
Expand Down
Loading

0 comments on commit d35ed36

Please sign in to comment.