)]}'
{"README.rst":[{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"d035a495147475f60d9d497aa5ea8eb822880231","unresolved":false,"context_lines":[{"line_number":107,"context_line":"    import requests"},{"line_number":108,"context_line":"    import json"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    r \u003d requests.post(\u0027http://0.0.0.0:8041/v1/entity\u0027, data\u003djson.dumps({\"archives\": [[1, 3600]]}))"},{"line_number":111,"context_line":"    print r.status_code"},{"line_number":112,"context_line":"    print r.text"}],"source_content_type":"text/x-rst","patch_set":11,"id":"fa98f980_92791c33","line":110,"updated":"2014-09-16 09:56:27.000000000","message":"Same change needed here also:\n\n  s/{\"archives\": [[1, 3600]]}/{\"archive_policy\": \"high\"}/","commit_id":"6a7f3eacbdc3ef01b7cabb81333038f49376fdb8"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"47facb4b5987ddf35b80bbcaa834a38bbe5cd237","unresolved":false,"context_lines":[{"line_number":107,"context_line":"    import requests"},{"line_number":108,"context_line":"    import json"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    r \u003d requests.post(\u0027http://0.0.0.0:8041/v1/entity\u0027, data\u003djson.dumps({\"archives\": [[1, 3600]]}))"},{"line_number":111,"context_line":"    print r.status_code"},{"line_number":112,"context_line":"    print r.text"}],"source_content_type":"text/x-rst","patch_set":11,"id":"fa98f980_6c55b7f9","line":110,"in_reply_to":"fa98f980_92791c33","updated":"2014-09-16 13:37:28.000000000","message":"Done","commit_id":"6a7f3eacbdc3ef01b7cabb81333038f49376fdb8"}],"gnocchi/rest/__init__.py":[{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"df00fb6caa3475b5f2932c010a60a01fae11a126","unresolved":false,"context_lines":[{"line_number":143,"context_line":"    def post(self, body):"},{"line_number":144,"context_line":"        # TODO(jd) Use policy to limit what values the user can use as"},{"line_number":145,"context_line":"        # \u0027archive\u0027?"},{"line_number":146,"context_line":"        id \u003d self.create_entity(body[\u0027archive_policy\u0027])"},{"line_number":147,"context_line":"        pecan.response.headers[\u0027Location\u0027] \u003d \"/v1/entity/\" + str(id)"},{"line_number":148,"context_line":"        pecan.response.status \u003d 201"},{"line_number":149,"context_line":"        return {\"id\": str(id),"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa98f980_80639baf","line":146,"updated":"2014-09-15 15:41:31.000000000","message":"Would it be good to have a default archiving policy if not explicitly specified? e.g.\n\n  id \u003d self.create_entity(body.get(\u0027archive_policy\u0027, \u0027low\u0027))","commit_id":"ec136f6469502b7c71da48126ad488917bbaff4f"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"25f02e07a54b2036401b24aca7b75f3ba3a381fd","unresolved":false,"context_lines":[{"line_number":143,"context_line":"    def post(self, body):"},{"line_number":144,"context_line":"        # TODO(jd) Use policy to limit what values the user can use as"},{"line_number":145,"context_line":"        # \u0027archive\u0027?"},{"line_number":146,"context_line":"        id \u003d self.create_entity(body[\u0027archive_policy\u0027])"},{"line_number":147,"context_line":"        pecan.response.headers[\u0027Location\u0027] \u003d \"/v1/entity/\" + str(id)"},{"line_number":148,"context_line":"        pecan.response.status \u003d 201"},{"line_number":149,"context_line":"        return {\"id\": str(id),"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa98f980_1565191d","line":146,"in_reply_to":"fa98f980_80639baf","updated":"2014-09-16 08:51:05.000000000","message":"It\u0027s mandatory in the schema to specify one. Do we really want to make it optional? We could. But then we\u0027d need a config option I guess to set the default. Not sure it\u0027s worth it, but if am not strongly opiniated on this one.","commit_id":"ec136f6469502b7c71da48126ad488917bbaff4f"}],"gnocchi/storage/__init__.py":[{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"9d924d41bd94ad53d8046d8add1a253cc13e0751","unresolved":false,"context_lines":[{"line_number":31,"context_line":"ARCHIVE_POLICIES \u003d {"},{"line_number":32,"context_line":"    \u0027low\u0027: ["},{"line_number":33,"context_line":"        # 5 minutes resolution for an hour"},{"line_number":34,"context_line":"        (300, 12),"},{"line_number":35,"context_line":"        # 1 hour resolution for a day"},{"line_number":36,"context_line":"        (3600, 24),"},{"line_number":37,"context_line":"        # 1 day resolution for a month"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_69572702","line":34,"updated":"2014-08-13 14:43:21.000000000","message":"For readability, how defining these as named tuples?\n\ne.g.\n\n  RetentionPolicy \u003d collections.namedtuple(\u0027Retention\u0027, [\u0027granularity\u0027, \u0027span\u0027])\n  \n  ARCHIVE_POLICIES \u003d {\n      \u0027low\u0027: [\n          RetentionPolicy(granularity\u003d300, span\u003d12),\n          ...","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"c1584e2e1ab60360d4382e9f47775cbfd69a8e71","unresolved":false,"context_lines":[{"line_number":31,"context_line":"ARCHIVE_POLICIES \u003d {"},{"line_number":32,"context_line":"    \u0027low\u0027: ["},{"line_number":33,"context_line":"        # 5 minutes resolution for an hour"},{"line_number":34,"context_line":"        (300, 12),"},{"line_number":35,"context_line":"        # 1 hour resolution for a day"},{"line_number":36,"context_line":"        (3600, 24),"},{"line_number":37,"context_line":"        # 1 day resolution for a month"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_ccb3e14c","line":34,"in_reply_to":"baada198_69572702","updated":"2014-08-13 14:55:04.000000000","message":"I\u0027ll do that sure.","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"9d924d41bd94ad53d8046d8add1a253cc13e0751","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    \u0027low\u0027: ["},{"line_number":33,"context_line":"        # 5 minutes resolution for an hour"},{"line_number":34,"context_line":"        (300, 12),"},{"line_number":35,"context_line":"        # 1 hour resolution for a day"},{"line_number":36,"context_line":"        (3600, 24),"},{"line_number":37,"context_line":"        # 1 day resolution for a month"},{"line_number":38,"context_line":"        (3600 * 24, 30),"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_8939db42","line":35,"updated":"2014-08-13 14:43:21.000000000","message":"Nice!\n\nTotally agree on the retention being coupled with a time-span as opposed to a number of datapoints (exactly as we discussed at mid-cycle IIRC).","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"c1584e2e1ab60360d4382e9f47775cbfd69a8e71","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    \u0027low\u0027: ["},{"line_number":33,"context_line":"        # 5 minutes resolution for an hour"},{"line_number":34,"context_line":"        (300, 12),"},{"line_number":35,"context_line":"        # 1 hour resolution for a day"},{"line_number":36,"context_line":"        (3600, 24),"},{"line_number":37,"context_line":"        # 1 day resolution for a month"},{"line_number":38,"context_line":"        (3600 * 24, 30),"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_8c456918","line":35,"in_reply_to":"baada198_8939db42","updated":"2014-08-13 14:55:04.000000000","message":"Yeah, I envision the REST API allowing to specify things like:\n\n{ granularity: \"1 hour\",\n  timespan: \"1 day\" }\n\nwhich will be translated for you to:\n\n{ granularity: 3600,\n  points: 24 }","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"815a10dede60e09411dd43f93be048ffa9ac201e","unresolved":false,"context_lines":[{"line_number":32,"context_line":"    \u0027low\u0027: ["},{"line_number":33,"context_line":"        # 5 minutes resolution for an hour"},{"line_number":34,"context_line":"        (300, 12),"},{"line_number":35,"context_line":"        # 1 hour resolution for a day"},{"line_number":36,"context_line":"        (3600, 24),"},{"line_number":37,"context_line":"        # 1 day resolution for a month"},{"line_number":38,"context_line":"        (3600 * 24, 30),"}],"source_content_type":"text/x-python","patch_set":1,"id":"7ac7a964_7aad3588","line":35,"in_reply_to":"baada198_8c456918","updated":"2014-08-14 13:16:17.000000000","message":"Cool.","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"9d924d41bd94ad53d8046d8add1a253cc13e0751","unresolved":false,"context_lines":[{"line_number":53,"context_line":"        # 1 hour resolution for a year"},{"line_number":54,"context_line":"        (3600, 365 * 24 * 3600),"},{"line_number":55,"context_line":"    ],"},{"line_number":56,"context_line":"}"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"OPTS \u003d ["},{"line_number":59,"context_line":"    cfg.StrOpt(\u0027driver\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_09e4eb40","line":56,"updated":"2014-08-13 14:43:21.000000000","message":"Do we need a \"keep forever\" policy?","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"6ac65c708560c2c07b88fb48b515de5fba8f0205","unresolved":false,"context_lines":[{"line_number":53,"context_line":"        # 1 hour resolution for a year"},{"line_number":54,"context_line":"        (3600, 365 * 24 * 3600),"},{"line_number":55,"context_line":"    ],"},{"line_number":56,"context_line":"}"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"OPTS \u003d ["},{"line_number":59,"context_line":"    cfg.StrOpt(\u0027driver\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"7ac7a964_0edebf3f","line":56,"in_reply_to":"7ac7a964_7a58d556","updated":"2014-08-14 14:31:09.000000000","message":"Ok, that\u0027s indeed interesting. I\u0027m gonna let this as it is right now in this patch, but I\u0027ll do take that into account when designing the storage driver API for the archive policy.","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"c1584e2e1ab60360d4382e9f47775cbfd69a8e71","unresolved":false,"context_lines":[{"line_number":53,"context_line":"        # 1 hour resolution for a year"},{"line_number":54,"context_line":"        (3600, 365 * 24 * 3600),"},{"line_number":55,"context_line":"    ],"},{"line_number":56,"context_line":"}"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"OPTS \u003d ["},{"line_number":59,"context_line":"    cfg.StrOpt(\u0027driver\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_0c487961","line":56,"in_reply_to":"baada198_09e4eb40","updated":"2014-08-13 14:55:04.000000000","message":"I can add one, though I think we want to be able to remove all these definitions in a next patch and let the users/operators create their own policy via the REST API, right?","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"815a10dede60e09411dd43f93be048ffa9ac201e","unresolved":false,"context_lines":[{"line_number":53,"context_line":"        # 1 hour resolution for a year"},{"line_number":54,"context_line":"        (3600, 365 * 24 * 3600),"},{"line_number":55,"context_line":"    ],"},{"line_number":56,"context_line":"}"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"OPTS \u003d ["},{"line_number":59,"context_line":"    cfg.StrOpt(\u0027driver\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"7ac7a964_7a58d556","line":56,"in_reply_to":"baada198_0c487961","updated":"2014-08-14 13:16:17.000000000","message":"Well, the way I thought this might play out was to have a set of built-in or statically configured policies dictated by the restrictions of the current storage driver, with the *optional* extra ability to create these policies dynamically via the REST API only if the storage driver can support this.\n\nFor example you could distinguish between:\n* expiry \u0026 downsampling in InfluxDB requires specific initial setup on the DB side, of continuous queries and naming conventions on the timeseries, that doesn\u0027t really scale to creating loads of these policies, or isn\u0027t even that suited to creating even just a few of them dynamically \n* expiry \u0026 downsampling in the Swift driver is easily extensible to an almost infinite variety of archiving policies, so is suited to the dynamic creation of policies via the REST API\n\nSo it seems to me like the individual storage driver should report the initial set of policies that it has available for use, and also indicate its capabilities to create new policies.","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"9d924d41bd94ad53d8046d8add1a253cc13e0751","unresolved":false,"context_lines":[{"line_number":108,"context_line":"        pass"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    @staticmethod"},{"line_number":111,"context_line":"    def create_entity(entity, archive_policy):"},{"line_number":112,"context_line":"        \"\"\"Create an entity."},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"        :param entity: The entity key."}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_89c47b43","line":111,"updated":"2014-08-13 14:43:21.000000000","message":"Hmmm, using a single policy to identify 3 separate (granularity, span) pairs seems a bit wasteful to me, in the sense that users may generally want just a single (granularity, span) to be defined for the entity.","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"c1584e2e1ab60360d4382e9f47775cbfd69a8e71","unresolved":false,"context_lines":[{"line_number":108,"context_line":"        pass"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    @staticmethod"},{"line_number":111,"context_line":"    def create_entity(entity, archive_policy):"},{"line_number":112,"context_line":"        \"\"\"Create an entity."},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"        :param entity: The entity key."}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_8ca9e9e0","line":111,"in_reply_to":"baada198_89c47b43","updated":"2014-08-13 14:55:04.000000000","message":"If your archive policy is just composed of a single retention policy like \"1 hour resolution for a year\" it\u0027s ok, but if we force to do that, you\u0027re going to lot of precision, or you will have to create different entities for different precision on the same metric source, which is not what we want AFAIK.","commit_id":"f73d65fe5171f5ec1d70327a3c8f0078f656f824"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"7e22e0befc0e4ed8552a2905553eced863842a32","unresolved":false,"context_lines":[{"line_number":54,"context_line":"        # 1 second resolution for a day"},{"line_number":55,"context_line":"        ArchivePolicy(1, 3600 * 24),"},{"line_number":56,"context_line":"        # 1 minute resolution for a month"},{"line_number":57,"context_line":"        ArchivePolicy(60, 60 * 24 * 3600),"},{"line_number":58,"context_line":"        # 1 hour resolution for a year"},{"line_number":59,"context_line":"        ArchivePolicy(3600, 365 * 24 * 3600),"},{"line_number":60,"context_line":"    ],"}],"source_content_type":"text/x-python","patch_set":2,"id":"1abeadc6_4025e808","line":57,"updated":"2014-08-25 19:32:18.000000000","message":"should 3600 be 30?","commit_id":"f5d67f05e774fda5918426955aa56c6b0b72a712"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"7af519a49a84a09eabcc03830cc361a6a42e5ac0","unresolved":false,"context_lines":[{"line_number":54,"context_line":"        # 1 second resolution for a day"},{"line_number":55,"context_line":"        ArchivePolicy(1, 3600 * 24),"},{"line_number":56,"context_line":"        # 1 minute resolution for a month"},{"line_number":57,"context_line":"        ArchivePolicy(60, 60 * 24 * 3600),"},{"line_number":58,"context_line":"        # 1 hour resolution for a year"},{"line_number":59,"context_line":"        ArchivePolicy(3600, 365 * 24 * 3600),"},{"line_number":60,"context_line":"    ],"}],"source_content_type":"text/x-python","patch_set":2,"id":"1abeadc6_45dda86f","line":57,"in_reply_to":"1abeadc6_4025e808","updated":"2014-08-27 12:39:20.000000000","message":"(30 days * 24 hours * 60 minutes * 60 seconds) / 60\n\nYup should be 60 not 3600. :)","commit_id":"f5d67f05e774fda5918426955aa56c6b0b72a712"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"7e22e0befc0e4ed8552a2905553eced863842a32","unresolved":false,"context_lines":[{"line_number":56,"context_line":"        # 1 minute resolution for a month"},{"line_number":57,"context_line":"        ArchivePolicy(60, 60 * 24 * 3600),"},{"line_number":58,"context_line":"        # 1 hour resolution for a year"},{"line_number":59,"context_line":"        ArchivePolicy(3600, 365 * 24 * 3600),"},{"line_number":60,"context_line":"    ],"},{"line_number":61,"context_line":"}"},{"line_number":62,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"1abeadc6_20a46c56","line":59,"updated":"2014-08-25 19:32:18.000000000","message":"is 3600 needed here?","commit_id":"f5d67f05e774fda5918426955aa56c6b0b72a712"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"7af519a49a84a09eabcc03830cc361a6a42e5ac0","unresolved":false,"context_lines":[{"line_number":56,"context_line":"        # 1 minute resolution for a month"},{"line_number":57,"context_line":"        ArchivePolicy(60, 60 * 24 * 3600),"},{"line_number":58,"context_line":"        # 1 hour resolution for a year"},{"line_number":59,"context_line":"        ArchivePolicy(3600, 365 * 24 * 3600),"},{"line_number":60,"context_line":"    ],"},{"line_number":61,"context_line":"}"},{"line_number":62,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"1abeadc6_c5d0d855","line":59,"in_reply_to":"1abeadc6_20a46c56","updated":"2014-08-27 12:39:20.000000000","message":"No, thanks.","commit_id":"f5d67f05e774fda5918426955aa56c6b0b72a712"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"1423fc85597954daeea8bb7e54b7110de33094a6","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        # 1 second resolution for a day"},{"line_number":58,"context_line":"        ArchivePolicy(1, 3600 * 24),"},{"line_number":59,"context_line":"        # 1 minute resolution for a month"},{"line_number":60,"context_line":"        ArchivePolicy(60, 60 * 24 * 60),"},{"line_number":61,"context_line":"        # 1 hour resolution for a year"},{"line_number":62,"context_line":"        ArchivePolicy(3600, 365 * 24),"},{"line_number":63,"context_line":"    ],"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa98f980_9b7a6586","line":60,"updated":"2014-09-12 12:59:35.000000000","message":"you mean 30 * 24 * 60? (30 days * 24 hours * 60 minutes)","commit_id":"fb9e3fad642275d6190ea48388afecb16535b138"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"538be57073a4f66569674424521b76c35afcb8d7","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        # 1 second resolution for a day"},{"line_number":58,"context_line":"        ArchivePolicy(1, 3600 * 24),"},{"line_number":59,"context_line":"        # 1 minute resolution for a month"},{"line_number":60,"context_line":"        ArchivePolicy(60, 60 * 24 * 60),"},{"line_number":61,"context_line":"        # 1 hour resolution for a year"},{"line_number":62,"context_line":"        ArchivePolicy(3600, 365 * 24),"},{"line_number":63,"context_line":"    ],"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa98f980_7b7a21f2","line":60,"in_reply_to":"fa98f980_9b7a6586","updated":"2014-09-12 13:36:05.000000000","message":"Done","commit_id":"fb9e3fad642275d6190ea48388afecb16535b138"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"df00fb6caa3475b5f2932c010a60a01fae11a126","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        # 1 hour resolution for a day"},{"line_number":44,"context_line":"        ArchivePolicy(3600, 24),"},{"line_number":45,"context_line":"        # 1 day resolution for a month"},{"line_number":46,"context_line":"        ArchivePolicy(3600 * 24, 30),"},{"line_number":47,"context_line":"    ],"},{"line_number":48,"context_line":"    \u0027medium\u0027: ["},{"line_number":49,"context_line":"        # 1 minute resolution for an hour"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa98f980_603957a3","line":46,"updated":"2014-09-15 15:41:31.000000000","message":"I guess this is going to change in a subsequent patch, but I\u0027m wondering about the approach of grouping multiple ArchivePolicies by default into triples.\n\nUsers *may* prefer the flexibility of mixing and matching individual policies, as opposed to always talking these as a group?","commit_id":"ec136f6469502b7c71da48126ad488917bbaff4f"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"25f02e07a54b2036401b24aca7b75f3ba3a381fd","unresolved":false,"context_lines":[{"line_number":43,"context_line":"        # 1 hour resolution for a day"},{"line_number":44,"context_line":"        ArchivePolicy(3600, 24),"},{"line_number":45,"context_line":"        # 1 day resolution for a month"},{"line_number":46,"context_line":"        ArchivePolicy(3600 * 24, 30),"},{"line_number":47,"context_line":"    ],"},{"line_number":48,"context_line":"    \u0027medium\u0027: ["},{"line_number":49,"context_line":"        # 1 minute resolution for an hour"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa98f980_553961f0","line":46,"in_reply_to":"fa98f980_603957a3","updated":"2014-09-16 08:51:05.000000000","message":"You can\u0027t define your own policies (for now) and an entity has only one archive policy assigned to it. So you have to predefine the set (triplet, duet, or anything else :) of ArchivePolicy you want.\n\nIf we allow to mix \u0026 match individual policy, it\u0027s going to be complicated for the user to create entities where he is sure that it can use them for aggregation.","commit_id":"ec136f6469502b7c71da48126ad488917bbaff4f"}],"gnocchi/tests/test_rest.py":[{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"df00fb6caa3475b5f2932c010a60a01fae11a126","unresolved":false,"context_lines":[{"line_number":49,"context_line":"class EntityTest(RestTest):"},{"line_number":50,"context_line":"    def test_post_entity(self):"},{"line_number":51,"context_line":"        result \u003d self.app.post_json(\"/v1/entity\","},{"line_number":52,"context_line":"                                    params\u003d{\"archive_policy\": \u0027medium\u0027})"},{"line_number":53,"context_line":"        self.assertEqual(\"application/json\", result.content_type)"},{"line_number":54,"context_line":"        self.assertEqual(201, result.status_code)"},{"line_number":55,"context_line":"        entity \u003d json.loads(result.body)"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa98f980_602eb744","line":52,"updated":"2014-09-15 15:41:31.000000000","message":"Dumb nitpick, mixed quote style on this line.","commit_id":"ec136f6469502b7c71da48126ad488917bbaff4f"},{"author":{"_account_id":1669,"name":"Julien Danjou","display_name":"jd","email":"julien@danjou.info","username":"jdanjou"},"change_message_id":"25f02e07a54b2036401b24aca7b75f3ba3a381fd","unresolved":false,"context_lines":[{"line_number":49,"context_line":"class EntityTest(RestTest):"},{"line_number":50,"context_line":"    def test_post_entity(self):"},{"line_number":51,"context_line":"        result \u003d self.app.post_json(\"/v1/entity\","},{"line_number":52,"context_line":"                                    params\u003d{\"archive_policy\": \u0027medium\u0027})"},{"line_number":53,"context_line":"        self.assertEqual(\"application/json\", result.content_type)"},{"line_number":54,"context_line":"        self.assertEqual(201, result.status_code)"},{"line_number":55,"context_line":"        entity \u003d json.loads(result.body)"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa98f980_d52c71ae","line":52,"in_reply_to":"fa98f980_602eb744","updated":"2014-09-16 08:51:05.000000000","message":"Done","commit_id":"ec136f6469502b7c71da48126ad488917bbaff4f"}]}
