ODM2 / ODM2RESTfulWebServices

A Python RESTful web service inteface for accessing data in an ODM2 database via Django rest swagger APIs.
http://odm2.github.io/ODM2RESTfulWebServices/
BSD 3-Clause "New" or "Revised" License
3 stars 4 forks source link

SamplingFeatureDatasets appending all previous samplingfeature datasets to further queries. #65

Closed Elijahwalkerwest closed 6 years ago

Elijahwalkerwest commented 6 years ago

Doing some testing with Mauriel today we discovered a strange behavior. Only the first query made returns accurate data. Each further query appends the datasets of all previous queries to a consistent object. E.G.

If you start the server and query id 1001, it returns 2 datasets.

If you start the server and query id 1002 it returns 3 datasets.

However if you first query 1001, then 1002, both objects show 5 datasets instead.

And if you after that make a query for ONLY 1003, (Which should only have 2 datasets) It will contain every dataset queried so far. So, 7 in total.

So each object acquires the dataset of each previously queried object. This also explains why the query is so monstrously slow. Instead of a a set of 3 objects that contain 2, 3, and 2 datasets. It's 3 objects that each contains 7 datasets. Which, if you are querying a large amount of ID's, get's absurdly large.

Elijahwalkerwest commented 6 years ago

sfds_issue1 sfds_issue2

Elijahwalkerwest commented 6 years ago

Appears to be an issue with the ODM2PythonAPI.

Additionally, it seems to break every FURTHER query. i.e. once you query any two samplingfeature ID's, all further queries will have thei datasets appended. So it seems each time a unique dataset is queried, it is permanently added to datasets of each object.

Elijahwalkerwest commented 6 years ago

ODM2PYTHONapi issue, closing here and re-opening there.

Elijahwalkerwest commented 6 years ago

issue #130