aurora-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua Cohen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AURORA-1561) Observer log browser throws exception when given a path not matching expected pattern
Date Tue, 15 Dec 2015 02:00:49 GMT

    [ https://issues.apache.org/jira/browse/AURORA-1561?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15057171#comment-15057171
] 

Joshua Cohen commented on AURORA-1561:
--------------------------------------

Given our long term goal of removing the Observer entirely in favor of integrating the task
UI into the scheduler, I suspect we won't get to this, but good to track nonetheless.

> Observer log browser throws exception when given a path not matching expected pattern
> -------------------------------------------------------------------------------------
>
>                 Key: AURORA-1561
>                 URL: https://issues.apache.org/jira/browse/AURORA-1561
>             Project: Aurora
>          Issue Type: Bug
>          Components: Observer
>            Reporter: Joshua Cohen
>            Priority: Trivial
>
> E.g. trying to access {{http://192.168.33.7:1338/logs/1450144103372-vagrant-test-http_example_docker-0-aaaf5e1a-f9eb-450c-8750-4d0376a322fb/foo/bar/baz}}
fails with the following exception:
> {noformat}
> Traceback (most recent call last):
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 764, in _handle
>     return route.call(**args)
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 1575, in wrapper
>     rv = callback(*a, **ka)
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 3138, in wrapper
>     result = func(*args, **kwargs)
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 3138, in wrapper
>     result = func(*args, **kwargs)
>   File "apache/thermos/observer/http/file_browser.py", line 76, in handle_logs
>     types = self._observer.logs(task_id, process, int(run))
> ValueError: invalid literal for int() with base 10: 'bar'
> {noformat}
> It's trying to interpret 'bar' as a run id, and dying when it cannot do so. Similar failures
can be generated for other parts of the path. E.g. if the first part of the path after the
task id does not match a process the following exception is thrown:
> {noformat}
> Traceback (most recent call last):
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 764, in _handle
>     return route.call(**args)
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 1575, in wrapper
>     rv = callback(*a, **ka)
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 3138, in wrapper
>     result = func(*args, **kwargs)
>   File "/root/.pex/install/bottle-0.11.6-py2.py3-none-any.whl.e1e7f36ef104f01896f13c85c9899f9d3d0a8813/bottle-0.11.6-py2.py3-none-any.whl/bottle.py",
line 3138, in wrapper
>     result = func(*args, **kwargs)
>   File "apache/thermos/observer/http/file_browser.py", line 76, in handle_logs
>     types = self._observer.logs(task_id, process, int(run))
>   File "/root/.pex/install/twitter.common.lang-0.3.3-py2-none-any.whl.3480f0b52b6872afe1c1c2ac8f43fb78cc44a3ae/twitter.common.lang-0.3.3-py2-none-any.whl/twitter/common/lang/lockable.py",
line 13, in wrapper
>     return method(self, *args, **kw)
>   File "apache/thermos/observer/task_observer.py", line 551, in logs
>     run = self.get_run_number(runner_state, process, run)
>   File "/root/.pex/install/twitter.common.lang-0.3.3-py2-none-any.whl.3480f0b52b6872afe1c1c2ac8f43fb78cc44a3ae/twitter.common.lang-0.3.3-py2-none-any.whl/twitter/common/lang/lockable.py",
line 13, in wrapper
>     return method(self, *args, **kw)
>   File "apache/thermos/observer/task_observer.py", line 531, in get_run_number
>     if run < len(runner_state.processes[process]):
> KeyError: 'xrun_server'
> {noformat}
> Ideally we'd return a 404 for all of these cases.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message