Hi Gimantha, it depends on the scenario: if you want to check existence of resource it's fine to use a GET on this resource and receive a "404 Not Found".
But the subtlety is that "Not Found" according to HTTP is statement in time: you cannot infer that the resource "does not exist", all that 404 says is that it cannot be found at this point in time, i.e. it maybe found later. If your scenario doesn't care about that you are fine. Furthermore, in case the resource in fact is found, the GET on this resource will return the complete table. This might not be acceptable if you only want to get an indicator that the exists. The signal for existence shouldn't the possibly huge table itself. Thus, depending on your scenario you may consider a corresponding function. By the way, this is completely compliant to the REST style that foresees such "processing function resources". Best regards, Frank 2015-02-14 15:01 GMT+01:00 Gimantha Bandara <giman...@wso2.com>: > Hi Manuranga, > > Already *GET /analytics/tables/{tableName} *returns 404 if the > table doesn't exists. So we will not need a separate API. Thanks for your > feedback. > > On Sat, Feb 14, 2015 at 12:22 PM, Manuranga Perera <m...@wso2.com> wrote: > >> there shouldn't be a separate end point for "is-exists" >> >> *GET /analytics/tables/{tableName}* - Will return table informing if it >> exists and if not it should return 404 >> >> _______________________________________________ >> Architecture mailing list >> Architecture@wso2.org >> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture >> >> > > > -- > Gimantha Bandara > Software Engineer > WSO2. Inc : http://wso2.com > Mobile : +94714961919 > > _______________________________________________ > Architecture mailing list > Architecture@wso2.org > https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture > >
_______________________________________________ Architecture mailing list Architecture@wso2.org https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture