From fffc9e0b2657e29eeb7ee73f5ff51dafa0b6acfb Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Thu, 22 Jul 2010 17:12:51 +0200 Subject: CONFIG reverted to @@config --- application.rb | 1 - 1 file changed, 1 deletion(-) (limited to 'application.rb') diff --git a/application.rb b/application.rb index b573314..1c94f24 100644 --- a/application.rb +++ b/application.rb @@ -1,7 +1,6 @@ require 'rubygems' gem "opentox-ruby-api-wrapper", "= 1.6.0" require 'opentox-ruby-api-wrapper' -LOGGER.progname = File.expand_path(__FILE__) class Model include DataMapper::Resource -- cgit v1.2.3 From 8e74fbbe98b4ef13c3d7a52352ab0e5ec99b7675 Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Fri, 6 Aug 2010 13:27:13 +0200 Subject: prediction caching --- application.rb | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'application.rb') diff --git a/application.rb b/application.rb index 1c94f24..4bf6e94 100644 --- a/application.rb +++ b/application.rb @@ -11,6 +11,15 @@ class Model property :created_at, DateTime end +class Prediction + # cache predictions + include DataMapper::Resource + property :id, Serial + property :compound_uri, String, :length => 255 + property :model_uri, String, :length => 255 + property :yaml, Text, :length => 2**32-1 +end + DataMapper.auto_upgrade! require 'lazar.rb' @@ -51,3 +60,9 @@ delete '/?' do response['Content-Type'] = 'text/plain' "All Models deleted." end + +delete '/prediction?' do + Prediction.auto_migrate! + response['Content-Type'] = 'text/plain' + "All datasets deleted." +end -- cgit v1.2.3 From 4e96a8c4f69e1dff298abfe245d9de2ec1daa3a4 Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Mon, 9 Aug 2010 10:03:11 +0200 Subject: opentox-api-wrapper bumped to 1.6.1 --- application.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'application.rb') diff --git a/application.rb b/application.rb index 4bf6e94..16f46b9 100644 --- a/application.rb +++ b/application.rb @@ -1,5 +1,5 @@ require 'rubygems' -gem "opentox-ruby-api-wrapper", "= 1.6.0" +gem "opentox-ruby-api-wrapper", "= 1.6.1" require 'opentox-ruby-api-wrapper' class Model -- cgit v1.2.3 From 6d3a6b65fc86a9ed9948cf572888920ee9db120d Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Mon, 9 Aug 2010 17:47:58 +0200 Subject: opentox-api-wrapper bumped to 1.6.2 --- application.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'application.rb') diff --git a/application.rb b/application.rb index 16f46b9..2b33b9f 100644 --- a/application.rb +++ b/application.rb @@ -1,5 +1,5 @@ require 'rubygems' -gem "opentox-ruby-api-wrapper", "= 1.6.1" +gem "opentox-ruby-api-wrapper", "= 1.6.2" require 'opentox-ruby-api-wrapper' class Model -- cgit v1.2.3 From ef47e85f08e0c0567b3f25a33cc0d929c1a3f0d6 Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Wed, 18 Aug 2010 19:52:09 +0200 Subject: opentox-api-wrapper bumped to 1.6.3 --- application.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'application.rb') diff --git a/application.rb b/application.rb index 2b33b9f..1efa581 100644 --- a/application.rb +++ b/application.rb @@ -1,5 +1,5 @@ require 'rubygems' -gem "opentox-ruby-api-wrapper", "= 1.6.2" +gem "opentox-ruby-api-wrapper", "= 1.6.3" require 'opentox-ruby-api-wrapper' class Model -- cgit v1.2.3 From 0f47a05adb11fbd9dfd0977780d2daa1e434c7c8 Mon Sep 17 00:00:00 2001 From: ch Date: Wed, 18 Aug 2010 20:40:34 +0200 Subject: cached predictions deleted --- application.rb | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'application.rb') diff --git a/application.rb b/application.rb index 1efa581..195dcaf 100644 --- a/application.rb +++ b/application.rb @@ -57,12 +57,7 @@ end delete '/?' do # TODO delete datasets Model.auto_migrate! - response['Content-Type'] = 'text/plain' - "All Models deleted." -end - -delete '/prediction?' do Prediction.auto_migrate! response['Content-Type'] = 'text/plain' - "All datasets deleted." + "All models and cached predictions deleted." end -- cgit v1.2.3