[ 
https://issues.apache.org/jira/browse/USERGRID-27?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14988356#comment-14988356
 ] 

Michael Russo commented on USERGRID-27:
---------------------------------------

This is fixed in 2.1.  Here is pulling back all connections:

{code}
➜  ~  curl 
"http://localhost:8080/test-organization/test-app/library/library1/has";
{
  "action" : "get",
  "application" : "972033e9-8276-11e5-a427-36d323f2ba24",
  "params" : { },
  "path" : "/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has",
  "uri" : 
"http://localhost:8080/test-organization/test-app/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has";,
  "entities" : [ {
    "uuid" : "0eb90f46-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book14",
    "created" : 1446590933420,
    "modified" : 1446590933420,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0eb90f46-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0eb90f46-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "0d46ba4a-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book13",
    "created" : 1446590930993,
    "modified" : 1446590930993,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0d46ba4a-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0d46ba4a-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "0b63ca23-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book12",
    "created" : 1446590927828,
    "modified" : 1446590927828,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0b63ca23-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0b63ca23-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "09f56cc3-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book11",
    "created" : 1446590925427,
    "modified" : 1446590925427,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/09f56cc3-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/09f56cc3-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "0856b090-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book10",
    "created" : 1446590922709,
    "modified" : 1446590922709,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0856b090-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0856b090-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "05228850-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book9",
    "created" : 1446590917334,
    "modified" : 1446590917334,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/05228850-827d-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/05228850-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "03b0cf89-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book8",
    "created" : 1446590914911,
    "modified" : 1446590914911,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/03b0cf89-827d-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/03b0cf89-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "01f7114d-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book7",
    "created" : 1446590912016,
    "modified" : 1446590912016,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/01f7114d-827d-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/01f7114d-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "fff9e266-827c-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book6",
    "created" : 1446590908679,
    "modified" : 1446590908679,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/fff9e266-827c-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/fff9e266-827c-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "fdee3396-827c-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book5",
    "created" : 1446590905247,
    "modified" : 1446590905247,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/fdee3396-827c-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/fdee3396-827c-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "fc53bd22-827c-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book4",
    "created" : 1446590902557,
    "modified" : 1446590902557,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/fc53bd22-827c-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/fc53bd22-827c-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "faae2322-827c-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book3",
    "created" : 1446590899794,
    "modified" : 1446590899794,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/faae2322-827c-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/faae2322-827c-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "f90778af-827c-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book2",
    "created" : 1446590897024,
    "modified" : 1446590897024,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/f90778af-827c-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/f90778af-827c-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "f424b588-827c-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book1",
    "created" : 1446590888827,
    "modified" : 1446590888827,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/f424b588-827c-11e5-9896-36d323f2ba24",
      "size" : 312,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/f424b588-827c-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  } ],
  "timestamp" : 1446591082639,
  "duration" : 20,
  "organization" : "test-organization",
  "applicationName" : "test-app"
}
{code}

Here is pulling back connections using a limit:

{code}
➜  ~  curl 
"http://localhost:8080/test-organization/test-app/library/library1/has?limit=2";
{
  "action" : "get",
  "application" : "972033e9-8276-11e5-a427-36d323f2ba24",
  "params" : {
    "limit" : [ "2" ]
  },
  "path" : "/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has",
  "uri" : 
"http://localhost:8080/test-organization/test-app/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has";,
  "entities" : [ {
    "uuid" : "0eb90f46-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book14",
    "created" : 1446590933420,
    "modified" : 1446590933420,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0eb90f46-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0eb90f46-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  }, {
    "uuid" : "0d46ba4a-827d-11e5-9896-36d323f2ba24",
    "type" : "book",
    "name" : "book13",
    "created" : 1446590930993,
    "modified" : 1446590930993,
    "metadata" : {
      "path" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0d46ba4a-827d-11e5-9896-36d323f2ba24",
      "size" : 313,
      "connecting" : {
        "has" : 
"/libraries/eb88ba91-827c-11e5-9896-36d323f2ba24/has/0d46ba4a-827d-11e5-9896-36d323f2ba24/connecting/has"
      }
    }
  } ],
  "timestamp" : 1446591155596,
  "duration" : 12,
  "organization" : "test-organization",
  "applicationName" : "test-app",
  "cursor" : 
"OikKAfqAM_qDdXVpZGMwZDQ2YmE0YS04MjdkLTExZTUtOTg5Ni0zNmQzMjNmMmJhMjSDdHlwZUNib29r-4Ax-olzb3VyY2VOb2Rl-kFjZWI4OGJhOTEtODI3Yy0xMWU1LTk4OTYtMzZkMzIzZjJiYTI0QkZsaWJyYXJ5-0JNenp6Y29ubnp6enxoYXOJdGFyZ2V0Tm9kZfpBYzBlYjkwZjQ2LTgyN2QtMTFlNS05ODk2LTM2ZDMyM2YyYmEyNEJDYm9va_uIdGltZXN0YW1wJQdLAj5MAmJSqvv7"
}
{code}

> Limit on connection query not working
> -------------------------------------
>
>                 Key: USERGRID-27
>                 URL: https://issues.apache.org/jira/browse/USERGRID-27
>             Project: Usergrid
>          Issue Type: Bug
>          Components: Stack
>            Reporter: Rod Simpson
>            Priority: Blocker
>
> Also "limit" doesn't seems to be working for connections for e.g. 
> https://api.usergrid.com/fdsafdsa/test/users/me/connecting/shares?limit=2&access_token=YWMtSQ92bBCsEeOYAQ1TRlcn_AAAAUDuPjgtlh06pENBKFRmoxta8jg1XwRuwVs.
>  Returns all in our case is 3



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to