Cache in Laravel | How to Create Cache in Laravel | How to Use Cache in Laravel

Поділитися
Вставка
  • Опубліковано 15 лип 2024
  • This video will show you how to use cache in Laravel. The cache is the act of transparently storing data for future use in an attempt to make applications run faster.
    Resouces
    - Github: github.com/codewithdary/larav...
    - Patreon: www.patreon.com/user?u=30307830
    - Instagram: / codewithdary
    - Twitter: / codewithdary
    - Cloudways Hosting: www.cloudways.com/en/?id=918573
    - Items I use: kit.co/codewithdary
    Get up to 1 Month Free Hosting by using code "DARY15" and get $15 free hosting credit.
    Cloudways offers peace of mind and flexibility so you can focus on growing your business and reaching new milestones instead of dealing with server management. With Cloudways, you get an optimized stack, managed servers, backups, staging environment, integrated Git, pre-configured, Composer, 24/7 support, and the choice of five cloud providers: AWS, DigitalOcean, Linode, Google Cloud, and Vultr.
    Coding Gear
    - MacBook Pro: amzn.to/3qTMnGi
    - Dell XPS: amzn.to/3Atp7Cm
    - LG 34WN650-W: amzn.to/3G0XMbS
    - Magic Trackpad 2: amzn.to/3Arp2ir
    - Magic Mouse 2: amzn.to/346k5zC
    - NAS: amzn.to/3rFf60U
    - Sandisk SSD: amzn.to/3fNHcBB
    - Rain Design Stand: amzn.to/3GTMeZ5
    Recording Gear
    - Rode NT-USB [Start]: amzn.to/3ApApXY
    - Shure SM7B [Advanced]: amzn.to/3Arj5lv
    - Rode PSA1: amzn.to/32pMCQ5
    - Focusrite Scarlett 2i2: amzn.to/3FYZD0t
    - XLR to XLR: amzn.to/3qVm2rC
    Timestamps
    00:00 Introduction
    01:52 Sponsor of today’s video: Cloudways
    02:29 Different cache drivers
    04:14 Available Cache Methods
    13:36 Caching database data
    ▬▬▬
    #cloudhosting #managedhosting #cloudways #laravel #laravelcache #cache

КОМЕНТАРІ • 60

  • @codewithdary
    @codewithdary  2 роки тому +1

    LETS CONNECT THROUGH INSTAGRAM.
    instagram.com/codewithdary

  • @mr_presley
    @mr_presley 2 роки тому

    Will watch at night after work...Thanks for uploading

  • @izk5578
    @izk5578 2 роки тому

    You are so smart lol, started html and css a few weeks ago and i can't see me doing that kind of stuff in prob 10 years xD

  • @noormohammadsiddiqui7737
    @noormohammadsiddiqui7737 2 роки тому +4

    That's great idea. I am gonna follow you for sure ❤️

  • @Venom-fq3hg
    @Venom-fq3hg 3 місяці тому +1

    thanks for great explanation😀

  • @isaacnewtonaranas3770
    @isaacnewtonaranas3770 2 роки тому +1

    I thank God that at last I know laravel for atleast 50% skilled at it. Im laravel frontend since 2017 and like what, wishing that someday will be able to be a backend here using laravel. Thanks Dary, you're updated contents really helps me and the way you teach these are pretty clear for a beginner like me. I wish this laravel dont upgrade to some what version 9 soon haha. so I'll be able to still learn in these series. I'm watching youtube videos to learn laravel cause I love it, but a lot of videos are boring and most of it are outdated. Yours is not, and is easy to learn. This is the first time that I'm confident in installing laravel and go make modules on it. That's all haha, really really BIG HELP! Stay safe and God bless you Dary and your family!

    • @codewithdary
      @codewithdary  2 роки тому +1

      Laravel will be updating in January to 9 haha :(. Thank you so much for your kind words Isaac, appreciate it a lot :)

    • @isaacnewtonaranas3770
      @isaacnewtonaranas3770 2 роки тому +1

      @@codewithdary Thank you Dary for informing about the version and for replying here haha. Lucky me being get noticed 😁😎 I know it's kinda scary for the new laravel version but I'll wait for new videos from you regarding laravel 9. Thank you so much!

  • @rezasiahcheshm
    @rezasiahcheshm 2 роки тому +1

    thank you for awesome video. ❤

  • @tahasamadi3730
    @tahasamadi3730 Рік тому +1

    i learned a lot of thing from you videos

    • @codewithdary
      @codewithdary  Рік тому +1

      I love to hear that Taha, keep it up :)

  • @soorajthekkepatt
    @soorajthekkepatt 2 роки тому

    You are a gem bro ❤️

  • @FHBStudio
    @FHBStudio 11 місяців тому +1

    Took me a while to get you meant "facade" when you said "vacate" lol.

    • @codewithdary
      @codewithdary  11 місяців тому

      LOL, I'm sorry

    • @FHBStudio
      @FHBStudio 11 місяців тому

      @@codewithdary It's fine 😉 Language isn't the topic of the video anyway, except maybe the programming language.

  • @dheeraj_kumar_1508
    @dheeraj_kumar_1508 Рік тому +1

    love the content

  • @yacobee
    @yacobee Рік тому +1

    Thank you.

  • @amrhussien2448
    @amrhussien2448 2 роки тому +2

    Thank you very much.. I have a question.. If there is a change in one of the records, what will happen ?

  • @busariibrahim8437
    @busariibrahim8437 2 роки тому +4

    Hey dary, can you please create a comprehensive project using laravel so as to understand laravel in depth

    • @codewithdary
      @codewithdary  2 роки тому +2

      I'm thinking about it bud! Not sure when though

  • @josephajibodu2377
    @josephajibodu2377 2 роки тому +1

    Valuable one. Thanks.
    I needed a quick introduction to cache when I started working with an API with rate limits. Thanks.
    Please how are you getting auto imports and suggestions on vscode for Laravel.

  • @syedjackson6931
    @syedjackson6931 Рік тому +1

    thanks man

  • @gt-nemachtillicomposer5478
    @gt-nemachtillicomposer5478 Рік тому +1

    Hello, very good video. What is the best practice? in the following scenario have three types of users where one is Admin, Editor and User.
    Apply cache in the controllers by minutes or by hours, it depends on the user.
    To avoid constant continuous requests to the database.

    • @codewithdary
      @codewithdary  Рік тому

      I don't really think storing that inside a cache is very useful, I would store it inside a session.

  • @devcaffeinated2248
    @devcaffeinated2248 2 роки тому +1

    Hello Dary, will you be having a tutorial on how to test cached data? please? 🙏🏼

  • @dimasbaguspm
    @dimasbaguspm 2 роки тому +2

    ❤️

  • @1337kaas
    @1337kaas 2 роки тому +1

    Memcached actually requires almost no config while redis can be configured in many ways (also as a persistent database)

  • @adorablebabiesandpets2514
    @adorablebabiesandpets2514 2 роки тому

    Hi Dary your videos are awesome....can you help with solid principles in laravel

  • @adil.bashir
    @adil.bashir Рік тому +1

    Hey Dary, hope you are doing well, thanks for the wonderful video. I am in need of Memcached to implement in laravel 8 on the windows operating system. I have tried multiple things but in the end, I am receiving the error class Memcached not found. Could you please help me out? It's very urgent. Nobody implemented Memcached in laravel 8 on windows till now, I have checked all the sources. Please have a look. Thanks in advanced

    • @codewithdary
      @codewithdary  Рік тому

      Hi Adil. I try to share all my experience through my videos. I can't help everyone 1 on 1 with their coding issues..

  • @lijinv674
    @lijinv674 2 роки тому

    ✌🏻

  • @-NguyenBuiAnhKhoa
    @-NguyenBuiAnhKhoa 3 місяці тому

    Can someone explain to me why he put a function inside the cache helper cache('post',function(){...})

  • @ulaskorpe
    @ulaskorpe Рік тому +1

    very good tutorial , but you should cut it into parts like cache-events- migrations

    • @codewithdary
      @codewithdary  Рік тому

      Thank you Ulas! You mean into separate videos or separate chapters?

    • @JacksonKon
      @JacksonKon Рік тому

      ​@@codewithdaryI would love to see chapter wise separation of deep dive cache

  • @hoaianle3940
    @hoaianle3940 Рік тому

    I feel like it slow compare to cache on Ram ( I try redis and it slow too).

  • @nipunsachinda
    @nipunsachinda 2 роки тому +1

    can you crate video how google calendar api in laravel 8 project

    • @codewithdary
      @codewithdary  2 роки тому +1

      Might definitely do it in the future!

  • @squattingnomad6298
    @squattingnomad6298 2 роки тому +1

    What is the difference between Cache::add and Cache::put?

    • @codewithdary
      @codewithdary  2 роки тому

      Functionality is identical, but the add method will not do anything if the item has already been cached.

  • @surajsuwal4703
    @surajsuwal4703 Рік тому

    why we need to remove cache even iy has not been set in listener?

    • @codewithdary
      @codewithdary  Рік тому

      Could you add the timestamp for me Suraj? I think that was just to show you that you could (not sure).

  • @sawyer303
    @sawyer303 2 роки тому +1

    Why is is blurry, yet 1080p@60?

    • @codewithdary
      @codewithdary  2 роки тому

      UA-cam settings :( I have it too when I watch some other YT videos. Super weird.

  • @AdilKhan-vf2es
    @AdilKhan-vf2es 2 роки тому

    Why did he put $dispatchedEvents in the Model? How can that be useful? Trying to see what he's doing with that.
    Great tutorial by the way