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

Update /series API to only get AniDB data if requested #5166

Merged
merged 5 commits into from
Sep 9, 2018

Conversation

sharkykh
Copy link
Contributor

@sharkykh sharkykh commented Sep 8, 2018

  • Add fetch argument to /series API endpoint
    Only fetch AniDB info when it is set to True (default is False)
  • Update editShow to get AniDB data
  • Update store/shows actions
  • Update changelog

This will fix the calls to AniDB (for every anime show in the library) when navigating to displayShow for a show of any type (normal or anime).

Closes #5170

@sharkykh sharkykh removed the Changelog Requires a changelog entry label Sep 8, 2018
Copy link
Collaborator

@OmgImAlexis OmgImAlexis left a comment

Choose a reason for hiding this comment

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

LGTM

@p0psicles p0psicles merged commit cf14dcd into develop Sep 9, 2018
@p0psicles p0psicles deleted the feature/api-series-fetch branch September 9, 2018 07:39
@p0psicles
Copy link
Contributor

I dont see this as the most desirable solution. I think we should eventually move the anidb fetch logic to a separate endpoint. Meaning we can always load the page fast. But for now its good enough

p0psicles pushed a commit that referenced this pull request Sep 9, 2018
* Add `fetch` argument to `/series` API endpoint

Only fetch AniDB info when it is set to `True` (default is `False`)

* Update editShow to get AniDB data

* Update store/shows actions

* Lint JS

* Update changelog

# Conflicts:
#	CHANGELOG.md
#	themes/dark/assets/js/vendors.js
#	themes/light/assets/js/vendors.js
@sharkykh
Copy link
Contributor Author

sharkykh commented Sep 9, 2018

I think we should eventually move the anidb fetch logic to a separate endpoint.

Haha, you mean like home/fetch_releasegroups? 😉

@p0psicles
Copy link
Contributor

Haha. Yeah but preferebly restfull

@OmgImAlexis
Copy link
Collaborator

@p0psicles you seem to put RPC calls and REST into the same basket. Fetching would be an action. REST endpoint can have actions that run in the background and return data over another transport(websocket) or on the next GET.

If you want to just add RPC calls then do that but please don't mix them.

@p0psicles
Copy link
Contributor

I dont mix them. I said i prefer a restfull solution. Didnt say we should use 'fetch' restfull

@OmgImAlexis
Copy link
Collaborator

I know that but you're talking about moving an ACTION not a RESOURCE to an endpoint.

@p0psicles
Copy link
Contributor

p0psicles commented Sep 9, 2018

Okay sorry for the confusion. I like to not start adding rpc. And prefer to add a rest reaource that can be used the get releasegroups. Like /series/id/releasegroups/operation

@OmgImAlexis
Copy link
Collaborator

Oh okay so the fetch + cache results would be there not just the fetching?

@sharkykh sharkykh mentioned this pull request Feb 14, 2019
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants