SpaceTradersAPI / issues-and-suggestions

16 stars 1 forks source link

Return ship flight plans when queried by ID #47

Closed artokun closed 3 years ago

bchoii commented 3 years ago

I realized I cannot query flightplan.

Then I thought, I actually had it at one time when I created a flight path. I could have saved it then. It is not critical information, having it missing doesn't affect gameplay greatly other than not knowing when the ship will arrive. The fact that so many clients are working without this ability proves it is not critical. In fact, missing it would even encourage developers to build their own cache.

This would further have a side effect of decreasing unnecessary, uncritical API loads on the server. You already have the data. You should not need to keep querying for it.

This could help differentiate between good enough clients and great, advanced clients.

There is merit in NOT having the ability to query flightplan.

artokun commented 3 years ago

Very true, maybe we just don’t eager load it with the list of user ships as I’d the case currently, but the app is intended to be newbie friendly so it might help have a single user ship endpoint that loads in the flight plan? Once we add in a cost to the request, that could potentially encourage caching instead of pinging updates constantly. I think caching should at least be recommended as a step before creating a flight plan in the api and tutorial.

Great insight!

On Mar 7, 2021, at 7:17 AM, bchoii notifications@github.com wrote:

 I realized I cannot query flightplan.

Then I thought, I actually had it at one time when I created a flight path. I could have saved it then. It is not critical information, having it missing doesn't affect gameplay greatly other than not knowing when the ship will arrive. In fact, missing it would even encourage developers to build their own cache.

This would further have a side effect of decreasing unnecessary, uncritical API loads on the server. You already have the data. You should not need to keep querying for it.

This could help differentiate between good enough clients and great, advanced clients.

There is merit in NOT having the ability to query flightplan.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

bchoii commented 3 years ago

Yes.

I can imagine a situation where clients abuse this API to update their ship movement, every few seconds.

HamishWHC commented 3 years ago

However, many clients are stateless and do not create the flight plans themselves, but are a way to monitor other applications actually creating flight plans.

HamishWHC commented 3 years ago

@artokun Has this been added or has it been rejected?

artokun commented 3 years ago

My bad, forgot to flip the tag when I closed it