I'm using the YouTube API. And this gem uses Net :: HTO as an adapter rather than directly using it. As you already know, take a remote request like this for at least a few seconds? Now that I do not have direct access to the Net :: HTTP library, how do I implement caching in my app? Here is a sample request to bring video from YouTube. You possibly can do this, the combination of queries and penguins To close You have little to do its work and more rest, but I have found that it is usually better because caching is a ton of bugs when you can lead to turn it on too early for me to write my own caching . Your code can: A quick question: Is there any reason that you have a client an instance variable? You probably are in control and it does not require this approach, so as a general principle, you should limit the scope to provide their views.
#othentikeshn $ @claint = Yutubat :: Outh2Clientkni (Claint_akses_tokn: "Akses_tokn" Claint_rifres_tokn: "Rifres_tokn" Claint_id: "Claint_id" Claint_sikret: "Claint_sikret" Dev_ke " Dev_key ", expires_at:" expiration time ") #Request @ video = @ client.videos_by (: query =>" .penguin ") video # = & gt; Video Returns array of "<">
No comments:
Post a Comment