Authenticating Users Without Enterprise Manager in 6.0

Authenticating Users Without Enterprise Manager in 6.0

I just upgraded from Service Studio 5.1 to 6.0 (Which looks great by the way!). After it updated my eSpace, I got a ton of error messages related to the USER_MASTER entity. I did my research and learned about the changes to users and roles. So here's my question... Is it possible to convert the eSpace to the new login system instead of using Enterprise Manager 6.0? If so, how? If EM isn't going to be used in new applications anymore, I'd like to move past it instead of using it as a workaround.

The application I'm creating is pretty close to being done. Would it be better to just stick with 5.1 instead and use 6.0 for future applications? I'd prefer to use 6.0 since I'm sure I'll make changes to it in the future, but if it's easier just to stick with 5.1 for current ones then that is fine.

Also, I'm seriously a newbie, so please - do state the obvious! I won't be offended. Outside of the Agile Platform, I have absolutely no development experience. I'm a web designer, not developer - although that won't stop me from trying!
If this is your first application for this Platform Server, I would highly suggest to remodel to the new User environment. Legacy applications are a pain in the neck, so unless you have a deadline you can't make, go the new way.
Sticking with EM will mean you have two maintenance environments, which will be annoying if not confusing. I've been playing around with a 5.1 application in 6.0 and I do not like having to move back and forth between Users an EM at all.

That said, I would love to know if there is an automatic conversion method or if one is in the making.

This is a good read (short version: change User Provider in espace properties):

That's what I figured would be the best way, so I already started on a new one. Any suggestions for the fastest/easiest way to do that?

Note: What I'm about to say is almost entirely theory (meaning: I couldn't check most of it right now), so here goes...

If the salt string used in the Encrypt() function of earlier versions of the platform is the same in 6.0, you could easily migrate users from USER_MASTER to the Users table. You can check this by executing Encrypt("abc") in both 5.1 and 6.0 and matching the results, if they are the same you're good to go.
Create the records in the Users table, with the data from USER_MASTER. Notice that USER_MASTER has more attributes than Users, so you'll have to specify what matches what (with an assign, in case you're doing it with an Outsystems action instead of an INSERT query).

* I've noticed that with 5.1 (couldn't check previous versions) there's an entity called USER_RELATION that links USER_MASTER and Users, and that whenever a user logs into EnterpriseManager a User record is created for that user, as well as a USER_RELATION record. If you're using the same database, maybe you don't need to import users from one table to another, unless the newer platform uses a different instance of the Users table. If you're still using the same database, check if if the Users table has your Enterprise Manager data in it already.

This would be my aproach to the users problem.

But there's another problem... most applications use other tables from Enterprise Manager (like roles, permission_master, etc), and you could still import the data from the old ones to the new ones using a similar aproach, then replace all (old table)table usages from the newer versions, however, the data model might have changed in such a way, for some of those tables that a simple data migration won't do.
Example: The GROUPS table from EnterpriseManager references itself, allowing you to create and organize groups in a "tree" fashion. The newer GROUPS table doesn't reference itself, meaning you'd lose the hiearchy if you didn't create a second table... and creating a second table would probably mean A LOT of changes in the applications (if you relied heavily on the GROUPS structure before) .

Edit: Don't forget about removing all references to enterprise manager, meaning you'd lose stuff you're probably using like Login_GetUserMasterId(), and replacing all error handling from flows (that redirect to enterprise manager related pages)...

So I believe (again, I didn't check all that) there's no easy way out of this... Keeping Enterprise Manager seems like the way to go for servers with a lot of applications...
Wow that sounds like a lot to do... probably less than recreating the whole thing though. The application is still in development though, so there's no users yet, and therefore no users to migrate. Also, this is currently my only application. In the future, I'll have more, but as of right now it's the only one. That being said, I'd rather not use Enterprise Manager if I don't have to. Since there's no end users yet, I can do whatever I want to it without having to deal with existing data, so I'd like to use the best method possible from the start. If I have to recreate the whole thing from scratch to get the best result, then I will do that, but I was hoping there was a simpler option. :)
Hi Britni,

I do not yet know the details of the upgrade process at this point, but I believe the main point is to update your eSpace Common web flow that is in the 5.1 model (that implements the login process with the Enterprise Manager) to the Common web flow in 6.0 model (that implements the login process with the new Users app).

I will post some more details once I have them.


Daniel Lourenço
That makes sense. Plus remove any references within the other flows... I'll do that and see what I get.