Cannot filter on blacklists, records, & tlds

Bug #1466649 reported by Mimi Lee
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Designate
Fix Released
Low
Mimi Lee

Bug Description

Doc (http://docs.openstack.org/developer/designate/rest/v2/collections.html#filtering) lists attributes that supports filtering, but does not work for blacklists, records, and tlds.

{{endpoint}}/v2/blacklists?pattern=*.edu*

{
  "blacklists": [
    {
      "description": null,
      "links": {
        "self": "http://127.0.0.1:9001/v2/blacklists/b328f386-542f-4423-a877-4abc8dbd75bb"
      },
      "pattern": "^([A-Za-z0-9_\\\\-]+\\\\.)*example\\\\.com\\\\.$",
      "created_at": "2015-06-18T19:59:49.000000",
      "updated_at": null,
      "id": "b328f386-542f-4423-a877-4abc8dbd75bb"
    },
    {
      "description": null,
      "links": {
        "self": "http://127.0.0.1:9001/v2/blacklists/709dd881-5c5f-4fa9-8d8d-da7017ce178f"
      },
      "pattern": "^([A-Z_\\\\-]+\\\\.)*yes\\\\.edu\\\\.$",
      "created_at": "2015-06-18T20:00:54.000000",
      "updated_at": null,
      "id": "709dd881-5c5f-4fa9-8d8d-da7017ce178f"
    }
  ],
  "links": {
    "self": "http://127.0.0.1:9001/v2/blacklists?pattern=%2A.edu%2A"
  }
}

----------------------------------

{{endpoint}}/v1/domains/8745bc62-a815-42db-ab90-497d8a00758e/records?data=server1.com.

{
  "records": [
    {
      "created_at": "2015-06-12T17:39:07.000000",
      "data": "nameofserver.com.",
      "description": null,
      "domain_id": "8745bc62-a815-42db-ab90-497d8a00758e",
      "id": "889bd36b-f3ec-4b73-991c-0d11f98b5ec7",
      "name": "randomexample.com.",
      "priority": null,
      "ttl": null,
      "type": "NS",
      "updated_at": "2015-06-12T19:05:56.000000"
    },
    {
      "created_at": "2015-06-12T17:39:07.000000",
      "data": "nameofserver.com. user.example.org. 1434130806 3600 600 86400 3600",
      "description": null,
      "domain_id": "8745bc62-a815-42db-ab90-497d8a00758e",
      "id": "949693c6-0cc0-4115-a596-fca559f7df82",
      "name": "randomexample.com.",
      "priority": null,
      "ttl": null,
      "type": "SOA",
      "updated_at": "2015-06-12T19:05:56.000000"
    },
    {
      "created_at": "2015-06-12T17:40:06.000000",
      "data": "server1.com.",
      "description": null,
      "domain_id": "8745bc62-a815-42db-ab90-497d8a00758e",
      "id": "145b8546-b566-4afd-8393-607aeb1d4268",
      "name": "randomexample.com.",
      "priority": null,
      "ttl": null,
      "type": "NS",
      "updated_at": "2015-06-12T19:05:56.000000"
    }
  ]
}

----------------------------------

{{endpoint}}/v2/tlds?name=edu

{
  "tlds": [
    {
      "name": "com",
      "links": {
        "self": "http://127.0.0.1:9001/v2/tlds/89b97a62-16a5-450f-b651-1c5e3d14e943"
      },
      "created_at": "2015-06-18T19:55:35.000000",
      "updated_at": null,
      "id": "89b97a62-16a5-450f-b651-1c5e3d14e943",
      "description": "Tld source http://data.iana.org/TLD/tlds-alpha-by-domain.txt"
    },
    {
      "name": "edu",
      "links": {
        "self": "http://127.0.0.1:9001/v2/tlds/0b8cda57-2584-49f7-9f66-74a42939a6bc"
      },
      "created_at": "2015-06-18T19:56:37.000000",
      "updated_at": null,
      "id": "0b8cda57-2584-49f7-9f66-74a42939a6bc",
      "description": null
    }
  ],
  "links": {
    "self": "http://127.0.0.1:9001/v2/tlds?name=edu"
  }
}

Kiall Mac Innes (kiall)
tags: added: low-hanging-fruit
Tim Simmons (timsim)
Changed in designate:
status: New → Triaged
importance: Undecided → Low
status: Triaged → New
importance: Low → Undecided
status: New → Triaged
importance: Undecided → Low
milestone: none → liberty-2
sonu (sonu-bhumca11)
Changed in designate:
assignee: nobody → sonu (sonu-bhumca11)
Mimi Lee (mimi-lee)
Changed in designate:
assignee: sonu (sonu-bhumca11) → Mimi Lee (mimi-lee)
Changed in designate:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to designate (master)

Reviewed: https://review.openstack.org/199263
Committed: https://git.openstack.org/cgit/openstack/designate/commit/?id=e73a95d4bb28bab065e2bf0417e2c0c71d76542e
Submitter: Jenkins
Branch: master

commit e73a95d4bb28bab065e2bf0417e2c0c71d76542e
Author: mimi8890 <email address hidden>
Date: Tue Jul 7 20:35:28 2015 +0000

    Enable filter on blacklists & tlds

    Can filter on blacklists by pattern and tlds by name.
    Deleted from doc that filters are supported on records.
    Added unit tests

    Change-Id: I541ebc46424b51603a1b95afc36f1c9eb5f1e2a4
    Closes-Bug: 1466649

Changed in designate:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to designate (stable/kilo)

Fix proposed to branch: stable/kilo
Review: https://review.openstack.org/202221

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to designate (stable/kilo)

Reviewed: https://review.openstack.org/202221
Committed: https://git.openstack.org/cgit/openstack/designate/commit/?id=368ae4363e8565609cc112c8389058bfd30f9861
Submitter: Jenkins
Branch: stable/kilo

commit 368ae4363e8565609cc112c8389058bfd30f9861
Author: mimi8890 <email address hidden>
Date: Tue Jul 7 20:35:28 2015 +0000

    Enable filter on blacklists & tlds

    Can filter on blacklists by pattern and tlds by name.
    Deleted from doc that filters are supported on records.
    Added unit tests

    Change-Id: I541ebc46424b51603a1b95afc36f1c9eb5f1e2a4
    Closes-Bug: 1466649

tags: added: in-stable-kilo
Thierry Carrez (ttx)
Changed in designate:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in designate:
milestone: liberty-2 → 1.0.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.