-
Hi,
During the migration of our instance from version 1.57.0 to version 1.59.1, we lost the
lastLoginInstantdata for almost all of our users.
After checking the database, we found that this data had been set tonullin theusertable.Is there a known bug logged regarding this issue?
Is there a procedure available to restore or reconcile the data?We have since upgraded to version 1.62.2. The data updates for users who log in again, but it remains missing for users who have not logged in.
Thank you in advance for your feedback.
-
D dan moved this topic from Q&A
-
D dan moved this topic from Frequently Asked Questions (FAQ)
-
Hiya @florent-bossuyt ,
Thanks for using FusionAuth.
The upgrade to 1.59.0 added support for phone number as a first class identity. While I don't know for sure, it is possible that impacted
lastLoginInstant. I'm not aware of any bug filed.It's also possible you can find the data previously in the
lastLoginInstantin theuser.identities[x].lastLoginInstantvalue, available when you retrieve a user.Since this is not a known issue, there's no documented procedure for reconciling the data, unfortunately.
Here's one approach, though.
If you have a database backup of the 1.57.0 release, you could stand up a FusionAuth instance pointing to that, and find all the users with a
lastLoginInstantthat is not null (set A). You'd then run the same query against your prod instance (set B). Then find the folks in set A who are not in set B (call them set C). Set C are the people you need to update.Unfortunately, you can't update their
lastLoginInstantdirectly. But you can fake a login using the passwordless APIs, which should set it. That is outlined here.So you'd want to perform that for all the users in set C.
Hope that helps.