Closed Krunal-Promact closed 7 years ago
both approach are complicated to implement and would not offer significant gains in terms of functionality. Simplest way is to just sync projects of the user who is registering. So, when user is authenticated we shall fetch projects associated with him only. similarly as and when more users authenticates we can fetch rest of the projects. While fetching the projects we may sometime fetch a project which is already there is our system in that case we just have to validate that only unique projects fetched every time are entered in our system.
After user authentication, identity server redirects a user to Dashboard action. So I can add code to sync projects that the authenticated user is assigned in Dashboard action. But it has one overhead that whenever a user lands on a Dashboard screen, project sync call to identity server will be done first.
It is not required to sync project every time user authenticates. Just sync project once only when user authenticates for the 1st time. later on provide an ability for user to manually sync project from his profile section.
Understood. Estimation Time to sync project on the first Authentication: 4 hours
There are a couple of ways we can sync data between two projects. 1) We can create one job scheduler that runs on every night which will sync data between two projects. 2) We can implement Webhook in OAuth Server.
Pros and Cons of Job Scheduler
Pros and Cons of Webhook