Тёмный
No video :(

How Do I Work with Offline Data? 

IAmTimCorey
Подписаться 419 тыс.
Просмотров 8 тыс.
50% 1

Опубликовано:

 

5 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 29   
@jamesmussett
@jamesmussett Год назад
One approach that I've found useful for offline data is to use event-driven architecture so that each change made offline is stored as an event. Rather then sending the content of the underlying data (i.e.: records from a table), you simply send all of the event's that have occurred since the app was last online. Yes there can still be conflicts, but in my opinion they are much easier to manage.
@vbaclasses3553
@vbaclasses3553 Год назад
You have just peaked my interest into event-driven architecture. I've watch tons of Derek's from CodeOpinion videos, but for the first time I want to know more.
@jamesmussett
@jamesmussett Год назад
@@vbaclasses3553 derek’s videos are great. I’ve only had the chance to use event driven architecture once, and it definitely makes a difference if you know what your doing. Especially in scenarios like this.
@IAmTimCorey
@IAmTimCorey Год назад
That gives you a better picture of the order of things, which does help with some issues, but it doesn’t really address data conflicts, which is the biggest issue.
@jamesmussett
@jamesmussett Год назад
@@IAmTimCorey I completely agree, conflicts are always challenging. However, with the above approach you don’t have to worry about conflicts like primary keys in tables when you are inserting data, just as an example.
@sirus49
@sirus49 Год назад
​​@@jamesmussett u just use guids and won't be an issue
@Norman_Fleming
@Norman_Fleming Год назад
Regarding comments that Tim is not providing a solution. The solution is specific to your business and what the user requirements are. One scenario not mentioned is not just that you have 2 changes from 2 locations, but that the changes are logically inconsistent. If user 1 changed the city to match the state, and user 2 changed the state to match the city. Each independent change is valid, but cannot be merged properly. This is where we earn our pay. Providing options to the business team and then making those options a reality.
@IAmTimCorey
@IAmTimCorey Год назад
Thanks for sharing. Excellent points.
@kostasgkoutis8534
@kostasgkoutis8534 Год назад
Thanks Tim, that was a really helpful nugget of architectural reasoning. We need more of this 😅. I myself have never sofar come across to some similar requirement to this (consolidating delayed and possibly incompatible conflicts, effectively reconstructing the past), and I am glad I came across your video early.
@IAmTimCorey
@IAmTimCorey Год назад
I am glad it was helpful.
@jalemanyr
@jalemanyr 11 месяцев назад
Hello Tim, First thank you for your great videos. I have watched too many already. I want to build a WPF with offline database synchronization Level 4. maybe level 5, not sure yet. Can you point me in some direction on what library to use? or samples? I dont mind to use Azure or google, etc. I have seen too many different options but I would like to use one where the trend is going to guarantee a long term support. Thank you.
@vbaclasses3553
@vbaclasses3553 Год назад
Really enjoyed the video. Lots of food for thought and guidelines of how to approach these challenges. Thank you.
@IAmTimCorey
@IAmTimCorey Год назад
Glad it was helpful!
@sirus49
@sirus49 Год назад
Years ago with a desktop application we built. We used sql server and localdb. We used dacpacs to check for db schema changes to update the localdb. Anyways when they created offline data and needed to sync back to the main server we used syncframework and totally customized it. We also used guids and had logic of what to "take" if there is conflicts from the server or client. It got pretty complicated to where eventually we built our own custom sync. Curious do you recommend a certain framework for syncing and then customizing it? Again I know it all depends on what you are doing. Just wondering if you have used any sync frameworks yourself or just built your own.
@IAmTimCorey
@IAmTimCorey Год назад
There are frameworks out there, and I mentioned a few technologies in this video, but at the end of the day they all take customization based upon your specific circumstances. I've found that even inside your specific scenario, you end up having different rules for different data.
@chrisjohansson9971
@chrisjohansson9971 Год назад
@@IAmTimCorey You mentioned sqllite and pouchdb. but just curious which ones you liked working with personally and have used for any given project. Do you usually build your own... i know it all depends, just wondering what you have worked with and liked
@valadares462
@valadares462 Год назад
Tim I've been following you for years and this was the first video of yours that I didn't like. you talked about a common problem for all developers, but you didn't give any solutions. only brought questions and no answers.
@IAmTimCorey
@IAmTimCorey Год назад
This is because I took you as far as I could. Each situation is specific and needs to be handled that way. There are high level concepts that we can talk about (this video), but I can’t say “do this”. Even for your specific situation, you will need to do things differently for different parts of your data. Offline data is HARD.
@waitingforyou2082
@waitingforyou2082 Год назад
You explained the different situations but you didn't actually give us any techniques that we can you to resolve those situations 🤔
@IAmTimCorey
@IAmTimCorey Год назад
I got you as close as I could. Even for your specific situation, you will probably mix and match these solutions. Offline data is either simplistic (read-only) or it is a custom solution for a given situation. Anyone that says “just do this” is incorrect and giving bad advice. Offline data that isn’t just read-only is HARD!
@waitingforyou2082
@waitingforyou2082 Год назад
@@IAmTimCorey Thanks Tim for all your efforts we really appreciate it.
@kandycan
@kandycan Год назад
You use one drive and all of the rest. C'mon man, say it. Say it that it's Google drive 😂 🥴😜
@IAmTimCorey
@IAmTimCorey Год назад
I actively avoid Google drive. Google has burned me too many times with cool tech that they've dropped.
@kandycan
@kandycan Год назад
@@IAmTimCorey 😆🤣
Далее
When Should I Quit? How Do I Know When to Move On?
18:21
Power Apps Dataverse Offline
19:24
Просмотров 6 тыс.
when you have plan B 😂
00:11
Просмотров 3,1 млн
A Minecraft Movie | Teaser
01:20
Просмотров 16 млн
How Do I Document My Code?
20:17
Просмотров 21 тыс.
Intro To Service Workers & Caching
35:26
Просмотров 234 тыс.
I've been using Redis wrong this whole time...
20:53
Просмотров 356 тыс.
Generating Fake Data in C# with Bogus
36:11
Просмотров 22 тыс.
What Was Your Biggest Mistake in Software Development?
19:24
Syncing SQLite and Postgres?
24:14
Просмотров 9 тыс.
Why I Stopped using Service Workers
11:44
Просмотров 89 тыс.
when you have plan B 😂
00:11
Просмотров 3,1 млн