Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gutyán Gábor
/
circlestack
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
c5c8a957
authored
Mar 04, 2014
by
Dudás Ádám
Committed by
cloud
Mar 04, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
storage: fix abortable task implementation
parent
0edc8ff2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
circle/storage/tasks/local_tasks.py
+8
-8
No files found.
circle/storage/tasks/local_tasks.py
View file @
c5c8a957
...
@@ -36,18 +36,18 @@ def restore(disk, user):
...
@@ -36,18 +36,18 @@ def restore(disk, user):
disk
.
restore
(
task_uuid
=
restore
.
request
.
id
,
user
=
user
)
disk
.
restore
(
task_uuid
=
restore
.
request
.
id
,
user
=
user
)
class
create_from_url
(
AbortableTask
):
class
CreateFromURLTask
(
AbortableTask
):
def
__init__
(
self
):
self
.
bind
(
celery
)
def
run
(
self
,
**
kwargs
):
def
run
(
self
,
**
kwargs
):
Disk
=
kwargs
[
'cls'
]
Disk
=
kwargs
.
pop
(
'cls'
)
url
=
kwargs
[
'url'
]
Disk
.
create_from_url
(
url
=
kwargs
.
pop
(
'url'
),
params
=
kwargs
[
'params'
]
user
=
kwargs
[
'user'
]
Disk
.
create_from_url
(
url
=
url
,
params
=
params
,
task_uuid
=
create_from_url
.
request
.
id
,
task_uuid
=
create_from_url
.
request
.
id
,
abortable_task
=
self
,
abortable_task
=
self
,
user
=
user
)
**
kwargs
)
create_from_url
=
CreateFromURLTask
()
@celery.task
@celery.task
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment