Merge lp:~cjohnston/qa-dashboard/hide-memory-test-framework-data into lp:qa-dashboard

Proposed by Chris Johnston
Status: Work in progress
Proposed branch: lp:~cjohnston/qa-dashboard/hide-memory-test-framework-data
Merge into: lp:qa-dashboard
Prerequisite: lp:~cjohnston/qa-dashboard/add-admin-link
Diff against target: 439 lines (+281/-8)
9 files modified
common/templates/layout.html (+2/-1)
memory/admin.py (+11/-0)
memory/api.py (+9/-1)
memory/management/commands/agg_results.py (+10/-3)
memory/migrations/0002_add_memory_config.py (+213/-0)
memory/models.py (+4/-0)
memory/templates/memory/machine_details.html (+14/-1)
memory/tests.py (+1/-1)
memory/views.py (+17/-1)
To merge this branch: bzr merge lp:~cjohnston/qa-dashboard/hide-memory-test-framework-data
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve
Chris Johnston Needs Resubmitting
Joe Talbott Approve
Review via email: mp+174325@code.launchpad.net

Commit message

Hides test framework results by default from memory graphs and tables, adding the ability to see the test framework results

Description of the change

In order to display proper results for memory testing, we should not be displaying the memory usage caused by the testing frame work. To fix this, we will add a set of blacklist processes, and exclude those from the results. Just for the ability to follow the usage by the testing framework, we added an option to display the data including the testing framework data.

The aggregated data will need to be reformulated after this branch lands in order to provide consistency.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:496
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https://code.launchpad.net/~cjohnston/qa-dashboard/hide-memory-test-framework-data/+merge/174325/+edit-commit-message

http://s-jenkins:8080/job/dashboard-ci/78/
Executed test runs:

Click here to trigger a rebuild:
http://s-jenkins:8080/job/dashboard-ci/78/rebuild

review: Needs Fixing (continuous-integration)
497. By Chris Johnston

Fix tests

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

PASSED: Continuous integration, rev:497
http://s-jenkins:8080/job/dashboard-ci/79/
Executed test runs:

Click here to trigger a rebuild:
http://s-jenkins:8080/job/dashboard-ci/79/rebuild

review: Approve (continuous-integration)
Revision history for this message
Joe Talbott (joetalbott) wrote :

LGTM.

review: Approve
498. By Chris Johnston

Change exclude to be in agg script

Revision history for this message
Chris Johnston (cjohnston) :
review: Needs Resubmitting
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

PASSED: Continuous integration, rev:498
http://s-jenkins:8080/job/dashboard-ci/80/
Executed test runs:

Click here to trigger a rebuild:
http://s-jenkins:8080/job/dashboard-ci/80/rebuild

review: Approve (continuous-integration)

Unmerged revisions

498. By Chris Johnston

Change exclude to be in agg script

497. By Chris Johnston

Fix tests

496. By Chris Johnston

Add the ability to exclude test framework data

495. By Chris Johnston

commit

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'common/templates/layout.html'
--- common/templates/layout.html 2013-07-11 15:30:27 +0000
+++ common/templates/layout.html 2013-07-12 13:44:34 +0000
@@ -28,7 +28,8 @@
28 <li {% ifequal url.0 'bootspeed' %}class="active" {% endifequal %}id="main-nav"><a class="main-nav-item" href="{% url bootspeed_arch_overview %}">Bootspeed</a></li>28 <li {% ifequal url.0 'bootspeed' %}class="active" {% endifequal %}id="main-nav"><a class="main-nav-item" href="{% url bootspeed_arch_overview %}">Bootspeed</a></li>
29 <li {% ifequal url.0 'power' %}class="active" {% endifequal %}id="main-nav"><a class="main-nav-item" href="{% url power_overview %}">Power</a></li>29 <li {% ifequal url.0 'power' %}class="active" {% endifequal %}id="main-nav"><a class="main-nav-item" href="{% url power_overview %}">Power</a></li>
30 <li {% ifequal url.0 'memory' %}class="active" {% endifequal %}id="main-nav"><a class="main-nav-item" href="{% url memory_arch_overview %}">Memory</a></li>30 <li {% ifequal url.0 'memory' %}class="active" {% endifequal %}id="main-nav"><a class="main-nav-item" href="{% url memory_arch_overview %}">Memory</a></li>
31 <li id="main-nav"><a class="main-nav-item" href="https://jenkins.qa.ubuntu.com/view/Saucy/view/AutoPkgTest/">Autopackage</a></li> 31 <li id="main-nav"><a class="main-nav-item" href="https://jenkins.qa.ubuntu.com/view/Saucy/view/AutoPkgTest/">Autopackage</a></li>
32 {% if user.is_staff %}<li id="main-nav"><a class="main-nav-item" href="/admin">Admin</a></li>{% endif %}
32 </ul>33 </ul>
33 </nav>34 </nav>
34 <a href='{% url index %}' class="logo-ubuntu">35 <a href='{% url index %}' class="logo-ubuntu">
3536
=== modified file 'memory/admin.py'
--- memory/admin.py 2013-03-21 18:59:36 +0000
+++ memory/admin.py 2013-07-12 13:44:34 +0000
@@ -22,6 +22,8 @@
22 MemoryResult,22 MemoryResult,
23 MemoryMetric,23 MemoryMetric,
24 MemoryBuild,24 MemoryBuild,
25 MemoryConfig,
26 MemoryProcess,
25)27)
2628
27from django.contrib import admin29from django.contrib import admin
@@ -131,6 +133,14 @@
131 )133 )
132134
133135
136class MemoryConfigAdmin(admin.ModelAdmin):
137 list_display = ('blacklist_process', )
138
139
140class MemoryProcessAdmin(admin.ModelAdmin):
141 list_display = ('image', 'upgrade', 'machine', 'process',)
142
143admin.site.register(MemoryConfig, MemoryConfigAdmin)
134admin.site.register(MemoryUpgrade, MemoryUpgradeAdmin)144admin.site.register(MemoryUpgrade, MemoryUpgradeAdmin)
135admin.site.register(MemoryMachine, MemoryMachineAdmin)145admin.site.register(MemoryMachine, MemoryMachineAdmin)
136admin.site.register(MemoryLog, MemoryLogAdmin)146admin.site.register(MemoryLog, MemoryLogAdmin)
@@ -139,3 +149,4 @@
139admin.site.register(MemoryDetail, MemoryDetailAdmin)149admin.site.register(MemoryDetail, MemoryDetailAdmin)
140admin.site.register(MemoryResult, MemoryResultAdmin)150admin.site.register(MemoryResult, MemoryResultAdmin)
141admin.site.register(MemoryBuild, MemoryBuildAdmin)151admin.site.register(MemoryBuild, MemoryBuildAdmin)
152admin.site.register(MemoryProcess, MemoryProcessAdmin)
142153
=== modified file 'memory/api.py'
--- memory/api.py 2013-06-09 23:59:45 +0000
+++ memory/api.py 2013-07-12 13:44:34 +0000
@@ -32,6 +32,7 @@
32 MemoryProcess,32 MemoryProcess,
33 MemoryResult,33 MemoryResult,
34 MemoryUpgrade,34 MemoryUpgrade,
35 MemoryConfig,
35)36)
3637
37MAX_RESULTS = 18038MAX_RESULTS = 180
@@ -353,7 +354,14 @@
353def result_processes(request, result_id):354def result_processes(request, result_id):
354 result = get_object_or_404(MemoryResult, id=result_id)355 result = get_object_or_404(MemoryResult, id=result_id)
355356
356 procs = result.memorydetail_set.filter(publish=True).order_by('-pss')357 exclude = MemoryConfig.objects.all().values_list(
358 'blacklist_process',
359 flat=True,
360 )
361
362 procs = result.memorydetail_set.exclude(
363 command__in=exclude,
364 ).filter(publish=True).order_by('-pss')
357365
358 data = []366 data = []
359 for p in procs:367 for p in procs:
360368
=== modified file 'memory/management/commands/agg_results.py'
--- memory/management/commands/agg_results.py 2013-03-22 21:10:26 +0000
+++ memory/management/commands/agg_results.py 2013-07-12 13:44:34 +0000
@@ -22,17 +22,20 @@
22from memory.models import (22from memory.models import (
23 MemoryDetail,23 MemoryDetail,
24 MemoryResult,24 MemoryResult,
25 MemoryConfig,
25)26)
2627
2728
28class Command(BaseCommand):29class Command(BaseCommand):
29 help = "Do result calculations."30 help = "Do result calculations."
3031
31 def _aggregate(self, result):32 def _aggregate(self, result, exclude):
32 """ Aggregate values by name. """33 """ Aggregate values by name. """
3334
34 details = MemoryDetail.objects.filter(35 details = MemoryDetail.objects.filter(
35 result=result,36 result=result,
37 ).exclude(
38 command__in=exclude,
36 )39 )
3740
38 if details.count() == 0:41 if details.count() == 0:
@@ -49,7 +52,6 @@
49 return result52 return result
5053
51 def handle(self, *args, **options):54 def handle(self, *args, **options):
52
53 verbosity = int(options.get('verbosity'))55 verbosity = int(options.get('verbosity'))
5456
55 log_level = logging.WARN57 log_level = logging.WARN
@@ -64,9 +66,14 @@
64 name='pss',66 name='pss',
65 )67 )
6668
69 exclude = MemoryConfig.objects.all().values_list(
70 'blacklist_process',
71 flat=True,
72 )
73
67 logging.info("results: {}".format(results))74 logging.info("results: {}".format(results))
68 for result in results.iterator():75 for result in results.iterator():
69 logging.info("name: {}".format(result.name))76 logging.info("name: {}".format(result.name))
70 res = self._aggregate(result)77 res = self._aggregate(result, exclude)
7178
72 logging.info("result: {}".format(res))79 logging.info("result: {}".format(res))
7380
=== added file 'memory/migrations/0002_add_memory_config.py'
--- memory/migrations/0002_add_memory_config.py 1970-01-01 00:00:00 +0000
+++ memory/migrations/0002_add_memory_config.py 2013-07-12 13:44:34 +0000
@@ -0,0 +1,213 @@
1# -*- coding: utf-8 -*-
2import datetime
3from south.db import db
4from south.v2 import SchemaMigration
5from django.db import models
6
7
8class Migration(SchemaMigration):
9
10 def forwards(self, orm):
11 # Adding model 'MemoryConfig'
12 db.create_table('memory_memoryconfig', (
13 ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
14 ('created_at', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True, blank=True)),
15 ('updated_at', self.gf('django.db.models.fields.DateTimeField')(auto_now=True, blank=True)),
16 ('internal', self.gf('django.db.models.fields.BooleanField')(default=True)),
17 ('publish', self.gf('django.db.models.fields.BooleanField')(default=True)),
18 ('blacklist_process', self.gf('django.db.models.fields.CharField')(max_length=4096)),
19 ))
20 db.send_create_signal('memory', ['MemoryConfig'])
21
22
23 def backwards(self, orm):
24 # Deleting model 'MemoryConfig'
25 db.delete_table('memory_memoryconfig')
26
27
28 models = {
29 'common.bug': {
30 'Meta': {'object_name': 'Bug', 'db_table': "'bugs'"},
31 'assignee': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
32 'bug_no': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
33 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
34 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
35 'importance': ('django.db.models.fields.CharField', [], {'default': "u'unknown'", 'max_length': '4096'}),
36 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
37 'project': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
38 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
39 'status': ('django.db.models.fields.CharField', [], {'default': "u'unknown'", 'max_length': '4096'}),
40 'title': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
41 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
42 },
43 'common.jenkinsbuild': {
44 'Meta': {'unique_together': "(('job', 'build_number'),)", 'object_name': 'JenkinsBuild', 'db_table': "'jenkins_builds'"},
45 'bugs': ('django.db.models.fields.related.ManyToManyField', [], {'related_name': "'build_bugs'", 'symmetrical': 'False', 'to': "orm['common.Bug']"}),
46 'build_description': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '1024'}),
47 'build_number': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
48 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
49 'failed': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
50 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
51 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
52 'job': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.JenkinsJob']"}),
53 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
54 'ran_at': ('django.db.models.fields.DateTimeField', [], {}),
55 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
56 },
57 'common.jenkinsjob': {
58 'Meta': {'object_name': 'JenkinsJob', 'db_table': "'jenkins_jobs'"},
59 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
60 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
61 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
62 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '200'}),
63 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
64 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
65 'url': ('django.db.models.fields.URLField', [], {'max_length': '200'})
66 },
67 'memory.memorybuild': {
68 'Meta': {'object_name': 'MemoryBuild', 'db_table': "'memory_builds'"},
69 'build': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['common.JenkinsBuild']"}),
70 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
71 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
72 'image': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryImage']", 'null': 'True'}),
73 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
74 'machine': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryMachine']"}),
75 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
76 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
77 'upgrade': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryUpgrade']", 'null': 'True'})
78 },
79 'memory.memoryconfig': {
80 'Meta': {'object_name': 'MemoryConfig'},
81 'blacklist_process': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
82 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
83 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
84 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
85 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
86 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
87 },
88 'memory.memorydetail': {
89 'Meta': {'object_name': 'MemoryDetail', 'db_table': "'memory_details'"},
90 'command': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
91 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
92 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
93 'image': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryImage']", 'null': 'True'}),
94 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
95 'machine': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryMachine']"}),
96 'name': ('django.db.models.fields.CharField', [], {'max_length': '1024'}),
97 'pss': ('django.db.models.fields.PositiveIntegerField', [], {}),
98 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
99 'ran_at': ('django.db.models.fields.DateTimeField', [], {}),
100 'result': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryResult']"}),
101 'rss': ('django.db.models.fields.PositiveIntegerField', [], {}),
102 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
103 'upgrade': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryUpgrade']", 'null': 'True'}),
104 'uss': ('django.db.models.fields.PositiveIntegerField', [], {}),
105 'vss': ('django.db.models.fields.PositiveIntegerField', [], {})
106 },
107 'memory.memoryimage': {
108 'Meta': {'object_name': 'MemoryImage', 'db_table': "'memory_images'"},
109 'arch': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
110 'build_number': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
111 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
112 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
113 'image_type': ('django.db.models.fields.CharField', [], {'default': "u'daily'", 'max_length': '10'}),
114 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
115 'md5': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '200'}),
116 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
117 'release': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
118 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
119 'variant': ('django.db.models.fields.CharField', [], {'max_length': '200'})
120 },
121 'memory.memorylog': {
122 'Meta': {'object_name': 'MemoryLog', 'db_table': "'memory_logs'"},
123 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
124 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
125 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
126 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
127 'path': ('django.db.models.fields.CharField', [], {'max_length': '512'}),
128 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
129 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
130 },
131 'memory.memorymachine': {
132 'Meta': {'object_name': 'MemoryMachine', 'db_table': "'memory_machines'"},
133 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
134 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
135 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
136 'mac_address': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
137 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '200'}),
138 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
139 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
140 },
141 'memory.memorymetric': {
142 'Meta': {'object_name': 'MemoryMetric', 'db_table': "'memory_metrics'"},
143 'average': ('django.db.models.fields.FloatField', [], {'default': '0'}),
144 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
145 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
146 'image': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryImage']", 'null': 'True'}),
147 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
148 'jenkins_url': ('django.db.models.fields.URLField', [], {'max_length': '200', 'null': 'True'}),
149 'kernel': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'}),
150 'machine': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryMachine']"}),
151 'maximum': ('django.db.models.fields.FloatField', [], {'default': '0'}),
152 'minimum': ('django.db.models.fields.FloatField', [], {'default': '0'}),
153 'name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
154 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
155 'ran_at': ('django.db.models.fields.DateTimeField', [], {}),
156 'stddev': ('django.db.models.fields.FloatField', [], {'default': '0'}),
157 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
158 'upgrade': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryUpgrade']", 'null': 'True'})
159 },
160 'memory.memoryprocess': {
161 'Meta': {'object_name': 'MemoryProcess', 'db_table': "'memory_processes'"},
162 'average': ('django.db.models.fields.FloatField', [], {'default': '0'}),
163 'command': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
164 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
165 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
166 'image': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryImage']", 'null': 'True'}),
167 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
168 'jenkins_url': ('django.db.models.fields.URLField', [], {'max_length': '200', 'null': 'True'}),
169 'machine': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryMachine']"}),
170 'maximum': ('django.db.models.fields.FloatField', [], {'default': '0'}),
171 'minimum': ('django.db.models.fields.FloatField', [], {'default': '0'}),
172 'name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
173 'process': ('django.db.models.fields.CharField', [], {'max_length': '1024'}),
174 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
175 'ran_at': ('django.db.models.fields.DateTimeField', [], {}),
176 'stddev': ('django.db.models.fields.FloatField', [], {'default': '0'}),
177 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
178 'upgrade': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryUpgrade']", 'null': 'True'})
179 },
180 'memory.memoryresult': {
181 'Meta': {'object_name': 'MemoryResult', 'db_table': "'memory_results'"},
182 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
183 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
184 'image': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryImage']", 'null': 'True'}),
185 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
186 'jenkins_url': ('django.db.models.fields.URLField', [], {'max_length': '200', 'null': 'True'}),
187 'kernel': ('django.db.models.fields.CharField', [], {'max_length': '100', 'null': 'True'}),
188 'log': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryLog']"}),
189 'machine': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryMachine']"}),
190 'metric': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryMetric']"}),
191 'name': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
192 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
193 'ran_at': ('django.db.models.fields.DateTimeField', [], {}),
194 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
195 'upgrade': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['memory.MemoryUpgrade']", 'null': 'True'}),
196 'value': ('django.db.models.fields.FloatField', [], {})
197 },
198 'memory.memoryupgrade': {
199 'Meta': {'object_name': 'MemoryUpgrade', 'db_table': "'memory_upgrades'"},
200 'arch': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
201 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
202 'date': ('django.db.models.fields.DateTimeField', [], {}),
203 'from_release': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
204 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
205 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
206 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
207 'release': ('django.db.models.fields.CharField', [], {'max_length': '200'}),
208 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
209 'variant': ('django.db.models.fields.CharField', [], {'max_length': '200'})
210 }
211 }
212
213 complete_apps = ['memory']
0\ No newline at end of file214\ No newline at end of file
1215
=== modified file 'memory/models.py'
--- memory/models.py 2013-05-06 21:18:46 +0000
+++ memory/models.py 2013-07-12 13:44:34 +0000
@@ -351,3 +351,7 @@
351 return 0351 return 0
352352
353 return self.average - prev.average353 return self.average - prev.average
354
355
356class MemoryConfig(DashboardBaseModel):
357 blacklist_process = models.CharField(max_length=4096)
354358
=== modified file 'memory/templates/memory/machine_details.html'
--- memory/templates/memory/machine_details.html 2013-07-10 19:05:25 +0000
+++ memory/templates/memory/machine_details.html 2013-07-12 13:44:34 +0000
@@ -12,7 +12,20 @@
12{% block content %}12{% block content %}
1313
14<div class="grid_15">14<div class="grid_15">
15 <h2>Memory consumption details for {{ build }} on {{ result.machine.name|display_name }} using {{ arch }}</h2>15 <h2>Memory consumption details for {{ result.machine.name|display_name }}</h2>
16 <p>
17 <strong>Build #:</strong> {{ build }}<br />
18 <strong>Arch:</strong> {{ arch }}<br />
19 {% if all %}
20 <a href="{% url memory_machine_image_details arch result.machine.id result.id %}">
21 Hide test framework data
22 </a>
23 {% else %}
24 <a href="?all">
25 Show test framework data
26 </a>
27 {% endif %}
28 </p>
16</div>29</div>
17<div class="grid_15">30<div class="grid_15">
18 <div id="stackedchart">31 <div id="stackedchart">
1932
=== modified file 'memory/tests.py'
--- memory/tests.py 2013-05-31 20:07:19 +0000
+++ memory/tests.py 2013-07-12 13:44:34 +0000
@@ -173,9 +173,9 @@
173173
174 self.assert_(self.detail2)174 self.assert_(self.detail2)
175175
176 call_command('agg_processes')
176 call_command('agg_results')177 call_command('agg_results')
177 call_command('agg_metrics')178 call_command('agg_metrics')
178 call_command('agg_processes')
179179
180 # get updated instances from the DB180 # get updated instances from the DB
181 self.result = MemoryResult.objects.get(id=self.result.id)181 self.result = MemoryResult.objects.get(id=self.result.id)
182182
=== modified file 'memory/views.py'
--- memory/views.py 2013-07-10 19:05:25 +0000
+++ memory/views.py 2013-07-12 13:44:34 +0000
@@ -39,6 +39,7 @@
39 MemoryMetric,39 MemoryMetric,
40 MemoryProcess,40 MemoryProcess,
41 MemoryResult,41 MemoryResult,
42 MemoryConfig,
42)43)
4344
44from memory.tables import (45from memory.tables import (
@@ -292,7 +293,21 @@
292@require_GET293@require_GET
293def machine_image_details(request, arch, machine_id, result_id):294def machine_image_details(request, arch, machine_id, result_id):
294 result = get_object_or_404(MemoryResult, id=result_id)295 result = get_object_or_404(MemoryResult, id=result_id)
295 details = result.memorydetail_set.all().select_related('image', 'machine')296 exclude = MemoryConfig.objects.all().values_list(
297 'blacklist_process',
298 flat=True,
299 )
300
301 all = request.GET.get('all')
302
303 if all is None:
304 all = False
305 details = result.memorydetail_set.exclude(
306 command__in=exclude,
307 ).select_related('image', 'machine')
308 else:
309 all = True
310 details = result.memorydetail_set.select_related('image', 'machine')
296311
297 chart_api = reverse(312 chart_api = reverse(
298 'memory_api_result_processes',313 'memory_api_result_processes',
@@ -354,6 +369,7 @@
354 'table': table,369 'table': table,
355 'totals': totals,370 'totals': totals,
356 'chart_api': chart_api,371 'chart_api': chart_api,
372 'all': all,
357 'bread_crumb_trail': BreadCrumbTrail.leading_to(373 'bread_crumb_trail': BreadCrumbTrail.leading_to(
358 machine_image_details,374 machine_image_details,
359 arch=arch,375 arch=arch,

Subscribers

People subscribed via source and target branches