Permalink
Browse files

Merge branch 'json_build_refs' of git://github.com/szager/buildbot

* 'json_build_refs' of git://github.com/szager/buildbot:
  Don't cache json build status objects; they are never cleaned up.
  • Loading branch information...
2 parents a44531a + ff8480d commit 2e77303668e39dfdbf563e370854c9120ab8e6a0 @djmitche djmitche committed May 2, 2012
Showing with 1 addition and 11 deletions.
  1. +1 −11 master/buildbot/status/web/status_json.py
@@ -446,17 +446,7 @@ def getChild(self, path, request):
if isinstance(path, int) or _IS_INT.match(path):
build_status = self.builder_status.getBuild(int(path))
if build_status:
- build_status_number = str(build_status.getNumber())
- # Happens with negative numbers.
- child = self.children.get(build_status_number)
- if child:
- return child
- # Create it on-demand.
- child = BuildJsonResource(self.status, build_status)
- # Cache it. Never cache negative numbers.
- # TODO(maruel): Cleanup the cache once it's too heavy!
- self.putChild(build_status_number, child)
- return child
+ return BuildJsonResource(self.status, build_status)
return JsonResource.getChild(self, path, request)
def asDict(self, request):

0 comments on commit 2e77303

Please sign in to comment.