cancel
Showing results for 
Search instead for 
Did you mean: 

Accessing User information from J2EE engiine using UME API

Former Member
0 Kudos

Hi,

I am working on a monitoring application in which I want to retrieve user information from the J2EE Engine.

I am using UME API for the same.

I have written the following code -

1. IUserFactory userFactory= UMFactory.getUserFactory();

2. IUser myUser = userFactory.getUser(request.getUserPrincipal().getName());

but an exception occurs at line-1 saying -

com.sap.security.api.UMRuntimeException: UME factory 'com.sap.security.api.IUserFactory' cannot be accessed because UME initialization has not started yet. Please check UMFactory.isInitialized() before using UME functionality.

Can anyone help me on this on how to initialize the UMFactory or how to retrieve user info from the j2ee server.

Any help will be highly appreciated.

Thanks & Regards,

Sunny

Accepted Solutions (0)

Answers (3)

Answers (3)

siarhei_pisarenka3
Active Contributor
0 Kudos

Check also this: http://help.sap.com/javadocs/nw04s/current/se/com/sap/security/api/UMFactory.html

It seems you are trying to access UME from a standalone application. In this case it requires explicit initialization via method initialize(...).

BR, Sergei

Former Member
0 Kudos

Thanks Puneet for your reply.

Yes I have added all the required jars -

com.sap.security.api.jar

com.sap.security.api.perm.jar

I think before retrieving user info the UMFactory should be initialized.

I am not getting the procedure on how to initialize it.

Can anyone plz provide me the steps or procedure for initializing UMFactory.

Thanks in advance,

Sunny

Former Member
0 Kudos

Hi,

Check this below thread:

/message/3817280#3817280 [original link is broken]

Regards,

Charan

PuneetSaxena
Contributor
0 Kudos

Did you added all the jars in your workspace??