Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 0947c3cd authored by Alexandre MERLIN's avatar Alexandre MERLIN
Browse files

Revert "API: do not consume log/debug when making a get on /deployment/[ID]/{logs,debugs}"

This reverts commit 7135e68d.
parent c4241a79
No related branches found
No related tags found
No related merge requests found
......@@ -95,12 +95,6 @@ module Debug
end
end
def read()
@lock.synchronize do
@output
end
end
def pop()
@lock.synchronize do
ret = @output
......@@ -188,21 +182,6 @@ module Debug
end
end
def read(node = nil)
@lock.synchronize do
if node
@debug[node]
else
ret = ''
@debug.each_key do |n|
ret << @debug[n] if @debug[n]
end
(ret.empty? ? nil : ret)
end
end
end
def empty?()
ret = true
@lock.synchronize do
......
......@@ -691,13 +691,13 @@ module Kaworkflow
error_not_found! if info[:workflows] and cluster and !info[:workflows][cluster]
if info[:workflows] and info[:workflows][cluster]
info[:workflows][cluster].output.read unless info[:workflows][cluster].done?
info[:workflows][cluster].output.pop unless info[:workflows][cluster].done?
else
log = ''
log << info[:output].read
log << info[:output].pop
if info[:workflows]
info[:workflows].each_value do |workflow|
log << workflow.output.read unless workflow.done?
log << workflow.output.pop unless workflow.done?
end
end
log
......@@ -710,7 +710,7 @@ module Kaworkflow
break if info[:error]
error_not_found! if (node and !info[:nodelist].include?(node)) or !info[:debugger]
info[:debugger].read(node)
info[:debugger].pop(node)
end
end
......@@ -774,3 +774,4 @@ module Kaworkflow
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment