Code Monkey home page Code Monkey logo

Comments (6)

ryangribble avatar ryangribble commented on June 2, 2024 2

Here is another octokit.net discussion about my thoughts on implementing ETag/caching support.

octokit/octokit.net#1636 (comment)

From my perspective I prefer the idea of exposing the necessary information to consumers (eg a way for them to know what the ETag of a response was, and a way to provide that ETag or a timestamp on a call) and let them use them as they see fit, as opposed to "magic" internal workings that automatically cache responses and use ETags internally without the user knowing about it etc.

I also prefer the idea of returning a blank collection when the 304 response is received, rather than returning a cached response - again because I feel like octokit is an API wrapper and not an actual application layer itself

from discussions.

M-Zuber avatar M-Zuber commented on June 2, 2024 1

Not a maintainer but I found some links related to octokit.net that might be useful

from discussions.

kytrinyx avatar kytrinyx commented on June 2, 2024 1

šŸ’Æ to providing helper methods to make it easy to do pagination, caching, and handling rate limit responses, etc. I'd rather not do it transparently, for all the reasons @ryangribble mentions.

from discussions.

jsg2021 avatar jsg2021 commented on June 2, 2024

If you add transparent handling of caching, you should not preclude consumers opting out and handling it themselves... or provide a cache-provider plug-in api (so consumers can serialize/persist the cache in whatever form they want... be it memcache, json files, etc)

from discussions.

gr2m avatar gr2m commented on June 2, 2024

My current idea is to make an official plugin that people can use, but can replace with their own. But Iā€™m curious to hear what maintainers of octokit.net & octokit.rb have worked out

from discussions.

Disturbing avatar Disturbing commented on June 2, 2024

Would love to see this feature implemented! Exposing this in ApiOptions alone should be the way. Agreed that it should be an Api Wrapper, not an Application Layer.

Common features that sit on top of OctoKit.Net such as adding extension methods that cache this stuff in appointed repos is how I'd see this going.

from discussions.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    šŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. šŸ“ŠšŸ“ˆšŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ā¤ļø Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.