[ARVADOS] updated: a0ea5ccfc370e3a0f72e77dc6f7e6904d15a89cc
git at public.curoverse.com
git at public.curoverse.com
Mon Jun 30 19:01:22 EDT 2014
Summary of changes:
.../app/controllers/application_controller.rb | 198 ++++++------
.../app/controllers/collections_controller.rb | 16 +-
apps/workbench/app/helpers/application_helper.rb | 2 +-
apps/workbench/app/models/arvados_api_client.rb | 83 +++--
apps/workbench/app/models/arvados_base.rb | 2 +-
apps/workbench/app/views/application/404.html.erb | 21 ++
.../application/{error.json.erb => 404.json.erb} | 0
.../app/views/application/api_error.html.erb | 23 ++
.../{error.json.erb => api_error.json.erb} | 0
.../app/views/layouts/application.html.erb | 6 +-
.../test/functional/application_controller_test.rb | 7 +
.../test/functional/collections_controller_test.rb | 7 +
.../test/functional/users_controller_test.rb | 2 +-
apps/workbench/test/integration/errors_test.rb | 61 +++-
docker/api/Dockerfile | 4 +-
.../api/application.yml.in | 13 +-
docker/api/passenger.conf | 4 +-
docker/api/production.rb.in | 100 ------
docker/api/secret_token.rb.in | 12 -
docker/arvdock | 336 +++++++++++----------
docker/build_tools/Makefile | 34 +--
docker/build_tools/build.rb | 29 +-
docker/keep/Dockerfile | 14 +
docker/mkimage-debootstrap.sh | 18 +-
docker/sso/passenger.conf | 4 +-
docker/warehouse/Dockerfile | 28 --
docker/warehouse/supervisor.conf | 3 -
docker/warehouse/warehouse.conf.in | 12 -
docker/workbench/Dockerfile | 5 +-
docker/workbench/apache2_foreground.sh | 5 +
.../workbench/application.yml.in | 15 +-
docker/workbench/passenger.conf | 4 +-
sdk/cli/bin/arv | 20 +-
sdk/cli/bin/crunch-job | 2 +
.../api/app/controllers/application_controller.rb | 60 ++--
.../v1/api_client_authorizations_controller.rb | 3 +-
.../app/controllers/arvados/v1/jobs_controller.rb | 5 +-
.../app/controllers/arvados/v1/links_controller.rb | 3 +-
.../test/fixtures/api_client_authorizations.yml | 7 +
.../test/functional/application_controller_test.rb | 49 +++
40 files changed, 677 insertions(+), 540 deletions(-)
create mode 100644 apps/workbench/app/views/application/404.html.erb
copy apps/workbench/app/views/application/{error.json.erb => 404.json.erb} (100%)
create mode 100644 apps/workbench/app/views/application/api_error.html.erb
copy apps/workbench/app/views/application/{error.json.erb => api_error.json.erb} (100%)
copy services/api/config/application.yml.example => docker/api/application.yml.in (78%)
delete mode 100644 docker/api/production.rb.in
delete mode 100644 docker/api/secret_token.rb.in
create mode 100644 docker/keep/Dockerfile
delete mode 100644 docker/warehouse/Dockerfile
delete mode 100644 docker/warehouse/supervisor.conf
delete mode 100644 docker/warehouse/warehouse.conf.in
copy apps/workbench/config/application.yml.example => docker/workbench/application.yml.in (60%)
create mode 100644 services/api/test/functional/application_controller_test.rb
via a0ea5ccfc370e3a0f72e77dc6f7e6904d15a89cc (commit)
via 2c4e6de200fa8fd40eb33cd2a4470d41f27227a7 (commit)
via 426417d8de4f288f6b360006cfe61c591b5e10a1 (commit)
via 30e420e6cc547a12f2a775188f0429b3607da6c3 (commit)
via fcb35ed42449c5ad58cd9ec62ff2ed353cf9d940 (commit)
via 87a7a3fbb7cf5231fdcdcd72bc3199dc15f95b71 (commit)
via 1af624cd3a0455e729d31f76405c365900e247d0 (commit)
via 0026484279e78edb42a01bc493f8014c4a647f8d (commit)
via 5d279a0a94cb89fad73e36ad558230f7df19a0af (commit)
via 07c31b9a40457a0ef0f9aa5dd9fb63e405215ec3 (commit)
via e34bc76fa1f721aaeb494b31e361ece19cbfaa1b (commit)
via 0b6f9c28663b06e173cfe0408fe073bf050bb3ee (commit)
via c23c9c44961528c251bd22bb130cf0f1eb98a698 (commit)
via a0300343f9bdb7737834bd15f2ac62e81d9e7b01 (commit)
via abd848823a9b7d24f2d9fa9bb76eb95f5e01e947 (commit)
via f9dd018181aec09a689211200bf663a5d21c771a (commit)
via 8010ff47f31c6cb38a21cf72de6b0ab8def81d17 (commit)
via 53fa082a61545d9161644bfd9c951b1c4e828c27 (commit)
via b40c9953d3f925ff507e1780d9970b632a819907 (commit)
via 1c213d4efb7badfd31036791b40475b4b933c78f (commit)
via 1f888bb7ac651968ba4995c9a6f0bac5214d1607 (commit)
via 1384d89e5be84105fbd6a416aa21530e4b18180d (commit)
via 9b9ceec0908bdf769109d4df73b3afe1e693c631 (commit)
via 659ce826d7e04bab793a4a3ab67dcd38cf98326d (commit)
via d7c0d242bb848613d5814966162b1c8d298d644d (commit)
via 6cd7a831d12be568d8e7e32b0860d494245bdb2f (commit)
via 55e1aaff28b93822c0ee149b8c2c53d2a5d87dfc (commit)
via 4af484d2c161fe75266bef6c43325a44cd3e0afd (commit)
via 295882a5097a938c1192e933afafb98ef39564fe (commit)
via 6bc625cbc09a69ca4d9379894d463b9c021f5ec0 (commit)
via b5352280e200fcecc39a8705151a0a3eb6be6e81 (commit)
via 59fcc702a3394a53f3fc36c71e24454d8fd647be (commit)
via 756c42a9b68e7d826c30402f9bcaba3a56260848 (commit)
via c1bcfda11a5d439bf6e9eabf10ed360e917f0d43 (commit)
via 479724c95e77bb9b950879f0d90399e0abf56ddc (commit)
via 6de4e2d16c3288ddda96fff8a8bc2b757e5765d7 (commit)
from 443468308aeb1140a4a898827a0ab55e6b3d056e (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit a0ea5ccfc370e3a0f72e77dc6f7e6904d15a89cc
Merge: 4434683 2c4e6de
Author: radhika <radhika at curoverse.com>
Date: Mon Jun 30 19:00:50 2014 -0400
Merge branch 'master' into 2659-anonymous-group
Conflicts:
apps/workbench/app/controllers/application_controller.rb
apps/workbench/app/views/layouts/application.html.erb
diff --cc apps/workbench/app/controllers/application_controller.rb
index 5e845f5,7d7ea95..68e5506
--- a/apps/workbench/app/controllers/application_controller.rb
+++ b/apps/workbench/app/controllers/application_controller.rb
@@@ -346,37 -342,31 +344,40 @@@ class ApplicationController < ActionCon
if params[:id] and params[:id].match /\D/
params[:uuid] = params.delete :id
end
- if not model_class
- @object = nil
- elsif params[:uuid].is_a? String
- if params[:uuid].empty?
+ begin
+ if not model_class
+ @object = nil
+ elsif not params[:uuid].is_a?(String)
+ @object = model_class.where(uuid: params[:uuid]).first
+ elsif params[:uuid].empty?
@object = nil
+ elsif (model_class != Link and
+ resource_class_for_uuid(params[:uuid]) == Link)
+ @name_link = Link.find(params[:uuid])
+ @object = model_class.find(@name_link.head_uuid)
else
- if (model_class != Link and
- resource_class_for_uuid(params[:uuid]) == Link)
- @name_link = Link.find(params[:uuid])
- @object = model_class.find(@name_link.head_uuid)
- else
- if Thread.current[:arvados_anonymous_api_token]
- begin
- @object = model_class.find(params[:uuid])
- rescue
- # not authorized
- end
- else
- @object = model_class.find(params[:uuid])
++ if Thread.current[:arvados_anonymous_api_token]
++ begin
+ @object = model_class.find(params[:uuid])
++ rescue
++ # not authorized
+ end
++ else
++ @object = model_class.find(params[:uuid])
+ end
end
- else
- @object = model_class.where(uuid: params[:uuid]).first
+ rescue ArvadosApiClient::NotFoundException, RuntimeError => error
+ if error.is_a?(RuntimeError) and (error.message !~ /^argument to find\(/)
+ raise
+ end
+ render_not_found(error)
+ return false
end
end
def thread_clear
- Thread.current[:arvados_api_token] = nil
- Thread.current[:user] = nil
+ load_api_token(nil)
+ Thread.current[:arvados_anonymous_api_token] = nil
Rails.cache.delete_matched(/^request_#{Thread.current.object_id}_/)
yield
Rails.cache.delete_matched(/^request_#{Thread.current.object_id}_/)
diff --cc apps/workbench/app/views/layouts/application.html.erb
index d9147cc,63de6c2..08d8cf3
--- a/apps/workbench/app/views/layouts/application.html.erb
+++ b/apps/workbench/app/views/layouts/application.html.erb
@@@ -76,8 -74,6 +76,7 @@@
</li>
-->
- <% if current_user %>
+ <% if !is_anonymous %>
<li class="dropdown notification-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" id="notifications-menu">
<span class="badge badge-alert notification-count"><%= @notification_count %></span>
@@@ -116,14 -96,7 +115,11 @@@
<% end %>
</ul>
</li>
+ <% else %>
- <% if is_anonymous %>
- <li><a href="<%= arvados_api_client.arvados_login_url(return_to: root_url) %>">Log in</a></li>
- <% end %>
- <% end %>
++ <li><a href="<%= arvados_api_client.arvados_login_url(return_to: root_url) %>">Log in</a></li>
+ <% end %>
+ <% if current_user.andand.is_active %>
<li class="dropdown selection-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<span class="fa fa-lg fa-paperclip"></span>
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list