Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
workspaces
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ssa
workspaces
Commits
10f97616
Commit
10f97616
authored
4 years ago
by
Charlotte Hausman
Browse files
Options
Downloads
Patches
Plain Diff
workflow rest api work - requests now persist ... sort of ...
parent
ce689d31
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
services/workflow/src/workflow/server.py
+2
-2
2 additions, 2 deletions
services/workflow/src/workflow/server.py
shared/workspaces/src/workspaces/schema.py
+6
-0
6 additions, 0 deletions
shared/workspaces/src/workspaces/schema.py
with
8 additions
and
2 deletions
services/workflow/src/workflow/server.py
+
2
−
2
View file @
10f97616
...
...
@@ -59,7 +59,7 @@ class WorkflowRestService:
# all we should have to do here is take the WorkflowRequest from the context and
# hand it to WorkflowInfo to save it, but we're still conflating
# workflows and workflow requests right now
request
=
self
.
request
.
workflows
.
create_workflow_request
(
request
=
self
.
request
.
info
.
create_workflow_request
(
workflow_name
=
self
.
request
.
GET
.
get
(
'
name
'
),
argument
=
self
.
request
.
GET
.
getall
(
'
args
'
))
return
request
...
...
@@ -188,7 +188,7 @@ def main(global_config, **settings):
config
.
add_route
(
'
workflows
'
,
'
/workflows
'
)
config
.
add_route
(
'
workflow
'
,
'
/workflows/{name}
'
,
factory
=
lookup_workflow
)
config
.
add_route
(
'
create_workflow
'
,
'
/workflows/create
'
,
factory
=
lookup_workflow
)
config
.
add_route
(
'
create_workflow
'
,
'
/workflows/
{name}/
create
'
,
factory
=
lookup_workflow
)
config
.
add_route
(
'
submit_workflow
'
,
'
/workflows/{name}/submit
'
,
factory
=
lookup_workflow
)
config
.
add_route
(
'
workflow_files
'
,
'
/workflows/{name}/files
'
,
factory
=
lookup_workflow
)
config
.
add_route
(
'
workflow_file
'
,
'
/workflows/{name}/files/{filename}
'
,
factory
=
lookup_file
)
...
...
This diff is collapsed.
Click to expand it.
shared/workspaces/src/workspaces/schema.py
+
6
−
0
View file @
10f97616
...
...
@@ -443,6 +443,12 @@ class WorkflowRequest(Base):
def
set_end_time
(
self
,
time
:
str
):
self
.
end_time
=
time
def
__json__
(
self
,
request
)
->
dict
:
return
dict
(
workflow_request_id
=
self
.
workflow_request_id
,
workflow_name
=
self
.
workflow_name
,
argument
=
self
.
argument
,)
def
__repr__
(
self
):
return
f
"
<WorkflowRequest workflow_request_id=
{
self
.
workflow_request_id
}
>
"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment