How to implement Redis in Spring Boot using Spring Data Redis & Jedis

Поділитися
Вставка
  • Опубліковано 20 січ 2025

КОМЕНТАРІ • 93

  • @DailyCodeBuffer
    @DailyCodeBuffer  4 роки тому

    Follow me on Twitter: twitter.com/DailyCodeBuffer

  • @bgoswami2730
    @bgoswami2730 10 місяців тому

    Best tutorial on Redis cache so far on the entire UA-cam channel

  • @utkarshdevgan6199
    @utkarshdevgan6199 3 роки тому

    you are simply awesome bro!, I have never seen such a good content creator yet in my entire life you are really good at it, keep it up Bro

    • @DailyCodeBuffer
      @DailyCodeBuffer  3 роки тому

      Thanks a lot for your kind words 🙂🙂. Means a lot to me 🙏🙏

  • @abduchadili5691
    @abduchadili5691 3 роки тому +4

    Great stuff here .
    Would be great if you can create a video on Springboot and Caching with Redis.
    Thanks

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

    I got really stuck with getting all the values from redis part. Turned out that flushall was the answer. Thank you.

  • @kayeshparvez
    @kayeshparvez 3 роки тому +3

    I want to use Redis and Mysql/Postgres at the same time where Redis will be used as an LRU cache. What should I do ?

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

    rt.setHashKeySerializer(new StringRedisSerializer());
    rt.setHashKeySerializer(new JdkSerializationRedisSerializer());
    why we set the properties two times ?

  • @aparnaagrawal8936
    @aparnaagrawal8936 4 роки тому +3

    Nice Explanation, You covered all operations in short time... awesome

  • @letsdebug450
    @letsdebug450 3 роки тому +2

    This man is a gem.

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

    Hi, your way of explanation is simply amazing.

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

    Why did you add @EneableCaching in the configuration? Where are we using caching here at all in the project? I can't understand the purpose of that here. Please help me understand its use case here

  • @ankurgoel09
    @ankurgoel09 3 роки тому +1

    Great Video, very well explained.

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

    One of the best video on redis
    Thank u so much for covering all scenarios 🙏

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

    19:46 Why am i getting this error "Error creating bean with name "jedisconnectionfactory" defined in class path resource ..
    Have anyone faced this issue ? Please help .

  • @rupeshtiwari4480
    @rupeshtiwari4480 3 роки тому +1

    Nice explanation ,I have one query over here How to club this with Mysql or Mongo database ,If key is not present in redis server , it should fetch from database ,Please make a video for it also

  • @turgenevslife9379
    @turgenevslife9379 5 місяців тому

    any ideas which pattern he used? it's impossible to understand to architecture

  • @sanketh768
    @sanketh768 3 роки тому +2

    in this project i think you used redis as a NOSQL database to store the data.
    Can we use it as a cache, using redistemplate?
    as far i know, w can use redis as a NOSQL DB, cache and message broker

    • @DailyCodeBuffer
      @DailyCodeBuffer  3 роки тому

      Yes

    • @sanketh768
      @sanketh768 3 роки тому +1

      @@DailyCodeBuffer can you make a video on this if possible?
      I mean to save java objects to redis cache?

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

    Hi, wanted to know that how can we add data to multiple db like redis and Mysql with use of single service

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

    how to see json stored in redis after save method thorugh redis cli???

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

    Nicely explained sir.
    It's so helpful...
    Kindly make springboot security tutorial.

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

      Thanks 🙏🏻
      Spring security is available on the channel

  • @RaviVerma-bg6ul
    @RaviVerma-bg6ul 3 роки тому

    good one, but how we deploy these things on production environment. like how to start redis on prod.

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

    Hi bro i have one doubt if i want data based on two param i.e loginuser and id which method of redis template i should use

  • @giftdzikiti1824
    @giftdzikiti1824 3 роки тому +1

    Thanks. Very useful

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

    could you explain how to configure jedispool?

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

    Hi @DailyCodebuffer, thanks for creating this video, it is very helpful, can you also create the video to store data in DB and then in cache and for 1st time fetching form DB and storing in cache then next time fetching should happen from cache, also I am facing class cast exception in getByID API can you please help in this.

  • @shivaadep8532
    @shivaadep8532 3 роки тому

    Bro I'm getting confused @cacheable n opsfoHash .. which one is better or do we use..?

  • @shashankbhat797
    @shashankbhat797 3 роки тому

    What about the database what we have already?

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

    Thanks for the video.
    Since we are fetching the value from Redis in cache when the value would be stored in real DB?

    • @salmasultana8155
      @salmasultana8155 7 місяців тому

      we will store in cache for frequent access. This will be small set of data. DB wise which is huge data remains intact

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

    Thanks a lot for this sir , I had to like , follow you on twitter and comment this comment 😂 , would you please let me know of the theme you are using ?

  • @ViniciusSousa-mx8uw
    @ViniciusSousa-mx8uw 3 роки тому

    Thank you SO MUCH!

  • @sergioddh
    @sergioddh 3 роки тому

    How can I find by firstName, for example?

  • @rajeevkalangi2472
    @rajeevkalangi2472 3 роки тому

    Bro.... But without all the config and all... Simply extending the CrudRepository is also working with Redis...

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

    You didn't start redis server. Is it not necessary?

  • @Hanumanji187
    @Hanumanji187 3 місяці тому

    Bro, if use radis, it can I install or not

  • @rahulkatlaparthi354
    @rahulkatlaparthi354 3 роки тому

    How can I implement auto generated id column in redis using spring boot

  • @FaisalKhan-iw6tw
    @FaisalKhan-iw6tw 3 роки тому

    What is the license of redis? Can I deploy this in production freely?

  • @unboxian6917
    @unboxian6917 3 роки тому

    How to set TTL in redis template...plz help

  • @arjunponti1483
    @arjunponti1483 3 роки тому

    Hii. After few requests get is not working. It is not showing any error but it is not invoking fingbyid method in serviceimpl

  • @Pranav-bt2dz
    @Pranav-bt2dz 4 роки тому

    How to manage connection pooling ?

  • @KrishnaKumarSahu-l4j
    @KrishnaKumarSahu-l4j Рік тому

    thanks for this video, when i connect this on my local redis its working fine but when i try to connect aws elasticache redis endpoint then i got connection issue like
    org.springframework.data.redis.RedisConnectionFailureException: Cannot get Jedis connection; nested exception is redis.clients.jedis.exceptions.JedisConnectionException: Could not get a resource from the pool
    at

  • @loftkey
    @loftkey 3 роки тому

    Why use opsforhash over opsforvalue?

  • @italoo190
    @italoo190 4 роки тому

    Tks sir, was very helpful

  • @ijaz2020
    @ijaz2020 4 роки тому

    what theme you are using in idea? looks nice.

    • @tomchandler2356
      @tomchandler2356 4 роки тому

      Did you find it?

    • @ijaz2020
      @ijaz2020 4 роки тому

      @@tomchandler2356 nope

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому

      If I find I will share, you guys also share if you find. Thanks

    • @tomchandler2356
      @tomchandler2356 4 роки тому

      The closest I could come across, is the Nord theme.

  • @RaghavSharma-nt3hr
    @RaghavSharma-nt3hr Рік тому

    Could you please create a tutorial on Spring Security and Session Management with Redis. And cover concepts like maxSessions and restrict logins after max sessions etc.

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

      This would be a great project tutorial.. the actual use case scenario. @DailyCodeBuffer

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

    how to connect redis with username and password ?

  • @curiouspragyan1938
    @curiouspragyan1938 3 роки тому

    How to implement redis connection pool logic

  • @loftkey
    @loftkey 4 роки тому

    Is there a way to do this without setting User to implement Serializable?

    • @loftkey
      @loftkey 3 роки тому

      I found a way by using gson to convert the object to a string.

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

    Good video lesson

  • @RahulRaoGonda
    @RahulRaoGonda 4 роки тому

    Hello sir...What’s exactly the use case of redis... meaning can you give me a real world example?

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому +1

      We can use Redis as a NoSQL Database. Mostly it is used as a distributed cache

    • @RahulRaoGonda
      @RahulRaoGonda 4 роки тому

      Daily Code Buffer thanks

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

      Yeah looks like some how he missed.
      But to answer it from my knowledge :
      Spring Redis - basically is a Remote Directory Server and its more popular as in-memory data structure tool.
      Its basically driven by key/store data structure to persist the data.
      You can use this Redis like a Database or a Cache or If you want you can also use like a Message Broker.

  • @Kidsfun1414-d5x
    @Kidsfun1414-d5x 4 роки тому

    Is redis support auto expired of data within 1 sec??

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому +1

      Yes, you can add the TTL value while storing the keys

  • @rabindrasahu3610
    @rabindrasahu3610 4 роки тому

    Thanks a lot Sir.

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому +1

      Happy to help. ❤

    • @rabindrasahu3610
      @rabindrasahu3610 4 роки тому +1

      @@DailyCodeBuffer sir can you share the update method code please.

    • @rabindrasahu3610
      @rabindrasahu3610 4 роки тому +1

      waiting for your response sir.(update method code in redis)

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому

      @@rabindrasahu3610 I have updated the code. You check checkthe updated repo.

    • @rabindrasahu3610
      @rabindrasahu3610 4 роки тому +1

      @@DailyCodeBuffer Thank you very much sir.

  • @tomchandler2356
    @tomchandler2356 4 роки тому

    Which theme is this?

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому

      I don't remember it. I will have to find it again and will share

    • @DailyCodeBuffer
      @DailyCodeBuffer  4 роки тому

      I have found this theme. It is "Visual Studio Code Dark Plus"

    • @tomchandler2356
      @tomchandler2356 4 роки тому

      @@DailyCodeBuffer Perfect! Thanks a lot, appreciate it. :)

  • @MountainMitch
    @MountainMitch 3 роки тому

    Great tutorial!
    When I tried to build this, an error occurred for this line
    JedisConnectionFactory jedisConnectionFactory = new JedisConnectionFactory(redisStandaloneConfiguration);
    Error:
    java: cannot access redis.clients.jedis.JedisShardInfo
    class file for redis.clients.jedis.JedisShardInfo not found.
    I googled and found 2 suggestions:
    1) Run the latest version of spring-boot-starter-parent
    2) Add an for lettuce to the POM
    Did both of these things but still get the errors.
    Do you have any ideas?

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

    Hello DCB
    I hope I can catch your attention
    Can you make Spring Caching it would be helpful
    Thank you so much

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

    only shabbir can make iron man learn backend xd

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

    Can all these records be accessed from redis-cli?