We have a sharePoint 2010 instance and an application runing on top of the same. As this was open to only a few users, the userprofile was set up manually and there is no seprate sync happening between userProfile and AD.Application was working fine and then problems started.
We observed that the when ensureuser is present in code the user is getting added to the site, but the first name, last name and userName are not being populated for most of the users. For few of the users it is coming though. Some functionalities in
the application which are depending upon them are thus failing.
Request if anyone can help.