Guys, that's exactly what I mentioned. The response time may vary. For example, the first time I tried, it took over 2000 ms. However, after a restart, it took only 1029 ms on the second attempt. If you restart and retry again, the response time could exceed 2000 ms or drop below 1029 ms
If no explicit cache duration is configured in your cache provider, the cache entries will remain until they are evicted due to memory constraints, manual eviction, or application restart.
No what it does is , fetchSize controls how many rows the JDBC driver fetches in one go from the database cursor but doesn’t limit the total records returned by the query. For example, with fetchSize=50, the driver fetches rows in chunks of 50, optimizing memory usage for large datasets. However, all rows matching the query will still be returned unless explicitly limited using setMaxResults() or a LIMIT clause. For instance, if a query matches 1000 rows, they’ll be fetched in 20 chunks of 50 but all 1000 rows will be returned unless otherwise restricted.
Good Video as always♥, one doubt here. In video iu mentioned in the quertHint annotatios as fetch size is 50 right. after calling the api, did u get the records in 1lakh++ or only 50
No let me clear your doubts , fetchSize controls how many rows the JDBC driver fetches in one go from the database cursor but doesn’t limit the total records returned by the query. For example, with fetchSize=50, the driver fetches rows in chunks of 50, optimizing memory usage for large datasets. However, all rows matching the query will still be returned unless explicitly limited using setMaxResults() or a LIMIT clause. For instance, if a query matches 1000 rows, they’ll be fetched in 20 chunks of 50 but all 1000 rows will be returned unless otherwise restricted. Hope this make sense
Basat request you please answer this question Why introduced Java 8 static and default method in interface and abstract class already used it? Can you tell me real time example
Girish i have covered this video on my interview QA series please have a look once , after watching if you are unclear then please feel free to let me know
When we use Queryhint for saving query response to cache, if the data in database is always changing, how will it help ? Because the cache data will not be in sync if database data is changed right ?
When first time I ran it might took more than 2 sec that's why we get error. Second time it took only 1029 ms So the fact is that it will varry , for example if i will run 5 times in my local every time it won't give you the same result buddy
iterating one record at time hearder table 1 record Details table 3 records Under details child table 4 records 3 tables one-to-many relationship Please make eager and lazy loading I didn't understand others videos still confused when to use fetchType.Eager and Lazy. One interview asked didn't given proper example
Redis complete Playlist is there buddy just click on Playlist section of javatechie you will find everything . Do let me know incase still you are facing issues
Bro deserves 100M subscribers
I don't know the true buddy whether i could reach even 1M or not however This word is enough for me to boost 🥰
I think gold button from UA-cam ❤❤❤
Not 100M please, 1Billion. Your information are always relevant. Thank you for consistently delivering value. You are the best
Thank you Richa for your good wishes 🥰. Keep learning 😊
Interesting video for db performance
Bro these are premium stuff. I am surprised by the number of subscribers.
Amazing tutor on UA-cam..
1M subscribers soon 🎉
Thank you so much buddy for your kind words 😊. Keep learning 😊
Thanks sir for everything
Thank you brother. I love Java Techie!
I was also searching for the same. Thank you so much 🎉
Thanks for sharing 👍
Thanks for sharing
Thank you 🙏🏻
Thanks! 🙂
How long does the value stay in cache,also why did time out if time out was set to 2000, when the response 1029
I also have same question why did time out if time out was set to 2000, when the response 1029?
Guys, that's exactly what I mentioned. The response time may vary. For example, the first time I tried, it took over 2000 ms. However, after a restart, it took only 1029 ms on the second attempt. If you restart and retry again, the response time could exceed 2000 ms or drop below 1029 ms
If no explicit cache duration is configured in your cache provider, the cache entries will remain until they are evicted due to memory constraints, manual eviction, or application restart.
@@Javatechie Thanks Sir
thank you.
Thanks❤🙏
please explain about Optimistic vs. Pessimistic Locking in Spring Data and thank you for this video
Sure good suggestion 👍. Noted ✅️
Great 👍
Impressive
Could you please post a video on the jpa specification interface
hey the fetched size was 50 but it bought 196504 records how? and where was cache?
No what it does is , fetchSize controls how many rows the JDBC driver fetches in one go from the database cursor but doesn’t limit the total records returned by the query. For example, with fetchSize=50, the driver fetches rows in chunks of 50, optimizing memory usage for large datasets. However, all rows matching the query will still be returned unless explicitly limited using setMaxResults() or a LIMIT clause. For instance, if a query matches 1000 rows, they’ll be fetched in 20 chunks of 50 but all 1000 rows will be returned unless otherwise restricted.
Good Video as always♥, one doubt here. In video iu mentioned in the quertHint annotatios as fetch size is 50 right. after calling the api, did u get the records in 1lakh++ or only 50
No let me clear your doubts , fetchSize controls how many rows the JDBC driver fetches in one go from the database cursor but doesn’t limit the total records returned by the query. For example, with fetchSize=50, the driver fetches rows in chunks of 50, optimizing memory usage for large datasets. However, all rows matching the query will still be returned unless explicitly limited using setMaxResults() or a LIMIT clause. For instance, if a query matches 1000 rows, they’ll be fetched in 20 chunks of 50 but all 1000 rows will be returned unless otherwise restricted.
Hope this make sense
@ Thank you for detail explaination👌👌🙌
Basat request you please answer this question
Why introduced Java 8 static and default method in interface and abstract class already used it?
Can you tell me real time example
Girish i have covered this video on my interview QA series please have a look once , after watching if you are unclear then please feel free to let me know
When we use Queryhint for saving query response to cache, if the data in database is always changing, how will it help ? Because the cache data will not be in sync if database data is changed right ?
It will update once you try fetching the records . Not sure how it does will check and update buddy
Small doute if it taken 1029 but why it thorws exception 2000 limit time
When first time I ran it might took more than 2 sec that's why we get error. Second time it took only 1029 ms
So the fact is that it will varry , for example if i will run 5 times in my local every time it won't give you the same result buddy
Can you make a Spring Data JDBC video?
Simpler than JPA
Okay sure will do that
Can do make video of jpa save performance. In real time am facing 15sec to save into 3tables using oneTOMany relationship with Eager loading
Okay sure I will plan but can you elaborate your usecase what is the payload size you are persisting to DB is this in bulk or single nested payload ?
iterating one record at time
hearder table 1 record
Details table 3 records
Under details child table 4 records
3 tables one-to-many relationship
Please make eager and lazy loading I didn't understand others videos still confused when to use fetchType.Eager and Lazy. One interview asked didn't given proper example
@@girishrp9339 thanks for clear picture let me try to reproduce this exact scenario and will update you buddy
Timeout is not required right technically
Let it take the actual time as we optimised the method using queryhint know .
i couldn't find your design pattern playlist, can you please post that playlist link.
finally can i get rid of redis cache ?
Redis complete Playlist is there buddy just click on Playlist section of javatechie you will find everything . Do let me know incase still you are facing issues
🎉
Where's pagination implemented here, you got all records at once
FetchSize will load chunk of records on batch on the fly buddy. That's what the magic