Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add documentation for Farms #44

Merged
merged 11 commits into from
Oct 6, 2020
Merged

Add documentation for Farms #44

merged 11 commits into from
Oct 6, 2020

Conversation

gabrieltron
Copy link
Contributor

This PR is to add documentation for Farms. While we were working on it, we noticed that we still need to implement multi-tenancy on Farm and Growers before it's safe to make the documentation available. Here's the work on the documentation so far, it'll be improved once multi-tenancy is implemented.

Copy link
Contributor

@ramnaq ramnaq left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well done, mate! (Approved. Please consider my comments and note that you commited .idea files, those can be ignored)

docs/field_boundaries_endpoints.md Outdated Show resolved Hide resolved
docs/field_boundaries_endpoints.md Outdated Show resolved Hide resolved
docs/field_boundaries_endpoints.md Outdated Show resolved Hide resolved
"id": "long",
"name": "str",
"providerName": "str",
"providerFarmId": "UUID",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we remove this from the response? It's unnecessary, from my perspective....

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am referring to "providerFarmId", this is the id of the farm on the provider right?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it is. Why unnecessary? datasync can create farms, so they will have this attribute set

{
"id": "long",
"name": "str",
"providerName": "str",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have to define if the convention will be "providerName" or "provider"... we have both now

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep. I vote for provider

@GMBueno GMBueno marked this pull request as ready for review October 1, 2020 18:51
Copy link
Contributor

@GMBueno GMBueno left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good job! I added a few comments/questions I would like to know before approving 😄

</Tabs>


### `DELETE users/{leafUserId}/farms/{id}`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this delete only at Leaf or at the provider as well? I suppose only at Leaf, but then we pull it again in 30 minutes?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Only at leaft" for the 1st question. "Maybe" for the 2nd. If that farm was created from pooling then yes, we do will create it again. We know 0 real use case for datasync, so I think documenting this kind of endpoint are 100% a product decision. The fact is that all endpoint that allows writting are conflicting with datasync. Currently we're simply ignoring this fact.

</Tabs>


### `POST users/{leafUserId}/farms`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add fields to farms on farm creation?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope, although we can add a farm to a field on field creation. Does this functionality you're asking about make sense?

</Tabs>


### `PUT users/{leafUserId}/farms`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add fields to farms on farm update?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope

@ramnaq ramnaq requested a review from GMBueno October 5, 2020 19:56
docs/field_boundaries_endpoints.md Outdated Show resolved Hide resolved
@GMBueno GMBueno merged commit f819be7 into master Oct 6, 2020
@GMBueno GMBueno deleted the farm-docs branch October 6, 2020 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants