Description:
[web] updated grader monitoring
git-svn-id: http://theory.cpe.ku.ac.th/grader/web/trunk@222 6386c4cd-e34a-4fa8-8920-d93eb39b512e
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r105:0ea7f18fc18a - - 14 files changed: 149 inserted, 20 deleted
@@ -0,0 +1,22 | |||||
|
|
1 | + %h1= "Submission: #{@submission.id}" | ||
|
|
2 | + | ||
|
|
3 | + %p | ||
|
|
4 | + User: | ||
|
|
5 | + = "#{@submission.user.login}" | ||
|
|
6 | + %br/ | ||
|
|
7 | + Problem: | ||
|
|
8 | + - if @submission.problem!=nil | ||
|
|
9 | + = "#{@submission.problem.full_name}" | ||
|
|
10 | + - else | ||
|
|
11 | + = "(n/a)" | ||
|
|
12 | + %br/ | ||
|
|
13 | + = "Number: #{@submission.number}" | ||
|
|
14 | + %br/ | ||
|
|
15 | + = "Submitted at: #{format_short_time(@submission.submitted_at)}" | ||
|
|
16 | + | ||
|
|
17 | + %b Source code (first 10kb) | ||
|
|
18 | + %div{:style => "border: 1px solid black; background: lightgrey"} | ||
|
|
19 | + - if @submission.source | ||
|
|
20 | + %pre | ||
|
|
21 | + = truncate(@submission.source,10240) | ||
|
|
22 | + |
@@ -0,0 +1,15 | |||||
|
|
1 | + %h1= "Task: #{@task.id}" | ||
|
|
2 | + | ||
|
|
3 | + %p | ||
|
|
4 | + User: | ||
|
|
5 | + = "#{@task.submission.user.login}" | ||
|
|
6 | + %br/ | ||
|
|
7 | + Status: | ||
|
|
8 | + = "#{@task.status_str} (at #{format_short_time(@task.updated_at)})" | ||
|
|
9 | + %br/ | ||
|
|
10 | + = "Submission: #{@task.submission_id}" | ||
|
|
11 | + - if @task.submission !=nil | ||
|
|
12 | + = link_to '[view submission]', :action => 'submission', :id => @task.submission.id | ||
|
|
13 | + %br/ | ||
|
|
14 | + = "Submitted at: #{format_short_time(@task.created_at)}" | ||
|
|
15 | + %br/ |
@@ -0,0 +1,40 | |||||
|
|
1 | + %h1= "Test Request: #{@test_request.id}" | ||
|
|
2 | + | ||
|
|
3 | + %p | ||
|
|
4 | + User: | ||
|
|
5 | + = "#{@test_request.user.login}" | ||
|
|
6 | + %br/ | ||
|
|
7 | + Problem: | ||
|
|
8 | + - if @test_request.problem!=nil | ||
|
|
9 | + = "#{@test_request.problem.full_name}" | ||
|
|
10 | + - else | ||
|
|
11 | + = "(n/a)" | ||
|
|
12 | + %br/ | ||
|
|
13 | + = "Submission: #{@test_request.submission.number}" | ||
|
|
14 | + = link_to '[view submission]', :action => 'submission', :id => @test_request.submission.id | ||
|
|
15 | + %br/ | ||
|
|
16 | + = "Test submitted at: #{format_short_time(@test_request.submitted_at)}" | ||
|
|
17 | + %br/ | ||
|
|
18 | + = "Execution time: #{@test_request.running_time} s." | ||
|
|
19 | + %br/ | ||
|
|
20 | + = "Memory usage: #{@test_request.memory_usage}kb" | ||
|
|
21 | + %br/ | ||
|
|
22 | + %b= @test_request.exit_status | ||
|
|
23 | + %br/ | ||
|
|
24 | + | ||
|
|
25 | + - if @test_request.compiler_message!=nil and @test_request.compiler_message!='' | ||
|
|
26 | + %b Compiler Message | ||
|
|
27 | + %div{:style => "border: 1px solid black; background: lightgrey"} | ||
|
|
28 | + = simple_format(truncate((@test_request.compiler_message or ''),200)) | ||
|
|
29 | + | ||
|
|
30 | + %b Input (first 2kb) | ||
|
|
31 | + %div{:style => "border: 1px solid black; background: lightgrey"} | ||
|
|
32 | + - if @test_request.input_file_name!=nil | ||
|
|
33 | + = simple_format(read_textfile(@test_request.input_file_name,2048)) | ||
|
|
34 | + | ||
|
|
35 | + %b Output (first 2kb) | ||
|
|
36 | + %div{:style => "border: 1px solid black; background: lightgrey"} | ||
|
|
37 | + - if @test_request.output_file_name!=nil | ||
|
|
38 | + = simple_format(read_textfile(@test_request.output_file_name,2048)) | ||
|
|
39 | + - else | ||
|
|
40 | + (no output) |
@@ -0,0 +1,9 | |||||
|
|
1 | + class AddTaskTypeToGraderProcesses < ActiveRecord::Migration | ||
|
|
2 | + def self.up | ||
|
|
3 | + add_column 'grader_processes', 'task_type', :string | ||
|
|
4 | + end | ||
|
|
5 | + | ||
|
|
6 | + def self.down | ||
|
|
7 | + remove_column 'grader_processes', 'task_type' | ||
|
|
8 | + end | ||
|
|
9 | + end |
@@ -1,18 +1,51 | |||||
|
1 | class GradersController < ApplicationController |
|
1 | class GradersController < ApplicationController |
|
2 |
|
2 | ||
|
3 | - |
|
3 | + before_filter :admin_authorization |
|
4 | - before_filter :authorization |
|
4 | + |
|
|
5 | + verify :method => :post, :only => ['clear_all'], | ||
|
|
6 | + :redirect_to => {:action => 'index'} | ||
|
|
7 | + | ||
|
|
8 | + def index | ||
|
|
9 | + redirect_to :action => 'list' | ||
|
|
10 | + end | ||
|
5 |
|
11 | ||
|
6 | def list |
|
12 | def list |
|
7 | @grader_processes = GraderProcess.find(:all, |
|
13 | @grader_processes = GraderProcess.find(:all, |
|
8 | :order => 'updated_at desc') |
|
14 | :order => 'updated_at desc') |
|
9 | @stalled_processes = GraderProcess.find_stalled_process |
|
15 | @stalled_processes = GraderProcess.find_stalled_process |
|
10 | end |
|
16 | end |
|
11 |
|
17 | ||
|
12 | def clear |
|
18 | def clear |
|
13 | grader_proc = GraderProcess.find(params[:id]) |
|
19 | grader_proc = GraderProcess.find(params[:id]) |
|
14 | grader_proc.destroy if grader_proc!=nil |
|
20 | grader_proc.destroy if grader_proc!=nil |
|
15 | redirect_to :action => 'list' |
|
21 | redirect_to :action => 'list' |
|
16 | end |
|
22 | end |
|
17 |
|
23 | ||
|
|
24 | + def clear_all | ||
|
|
25 | + GraderProcess.find(:all).each do |p| | ||
|
|
26 | + p.destroy | ||
|
|
27 | + end | ||
|
|
28 | + redirect_to :action => 'list' | ||
|
|
29 | + end | ||
|
|
30 | + | ||
|
|
31 | + def view | ||
|
|
32 | + if params[:type]=='Task' | ||
|
|
33 | + redirect_to :action => 'task', :id => params[:id] | ||
|
|
34 | + else | ||
|
|
35 | + redirect_to :action => 'test_request', :id => params[:id] | ||
|
|
36 | + end | ||
|
|
37 | + end | ||
|
|
38 | + | ||
|
|
39 | + def test_request | ||
|
|
40 | + @test_request = TestRequest.find(params[:id]) | ||
|
|
41 | + end | ||
|
|
42 | + | ||
|
|
43 | + def task | ||
|
|
44 | + @task = Task.find(params[:id]) | ||
|
|
45 | + end | ||
|
|
46 | + | ||
|
|
47 | + def submission | ||
|
|
48 | + @submission = Submission.find(params[:id]) | ||
|
|
49 | + end | ||
|
|
50 | + | ||
|
18 | end |
|
51 | end |
@@ -1,15 +1,15 | |||||
|
1 | class UserAdminController < ApplicationController |
|
1 | class UserAdminController < ApplicationController |
|
2 |
|
2 | ||
|
3 |
- before_filter :a |
|
3 | + before_filter :admin_authorization |
|
4 |
|
4 | ||
|
5 | def index |
|
5 | def index |
|
6 | list |
|
6 | list |
|
7 | render :action => 'list' |
|
7 | render :action => 'list' |
|
8 | end |
|
8 | end |
|
9 |
|
9 | ||
|
10 | # GETs should be safe (see http://www.w3.org/2001/tag/doc/whenToUseGet.html) |
|
10 | # GETs should be safe (see http://www.w3.org/2001/tag/doc/whenToUseGet.html) |
|
11 | verify :method => :post, :only => [ :destroy, :create, :update ], |
|
11 | verify :method => :post, :only => [ :destroy, :create, :update ], |
|
12 | :redirect_to => { :action => :list } |
|
12 | :redirect_to => { :action => :list } |
|
13 |
|
13 | ||
|
14 | def list |
|
14 | def list |
|
15 | @users = User.find(:all) |
|
15 | @users = User.find(:all) |
@@ -4,25 +4,25 | |||||
|
4 | def user_header |
|
4 | def user_header |
|
5 | menu_items = '' |
|
5 | menu_items = '' |
|
6 | user = User.find(session[:user_id]) |
|
6 | user = User.find(session[:user_id]) |
|
7 |
|
7 | ||
|
8 | if (user!=nil) and (session[:admin]) |
|
8 | if (user!=nil) and (session[:admin]) |
|
9 | # admin menu |
|
9 | # admin menu |
|
10 | menu_items << "<b>Administrative task:</b> " |
|
10 | menu_items << "<b>Administrative task:</b> " |
|
11 | append_to menu_items, '[Announcements]', 'announcements', 'index' |
|
11 | append_to menu_items, '[Announcements]', 'announcements', 'index' |
|
12 | append_to menu_items, '[Msg console]', 'messages', 'console' |
|
12 | append_to menu_items, '[Msg console]', 'messages', 'console' |
|
13 | append_to menu_items, '[Problem admin]', 'problems', 'index' |
|
13 | append_to menu_items, '[Problem admin]', 'problems', 'index' |
|
14 | append_to menu_items, '[User admin]', 'user_admin', 'index' |
|
14 | append_to menu_items, '[User admin]', 'user_admin', 'index' |
|
15 | append_to menu_items, '[User stat]', 'user_admin', 'user_stat' |
|
15 | append_to menu_items, '[User stat]', 'user_admin', 'user_stat' |
|
16 |
- |
|
16 | + append_to menu_items, '[Graders]', 'graders', 'list' |
|
17 | append_to menu_items, '[Site config]', 'configurations', 'index' |
|
17 | append_to menu_items, '[Site config]', 'configurations', 'index' |
|
18 | menu_items << "<br/>" |
|
18 | menu_items << "<br/>" |
|
19 | end |
|
19 | end |
|
20 |
|
20 | ||
|
21 | # main page |
|
21 | # main page |
|
22 | append_to menu_items, '[Main]', 'main', 'list' |
|
22 | append_to menu_items, '[Main]', 'main', 'list' |
|
23 | append_to menu_items, '[Messages]', 'messages', 'list' |
|
23 | append_to menu_items, '[Messages]', 'messages', 'list' |
|
24 | append_to menu_items, '[Tasks]', 'tasks', 'list' |
|
24 | append_to menu_items, '[Tasks]', 'tasks', 'list' |
|
25 | append_to menu_items, '[Submissions]', 'main', 'submission' |
|
25 | append_to menu_items, '[Submissions]', 'main', 'submission' |
|
26 | append_to menu_items, '[Test]', 'test', 'index' |
|
26 | append_to menu_items, '[Test]', 'test', 'index' |
|
27 | append_to menu_items, '[Settings]', 'users', 'index' |
|
27 | append_to menu_items, '[Settings]', 'users', 'index' |
|
28 | append_to menu_items, '[Log out]', 'main', 'login' |
|
28 | append_to menu_items, '[Log out]', 'main', 'login' |
@@ -63,13 +63,21 | |||||
|
63 | <tr> |
|
63 | <tr> |
|
64 | <td class="left-col"> |
|
64 | <td class="left-col"> |
|
65 | #{user.full_name}<br/> |
|
65 | #{user.full_name}<br/> |
|
66 | Current time is #{format_short_time(Time.new)}<br/> |
|
66 | Current time is #{format_short_time(Time.new)}<br/> |
|
67 | </td> |
|
67 | </td> |
|
68 | <td class="right-col">APIO'08</td> |
|
68 | <td class="right-col">APIO'08</td> |
|
69 | </tr> |
|
69 | </tr> |
|
70 | </table> |
|
70 | </table> |
|
71 | </div> |
|
71 | </div> |
|
72 | TITLEBAR |
|
72 | TITLEBAR |
|
73 | end |
|
73 | end |
|
74 |
|
74 | ||
|
|
75 | + def read_textfile(fname,max_size=2048) | ||
|
|
76 | + begin | ||
|
|
77 | + File.open(fname).read(max_size) | ||
|
|
78 | + rescue | ||
|
|
79 | + nil | ||
|
|
80 | + end | ||
|
|
81 | + end | ||
|
|
82 | + | ||
|
75 | end |
|
83 | end |
@@ -1,11 +1,2 | |||||
|
1 | module TestHelper |
|
1 | module TestHelper |
|
2 | - |
|
||
|
3 | - def read_textfile(fname,max_size=2048) |
|
||
|
4 | - begin |
|
||
|
5 | - File.open(fname).read(max_size) |
|
||
|
6 | - rescue |
|
||
|
7 | - nil |
|
||
|
8 | - end |
|
||
|
9 | - end |
|
||
|
10 | - |
|
||
|
11 | end |
|
2 | end |
@@ -1,52 +1,53 | |||||
|
1 | class GraderProcess < ActiveRecord::Base |
|
1 | class GraderProcess < ActiveRecord::Base |
|
2 |
|
2 | ||
|
3 | - belongs_to :task |
|
||
|
4 | - |
|
||
|
5 | def self.find_by_host_and_pid(host,pid) |
|
3 | def self.find_by_host_and_pid(host,pid) |
|
6 | return GraderProcess.find(:first, |
|
4 | return GraderProcess.find(:first, |
|
7 | :conditions => { |
|
5 | :conditions => { |
|
8 | :host => host, |
|
6 | :host => host, |
|
9 | :pid => pid |
|
7 | :pid => pid |
|
10 | }) |
|
8 | }) |
|
11 | end |
|
9 | end |
|
12 |
|
10 | ||
|
13 | def self.register(host,pid,mode) |
|
11 | def self.register(host,pid,mode) |
|
14 | grader = GraderProcess.find_by_host_and_pid(host,pid) |
|
12 | grader = GraderProcess.find_by_host_and_pid(host,pid) |
|
15 | if grader |
|
13 | if grader |
|
16 | grader.mode = mode |
|
14 | grader.mode = mode |
|
17 | grader.active = nil |
|
15 | grader.active = nil |
|
18 | grader.task_id = nil |
|
16 | grader.task_id = nil |
|
|
17 | + grader.task_type = nil | ||
|
19 | grader.save |
|
18 | grader.save |
|
20 | else |
|
19 | else |
|
21 | grader = GraderProcess.create(:host => host, |
|
20 | grader = GraderProcess.create(:host => host, |
|
22 | :pid => pid, |
|
21 | :pid => pid, |
|
23 | :mode => mode) |
|
22 | :mode => mode) |
|
24 | end |
|
23 | end |
|
25 | grader |
|
24 | grader |
|
26 | end |
|
25 | end |
|
27 |
|
26 | ||
|
28 | def self.find_stalled_process() |
|
27 | def self.find_stalled_process() |
|
29 | GraderProcess.find(:all, |
|
28 | GraderProcess.find(:all, |
|
30 | :conditions => ["active AND updated_at < ?", |
|
29 | :conditions => ["active AND updated_at < ?", |
|
31 | Time.now.gmtime - GraderProcess.stalled_time]) |
|
30 | Time.now.gmtime - GraderProcess.stalled_time]) |
|
32 | end |
|
31 | end |
|
33 |
|
32 | ||
|
34 | def report_active(task=nil) |
|
33 | def report_active(task=nil) |
|
35 | self.active = true |
|
34 | self.active = true |
|
36 | - self.task = task |
|
35 | + self.task_id = task.id |
|
|
36 | + self.task_type = task.class.to_s | ||
|
37 | self.save |
|
37 | self.save |
|
38 | end |
|
38 | end |
|
39 |
|
39 | ||
|
40 | def report_inactive() |
|
40 | def report_inactive() |
|
41 | self.active = false |
|
41 | self.active = false |
|
42 | - self.task = nil |
|
42 | + self.task_id = nil |
|
|
43 | + self.task_type = nil | ||
|
43 | self.save |
|
44 | self.save |
|
44 | end |
|
45 | end |
|
45 |
|
46 | ||
|
46 | protected |
|
47 | protected |
|
47 |
|
48 | ||
|
48 | def self.stalled_time() |
|
49 | def self.stalled_time() |
|
49 | return 1.minute |
|
50 | return 1.minute |
|
50 | end |
|
51 | end |
|
51 |
|
52 | ||
|
52 | end |
|
53 | end |
@@ -1,14 +1,16 | |||||
|
1 | class Task < ActiveRecord::Base |
|
1 | class Task < ActiveRecord::Base |
|
2 |
|
2 | ||
|
|
3 | + belongs_to :submission | ||
|
|
4 | + | ||
|
3 | STATUS_GRADING = 0 |
|
5 | STATUS_GRADING = 0 |
|
4 | STATUS_INQUEUE = 1 |
|
6 | STATUS_INQUEUE = 1 |
|
5 | STATUS_COMPLETE = 2 |
|
7 | STATUS_COMPLETE = 2 |
|
6 |
|
8 | ||
|
7 | def status_inqueue |
|
9 | def status_inqueue |
|
8 | self.status = Task::STATUS_INQUEUE |
|
10 | self.status = Task::STATUS_INQUEUE |
|
9 | end |
|
11 | end |
|
10 |
|
12 | ||
|
11 | def status_inqueue! |
|
13 | def status_inqueue! |
|
12 | status_inqueue |
|
14 | status_inqueue |
|
13 | self.save |
|
15 | self.save |
|
14 | end |
|
16 | end |
@@ -1,9 +1,11 | |||||
|
1 |
|
1 | ||
|
2 | %td= grader.host |
|
2 | %td= grader.host |
|
3 | %td= grader.pid |
|
3 | %td= grader.pid |
|
|
4 | + %td= grader.mode | ||
|
4 | %td= grader.updated_at.strftime("%H:%M:%S") if grader.updated_at!=nil |
|
5 | %td= grader.updated_at.strftime("%H:%M:%S") if grader.updated_at!=nil |
|
|
6 | + %td= grader.task_type | ||
|
5 | %td |
|
7 | %td |
|
6 | - if grader.task_id==nil |
|
8 | - if grader.task_id==nil |
|
7 | - \- |
|
9 | + idle |
|
8 | - else |
|
10 | - else |
|
9 | - = grader.task_id |
|
11 | + = link_to "#{grader.task_id}", :action => 'view', :id => grader.task_id, :type => grader.task_type |
@@ -1,16 +1,18 | |||||
|
1 |
|
1 | ||
|
2 | %table.graders |
|
2 | %table.graders |
|
3 | %tr |
|
3 | %tr |
|
4 | %th host |
|
4 | %th host |
|
5 | %th pid |
|
5 | %th pid |
|
|
6 | + %th mode | ||
|
6 | %th last updated |
|
7 | %th last updated |
|
|
8 | + %th type | ||
|
7 | %th task |
|
9 | %th task |
|
8 | - grader_list.each do |grader| |
|
10 | - grader_list.each do |grader| |
|
9 | - if grader.active |
|
11 | - if grader.active |
|
10 | - c = 'active' |
|
12 | - c = 'active' |
|
11 | - else |
|
13 | - else |
|
12 | - c = 'inactive' |
|
14 | - c = 'inactive' |
|
13 | %tr{:class => c} |
|
15 | %tr{:class => c} |
|
14 | = render :partial => 'grader', :locals => {:grader => grader} |
|
16 | = render :partial => 'grader', :locals => {:grader => grader} |
|
15 | %td= link_to 'clear', {:action => 'clear', :id => grader} |
|
17 | %td= link_to 'clear', {:action => 'clear', :id => grader} |
|
16 |
|
18 |
@@ -1,12 +1,15 | |||||
|
1 | - content_for :head do |
|
1 | - content_for :head do |
|
2 | = stylesheet_link_tag 'graders' |
|
2 | = stylesheet_link_tag 'graders' |
|
3 |
|
3 | ||
|
4 | %h2 (Under Experiments) |
|
4 | %h2 (Under Experiments) |
|
5 |
|
5 | ||
|
|
6 | + - form_for :clear, nil, :url => {:action => 'clear_all'} do |f| | ||
|
|
7 | + = submit_tag 'Clear all data' | ||
|
|
8 | + | ||
|
6 | %h3 Current graders |
|
9 | %h3 Current graders |
|
7 |
|
10 | ||
|
8 | = render :partial => 'grader_list', :locals => {:grader_list => @grader_processes} |
|
11 | = render :partial => 'grader_list', :locals => {:grader_list => @grader_processes} |
|
9 |
|
12 | ||
|
10 | %h3 Stalled graders |
|
13 | %h3 Stalled graders |
|
11 |
|
14 | ||
|
12 | = render :partial => 'grader_list', :locals => {:grader_list => @stalled_processes} |
|
15 | = render :partial => 'grader_list', :locals => {:grader_list => @stalled_processes} |
@@ -1,24 +1,24 | |||||
|
1 | # This file is auto-generated from the current state of the database. Instead of editing this file, |
|
1 | # This file is auto-generated from the current state of the database. Instead of editing this file, |
|
2 | # please use the migrations feature of ActiveRecord to incrementally modify your database, and |
|
2 | # please use the migrations feature of ActiveRecord to incrementally modify your database, and |
|
3 | # then regenerate this schema definition. |
|
3 | # then regenerate this schema definition. |
|
4 | # |
|
4 | # |
|
5 | # Note that this schema.rb definition is the authoritative source for your database schema. If you need |
|
5 | # Note that this schema.rb definition is the authoritative source for your database schema. If you need |
|
6 | # to create the application database on another system, you should be using db:schema:load, not running |
|
6 | # to create the application database on another system, you should be using db:schema:load, not running |
|
7 | # all the migrations from scratch. The latter is a flawed and unsustainable approach (the more migrations |
|
7 | # all the migrations from scratch. The latter is a flawed and unsustainable approach (the more migrations |
|
8 | # you'll amass, the slower it'll run and the greater likelihood for issues). |
|
8 | # you'll amass, the slower it'll run and the greater likelihood for issues). |
|
9 | # |
|
9 | # |
|
10 | # It's strongly recommended to check this file into your version control system. |
|
10 | # It's strongly recommended to check this file into your version control system. |
|
11 |
|
11 | ||
|
12 |
- ActiveRecord::Schema.define(:version => 3 |
|
12 | + ActiveRecord::Schema.define(:version => 33) do |
|
13 |
|
13 | ||
|
14 | create_table "announcements", :force => true do |t| |
|
14 | create_table "announcements", :force => true do |t| |
|
15 | t.string "author" |
|
15 | t.string "author" |
|
16 | t.text "body" |
|
16 | t.text "body" |
|
17 | t.boolean "published" |
|
17 | t.boolean "published" |
|
18 | t.datetime "created_at" |
|
18 | t.datetime "created_at" |
|
19 | t.datetime "updated_at" |
|
19 | t.datetime "updated_at" |
|
20 | end |
|
20 | end |
|
21 |
|
21 | ||
|
22 | create_table "configurations", :force => true do |t| |
|
22 | create_table "configurations", :force => true do |t| |
|
23 | t.string "key" |
|
23 | t.string "key" |
|
24 | t.string "value_type" |
|
24 | t.string "value_type" |
@@ -33,24 +33,25 | |||||
|
33 | t.datetime "created_at" |
|
33 | t.datetime "created_at" |
|
34 | t.datetime "updated_at" |
|
34 | t.datetime "updated_at" |
|
35 | end |
|
35 | end |
|
36 |
|
36 | ||
|
37 | create_table "grader_processes", :force => true do |t| |
|
37 | create_table "grader_processes", :force => true do |t| |
|
38 | t.string "host", :limit => 20 |
|
38 | t.string "host", :limit => 20 |
|
39 | t.integer "pid" |
|
39 | t.integer "pid" |
|
40 | t.string "mode" |
|
40 | t.string "mode" |
|
41 | t.boolean "active" |
|
41 | t.boolean "active" |
|
42 | t.datetime "created_at" |
|
42 | t.datetime "created_at" |
|
43 | t.datetime "updated_at" |
|
43 | t.datetime "updated_at" |
|
44 | t.integer "task_id" |
|
44 | t.integer "task_id" |
|
|
45 | + t.string "task_type" | ||
|
45 | end |
|
46 | end |
|
46 |
|
47 | ||
|
47 | add_index "grader_processes", ["host", "pid"], :name => "index_grader_processes_on_ip_and_pid" |
|
48 | add_index "grader_processes", ["host", "pid"], :name => "index_grader_processes_on_ip_and_pid" |
|
48 |
|
49 | ||
|
49 | create_table "languages", :force => true do |t| |
|
50 | create_table "languages", :force => true do |t| |
|
50 | t.string "name", :limit => 10 |
|
51 | t.string "name", :limit => 10 |
|
51 | t.string "pretty_name" |
|
52 | t.string "pretty_name" |
|
52 | t.string "ext", :limit => 10 |
|
53 | t.string "ext", :limit => 10 |
|
53 | end |
|
54 | end |
|
54 |
|
55 | ||
|
55 | create_table "messages", :force => true do |t| |
|
56 | create_table "messages", :force => true do |t| |
|
56 | t.integer "sender_id" |
|
57 | t.integer "sender_id" |
You need to be logged in to leave comments.
Login now