Role Updation-FDI api

Hi all,
i am trying to update the existing role through Java FDI api(albpmfdi.jar) .I use FuegoFDIAdmin.admin.addRolesToUser(soeId, roles, fuegoParameter, 95) to addroles to user.I dont find any similar utilities to update the existing role.I want to update the permission alone in the existing role.
DirHumanParticipant.getRolesAssignment() returns a string array which comprises of permission value.But it is a final variable so no new assignment could not be made.
I tried FuegoFDIAdmin.admin.addRolesToUser(soeId, roles[i], fuegoParameter, 255) again to see if that updates the existing role.But that throws exception since role already exists.
can anybody find a way out and can explain me what DirHumanParticipant.addpermission(int) will do .I tried this also but it doesnt have any impact.What is a user permission and permission added to a person with role ,How these both various.I will be grateful if somebody explains the user permission since i know what the later is meant for("XSARFGP")
Thanks,
Madhanagopal Kumar

Rubén,
Thanks for ur timely reply.But i couldnt replicate the same stuff whatever u did in ALBPM with the FDI Java api's or papi.My code look like this.
We tried the insert and other stuffs which u proposed(see the commented lines below),But unfortunately those utilities are not available in any of the jars like fuegofdi.jar,fuego-papi client.jar ect.can u please help in finding the exact jar where all such stuffs are available to update the permission alone in the existing role and its implementation if possible.Once again my overwhelming thanks for the post.
admin = new FuegoFDIAdmin();
               admin.createFdiSession(adminUser, adminPassword, directoryFile,     directoryID);
DirHumanParticipant usrDetails = null;
DirectorySession dirSession=admin.getFdiSession().getDirectorySession();
                    usrDetails=DirHumanParticipant.fetch(dirSession, soeId);
                    DirHumanParticipant.RoleAssignment []definedRoles = usrDetails.getRolesAssignment();
                    LOG.debug("No. of pre-defined roles [currently assigned] to the user ["+soeId+"] ="+ usrDetails.getRolesAssignment().length);
                    LOG.debug("Fuego parameter "+fuegoParameter);
                    LOG.debug("Fuego business parameter "+businessParameter);
                    for (int i = 0; i < roles.length; i++) {                 
                         roleFound = false;
                         for (int k=0;k<definedRoles.length;k++) {
                              if((definedRoles[k].role).equals(roles)){
                                   try {          
                                        if(isParametric(roles[i])){
                                             LOG.debug("The role "+roles[i]+" is parametric");                                                                                
                                             if (null!=fuegoParameter && usrDetails.hasRoleAssigned(roles[i], fuegoParameter)){
                                                  roleFound = true;
                                                  break;
                                             }else{
                                                  roleFound = false;
                                                  break;
                                        }else{
                                             LOG.debug("The role "+roles[i]+" is not parametric");
                                             int category=5;
                                             *if(usrDetails.hasRoleAssigned(roles[i])){*
*//                                                  fuego.papi.Participant.RoleAssignment roleass=new fuego.papi.Participant.RoleAssignment(roles[i],category,"XRSADE");*
*//                                                  DirOrganizationalRole dRole=DirOrganizationalRole.fetch(dirSession, definedRoles[k].role);*
                                                  //definedRolesnew[k].insert(definedRoles.length, roleass);
                                                  dirSession.startTransaction();
                                                  RoleAssignmentImpl rImpl=new RoleAssignmentImpl(definedRoles[k]);
                                                  rImpl.addPermissions(255);
                                                  System.out.println("Two ::"+dirSession.isTransactionStarted());
                                                  usrDetails.update();
                                                  dirSession.commitTransaction();
                                                  roleFound = true;
                                                  break;
                                             }else{
                                                  roleFound = false;
                                                  break;
                                   }catch(Exception ex){
                                        LOG.debug("Exception while looking up for the role (Skipping role addition/verification of role) "+roles[i]);     
                                   //roleFound = true;
                                   //break;           
                         try {                                 
                              if (!roleFound){
                                   LOG.debug("Updating user role "+roles[i]);
                                   admin.addRolesToUser(soeId, roles[i], fuegoParameter, permission);           
                         }catch(Exception fnd){
                              LOG.debug("Role already exists:- "+fnd.getMessage());
                              fnd=null;

Similar Messages

  • Error in oim Role creation using Role Manager Service API from Standalone Java client

    Hi,
      Facing the following error when trying to create Role using Role Manager Service API from a standalone java client .
    Tried with the solution of changing ,
    Login into the Web Logic Admin Console --> Servers --> OIM Server --> Protocols --> Modify the Maximum Message from 100000000 to 1000000000, but still the problem persists.
    Exception in thread "main" org.omg.CORBA.BAD_PARAM:   vmcid: 0x0  minor code: 0  completed: No
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
    at java.lang.reflect.Constructor.newInstance(Unknown Source)
    at java.lang.Class.newInstance0(Unknown Source)
    at java.lang.Class.newInstance(Unknown Source)
    at com.sun.corba.se.impl.protocol.giopmsgheaders.MessageBase.getSystemException(Unknown Source)
    at com.sun.corba.se.impl.protocol.giopmsgheaders.ReplyMessage_1_2.getSystemException(Unknown Source)
    at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.getSystemExceptionReply(Unknown Source)
    at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.processResponse(Unknown Source)
    at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.marshalingComplete(Unknown Source)
    at com.sun.corba.se.impl.protocol.CorbaClientDelegateImpl.invoke(Unknown Source)
    at org.omg.CORBA.portable.ObjectImpl._invoke(Unknown Source)
    at com.sun.org.omg.SendingContext._CodeBaseStub.meta(Unknown Source)
    at com.sun.corba.se.impl.encoding.CachedCodeBase.meta(Unknown Source)
    at com.sun.corba.se.impl.io.IIOPInputStream.getOrderedDescriptions(Unknown Source)
    at com.sun.corba.se.impl.io.IIOPInputStream.inputObjectUsingFVD(Unknown Source)
    at com.sun.corba.se.impl.io.IIOPInputStream.simpleReadObject(Unknown Source)
    at com.sun.corba.se.impl.io.ValueHandlerImpl.readValueInternal(Unknown Source)
    at com.sun.corba.se.impl.io.ValueHandlerImpl.readValue(Unknown Source)
    at com.sun.corba.se.impl.encoding.CDRInputStream_1_0.read_value(Unknown Source)
    at com.sun.corba.se.impl.encoding.CDRInputStream.read_value(Unknown Source)
    at oracle.iam.identity.rolemgmt.api._RoleManager_ogut7n_RoleManagerRemoteRIntf_Stub.createx(Unknown Source)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:85)
    at $Proxy2.createx(Unknown Source)
    at oracle.iam.identity.rolemgmt.api.RoleManagerDelegate.create(Unknown Source)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at Thor.API.Base.SecurityInvocationHandler$1.run(SecurityInvocationHandler.java:68)
    at weblogic.security.subject.SubjectProxy.doAs(SubjectProxy.java:64)
    at weblogic.security.subject.SubjectManager.runAs(SubjectManager.java:262)
    at weblogic.security.Security.runAs(Security.java:48)
    at Thor.API.Security.LoginHandler.weblogicLoginSession.runAs(weblogicLoginSession.java:52)
    at Thor.API.Base.SecurityInvocationHandler.invoke(SecurityInvocationHandler.java:79)
    at $Proxy3.create(Unknown Source)
    at com.idm.role.CreateRole.createRole(CreateRole.java:113)
    at com.idm.role.CreateRole.main(CreateRole.java:167)
    Thanks In Advance

    Hi , I have used OIM 11g  R2.
    Please find below the code we have used,
    package com.idm.role;
    import java.util.HashMap;
    import java.util.HashSet;
    import java.util.Hashtable;
    import java.util.Iterator;
    import java.util.Set;
    import java.util.logging.Logger;
    import javax.security.auth.login.LoginException;
    import oracle.iam.identity.exception.NoSuchRoleException;
    import oracle.iam.identity.exception.RoleAlreadyExistsException;
    import oracle.iam.identity.exception.RoleCreateException;
    import oracle.iam.identity.exception.RoleLookupException;
    import oracle.iam.identity.exception.RoleModifyException;
    import oracle.iam.identity.exception.SearchKeyNotUniqueException;
    import oracle.iam.identity.exception.ValidationFailedException;
    import oracle.iam.identity.rolemgmt.api.RoleManager;
    import oracle.iam.identity.rolemgmt.api.RoleManagerConstants;
    import oracle.iam.identity.rolemgmt.vo.Role;
    import oracle.iam.platform.OIMClient;
    import oracle.iam.platform.authz.exception.AccessDeniedException;
    public class CreateRole {
    private final static Logger LOGGER = Logger.getLogger(CreateRole.class .getName());
    OIMClient oimClient = null;
    public OIMClient connectToOIM() {
      LOGGER.info("In connectToOIM ");
      Hashtable env = new Hashtable();
      env.put(OIMClient.JAVA_NAMING_FACTORY_INITIAL,
        "weblogic.jndi.WLInitialContextFactory");
      env.put(OIMClient.JAVA_NAMING_PROVIDER_URL,
        "t3://V-hydidm1.itig.co.in:14000");
      System.setProperty("java.security.auth.login.config",
        "F:\\Projects\\IDM\\Team\\Env_setup\\OIM_Setup\\designconsole\\config\\authwl.conf");
      System.setProperty("java.security.policy",
        "F:\\Projects\\IDM\\Team\\Env_setup\\OIM_Setup\\designconsole\\config\\xl.policy");
      System.setProperty("OIM.AppServerType", "wls");
      System.setProperty("APPSERVER_TYPE", "wls");
      System.setProperty("weblogic.Name", "oim_server1");
      oimClient = new OIMClient(env);
      try {
       oimClient.login("xelsysadm", "Passw0rd".toCharArray());
      } catch (LoginException e) {
       e.printStackTrace();
      System.out.println("Connected");
      return oimClient;
    public void readRoleMetadata() {
      LOGGER.info("in readRoleMetadata ");
      RoleManager roleManagerService = oimClient
        .getService(RoleManager.class);
      try {
       Role roleVo = roleManagerService.getDetails(
         RoleManagerConstants.ROLE_DISPLAY_NAME, "API Role1", null);
       Set attributeNameSet = roleVo.getAttributeNames();
       Iterator it = attributeNameSet.iterator();
       while (it.hasNext()) {
        System.out.println("Attribute Name :: " + it.next());
       // roleVo.setAttribute("ADentitlements", "Security Admin access");
       String adEntitlements = "" + roleVo.getAttribute("ADentitlements");
       System.out.println("AD Entitlements :: " + adEntitlements);
       System.out.println("DB Entitlements :: " + ""
         + roleVo.getAttribute("DBEntitlements"));
       System.out.println("Unix Entitlements :: " + ""
         + roleVo.getAttribute("UnixWindows"));
       System.out.println("VPN :: " + "" + roleVo.getAttribute("VPN"));
      } catch (SearchKeyNotUniqueException e) {
       e.printStackTrace();
      } catch (NoSuchRoleException e) {
       e.printStackTrace();
      } catch (RoleLookupException e) {
       e.printStackTrace();
      } catch (AccessDeniedException e) {
       e.printStackTrace();
    public void createRole() {
      LOGGER.info(" in Create role ");
      RoleManager roleManagerService = oimClient
        .getService(RoleManager.class);
      HashMap<String, Object> roleCreationAttrMap = new HashMap<String, Object>();
      roleCreationAttrMap.put(RoleManagerConstants.ROLE_NAME, "API Role1");
      roleCreationAttrMap.put(RoleManagerConstants.ROLE_DESCRIPTION,
        "This Role is created using API Role1");
      roleCreationAttrMap.put(RoleManagerConstants.ROLE_DISPLAY_NAME,
        "API Role1");
      roleCreationAttrMap.put("ADentitlements", "API Role1 AD Entitlements");
      roleCreationAttrMap.put("DBEntitlements", "API Role1 DB Entitlements");
      roleCreationAttrMap.put("VPN", "No");
      roleCreationAttrMap.put("UnixWindows", "API Role1 Unix Entitlements");
      Role roleVo = new Role(roleCreationAttrMap);
      try {
       System.out.println(" Before Create role *********************************************");
       roleManagerService.create(roleVo);
       System.out.println("Role Created .. ");
      } catch (ValidationFailedException e) {
       e.printStackTrace();
      } catch (RoleAlreadyExistsException e) {
       e.printStackTrace();
      } catch (RoleCreateException e) {
       e.printStackTrace();
      } catch (AccessDeniedException e) {
       e.printStackTrace();
    public void modifyRole() {
      LOGGER.info(" in modifyRole ");
      RoleManager roleManagerService = oimClient
        .getService(RoleManager.class);
      Role roleVo;
      try {
       roleVo = roleManagerService.getDetails(
         RoleManagerConstants.ROLE_DISPLAY_NAME, "API Role1", null);
       String roleKey = roleVo.getEntityId();
       HashMap<String, Object> roleCreationAttrMap = new HashMap<String, Object>();
       roleCreationAttrMap.put("ADentitlements",
         "Updated API Role1 AD Entitlements");
       Set roleKeySet = new HashSet<String>();
       roleKeySet.add(roleKey);
       Role roleVoNew = new Role(roleCreationAttrMap);
       roleManagerService.modify(roleKeySet, roleVoNew);
       System.out.println("Role Modified ..");
      } catch (SearchKeyNotUniqueException e) {
       e.printStackTrace();
      } catch (NoSuchRoleException e) {
       e.printStackTrace();
      } catch (RoleLookupException e) {
       e.printStackTrace();
      } catch (AccessDeniedException e) {
       e.printStackTrace();
      } catch (ValidationFailedException e) {
       e.printStackTrace();
      } catch (RoleModifyException e) {
       e.printStackTrace();
    public static void main(String args[]) {
      CreateRole miscObj = new CreateRole();
      miscObj.connectToOIM();
      miscObj.createRole();
      //miscObj.readRoleMetadata();
    Thanks In Advance .

  • Is anyone aware of an updated reporting API for the ESA/WSA?

    I'm looking to build a dashboard website and the pre-Cisco API tools don't seem to work on any of the current platforms. 
    https://supportforums.cisco.com/document/33721/cisco-ironport-systems-contributed-tools
    I know they worked for a while after the merger, but I didn't notice when they stopped working.

    Hi
    Could you please let us know your plan for the release of updated Reporting API tools and Log based reporting tools.  
    Also let us know the new forums to which you have migrated.
    We are also looking to interact with the WSA device and fetch the logs or CSVs for our customized systems

  • 11g R2: Role creation using API

    I am trying to create a role using OIM API RoleManager
                RoleManager roleService = oimClient.getService(RoleManager.class);    
                Role roleObj = new oracle.iam.identity.rolemgmt.vo.Role("");
                roleObj.setAttribute("Role Name","SampleTestRole");
                roleObj.setAttribute("Role Display Name","Sample Test Role");
                roleObj.setAttribute("Role Description","Sample Test Role");
                System.out.print(roleService.create(roleObj));
                System.out.print("Role has been created.... ");
    I am getting the following exception:
    oracle.iam.identity.exception.RoleCreateException: Orchestration process with id 14915, failed with error message null.
      at weblogic.rjvm.ResponseImpl.unmarshalReturn(ResponseImpl.java:237)
      at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:348)
      at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:259)
      at oracle.iam.identity.rolemgmt.api.RoleManager_ogut7n_RoleManagerRemoteImpl_1036_WLStub.createx(Unknown Source)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:85)
      at $Proxy2.createx(Unknown Source)
      at oracle.iam.identity.rolemgmt.api.RoleManagerDelegate.create(Unknown Source)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at Thor.API.Base.SecurityInvocationHandler$1.run(SecurityInvocationHandler.java:68)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
      at weblogic.security.Security.runAs(Security.java:41)
      at Thor.API.Security.LoginHandler.weblogicLoginSession.runAs(weblogicLoginSession.java:52)
      at Thor.API.Base.SecurityInvocationHandler.invoke(SecurityInvocationHandler.java:79)

    Tried as suggested in the link posted but still getting the same exception.
            Role managerRole=new Role("powerUser");
            managerRole.setName("powerUser");
            managerRole.setDisplayName("powerUser");
    oracle.iam.identity.exception.RoleCreateException: Orchestration process with id 14930, failed with error message null.
      at weblogic.rjvm.ResponseImpl.unmarshalReturn(ResponseImpl.java:237)
      at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:348)
      at weblogic.rmi.cluster.ClusterableRemoteRef.invoke(ClusterableRemoteRef.java:259)
      at oracle.iam.identity.rolemgmt.api.RoleManager_ogut7n_RoleManagerRemoteImpl_1036_WLStub.createx(Unknown Source)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:85)
      at $Proxy4.createx(Unknown Source)
      at oracle.iam.identity.rolemgmt.api.RoleManagerDelegate.create(Unknown Source)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at Thor.API.Base.SecurityInvocationHandler$1.run(SecurityInvocationHandler.java:68)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
      at weblogic.security.Security.runAs(Security.java:41)
      at Thor.API.Security.LoginHandler.weblogicLoginSession.runAs(weblogicLoginSession.java:52)
      at Thor.API.Base.SecurityInvocationHandler.invoke(SecurityInvocationHandler.java:79)
      at $Proxy5.create(Unknown Source)

  • Schedule role update automatically

    Hi ,
    I did what it says in note 1406037 to schedule role update automatically but my jobs are staying in pending status? Anyone got any ideas why this is happening?
    details of note below:
    In the CMC, go to Folders and create new folder "Objects"
    Select the folder "Objects" and click on Manage | Add | Program File
    Choose as Program Type Java and add SAPUpdate.jar
    Right Click on SAPUpdate within your Objects folder and choose Properties | Default Settings | Program Parameters
    Specify as "Class to run:" sapupdate.Main
    Test "Run Now" and schedule the Program Object
    I can manually update roles as expected. I am using XI 3.1 SP3 and SAP BW 7.0.
    Thanks,
    Leo
    Edited by: Leo on Oct 7, 2010 3:43 PM

    https://www.google.com/#newwindow=1&q=trigger+windows+update+command+line
    Try using the search engine for non scripting questions.
    ¯\_(ツ)_/¯

  • How can I get roles by BEA API

    I use some bea api and create one role name is "test",I add one user and one group in it.
    but I input resourceId is "test",no results display,whether I use wrong?please tell me how can I get roles by bea api
    some code ,for example
    public RoleProviderDescription getRoleDefaultProvider() throws ProviderMgmtException
              RoleProviderDescription roleProviderDescription = RoleSecurityMgmtHelper.getDefaultProvider();
              return roleProviderDescription;
    public RoleManagerProxy getRoleManagerProxy()
              RoleManagerProxy roleManagerProxy = new RoleManagerProxy(getRoleDefaultProvider());
              return roleManagerProxy;
    public List<String> getRoles(String resourceId)
              String[] roles = getRoleManagerProxy().listRolesForResource(resourceId);
              List<String> list = new ArrayList<String>(roles.length);
              for(int i=0; i<roles.length; i++)
                   list.add(i, roles);
              return list;

    *{color:#0000ff}Alternatively you can try this one too:{color}*
    public static Object[][] listRolesForResource(int aResourceScope,String anEntAppName,String aWebAppName,String aResourceId)
    {color:#800000}
    Other than this if you are trying to access the roles within a portal context there is a control called DelegatedRolePolicyManagerControlFacade (com.bea.portal.tools.entitlements.controls.DelegatedRolePolicyManagerControlFacade) which can give you all the roles:
    Here is the sample code (within a pageflow action):
    @Control
    private DelegatedRolePolicyManagerControlFacade rolePolicyManagerCtrl;
    ResourceContext context = ResourceContext.createResourceContext(request, false);
    SortablePagedResult&lt;String&gt; result = rolePolicyManagerCtrl.getScopedRoles(null, null, null, false, -1, context);{color}
    Edited by: user5833069 on Jan 7, 2009 10:08 AM
    Edited by: user5833069 on Jan 7, 2009 11:38 AM

  • Cloud Service roles update issues

    Hi Team,
    we deployed a cloud service in EMEA windows azure (North Ireland).
    There are worker roles and web roles in the cloud service , it's strange that when we update the web role the worker roles are rebooted at the same time.
    we thought that the worker role update should not affect other roles , please advice,
    thanks in advance.

    Thanks Nagamalar for
    the reply,
    add some comments here.
    These roles, are they hosted from Azure Management portal or Visual Studio?
    [comment] The roles are all hosted  from Azure Management portal.
    What is the update you are performing, is it a Configuration file or a Package file?
    [comment] We are performing to update package.
    Or when you apply the updates do you choose all instances or a particular instance for the update? (In case
    of an instance created in Azure Management Portal)
    [comment]We are choosing a particular role to update. we have both web role and worker role in a cloud service. but we just update the web role at that moment.
    one more question:
    when we update a specific role, the step are the following:
    1. download the configuration file
    2. choose the specific roles to update and upload package and the configuration file
    3. check the two options under roles
    4. click OK button to update the cloud service.
    in this case, will the configuration files will be treated as a new one or old one.
    Thanks in advance.

  • Assigning users to role using Security API

    Hi,
    I am trying to assign portal users to portal role using the IRoleFactory and IRole class of Secutiy API from my web dynpro application.
    For getting the role , i can use either the uniqueId of the role or the uniqueName of the role.(Using methods of IRole class, getRole(uid) or getRoleByUniqueName(uname)).
    The UniqueId of roles contains some hash values and cannot be used. For example ROLE.PCD_ROLE_PERSISTENCE.6dT95vZpyNWQHm59z7B9FxAM/fg=.
    And the for getting the role using the uniqueName, i need to give like pcd:portal_content/other_vendors/<folder name>/<my prefix>.<rolename>. Which is also not feasible.
    Is there any way to get the role only using the role name that we give while creating it?
    Thanks and Regards,
    Venkat

    Hi,
         Check if this helps.
    try  {
         IRoleFactory rfact = UMFactory.getRoleFactory();
         IRoleSearchFilter isf = rfact.getRoleSearchFilter();
         isf.setDisplayName ("*",ISearchAttribute.LIKE_OPERATOR,false);
         ISearchResult rit = rfact.searchRoles(isf);
         while(rit.next()!=null){
             String roleName = (String) rit.next();
             IRole role = rfact.getRole(roleName);
             response.write("nRole:" + role.getUniqueName());
      }catch(Exception e){
           response.write("exception");
    U will get list of roles. U can pass these directly or use String tokenizer to separate the role name alone using '.' as separator.
    Regards,
    Vijai

  • Role updation during Flat File Active Sync

    Hi
    I have defined a role which assigns default values to some attributes for a particular resource.
    And this role am assigning it to the user in the Flat File Active Sync form during user creation.
    But the problem is the attribute-values defined in the Role are not getting updated in the user data during the creation process. The next time there is an update, the values get reflected.
    I want this to be reflected during the first creation process itself. Please let me know what changes needs to be done in the following code -
    <Field name='accounts[Lighthouse].roles'>
    <Expansion>
    <filterdup>
    <appendAll>
         <ref>accounts[Lighthouse].roles</ref>
    <s>Initial-Provision-Role</s>
    </appendAll>
    </filterdup>
    </Expansion>
    </Field>
    This is done after assigning the user to the resources.
    Please help asap
    Thanks
    Bushra

    no....what i mean is that instead of using the user forms to set all the values, call a workflow instead. I believe the field in the configuration is called "process workflow" or something like that. this will be called instead of the forms. inside that workflow create a view, or get the existing view...set the new role....refresh the view...then call the create/update/delete user etc.
    a create view is s provisioning task...so you cant call it from a workflow. take the "provisioning task" part out of the header of the create user workflow and it should work just fine.
    this may be much more complicated than what you actually need. Its just the way i would handle it. I dont like using the user forms and always call a workflow instead. gives me much more flexibility
    dana

  • Product updates via API cause release date to be changed

    When running product updates via the eCommerce API (Product_UpdateInsert) the release dates for the updated products are being set to 02-Jan-2000. Is this happening for anyone else?
    This is kind of painful as we have a client who uses the product release dates throughout their site...

    Ran into the same issue. I was using the release date to flag latest products, regardless of ordering. Unfortunately running a product import then destroyed all that work.
    Found this thread with a staff reponse regarding it not being possible to set release dates using import, but it doesn't explain why release dates get reset.

  • Removing Role Membership through API's in OIM11g

    Guys, I am trying to remove a role membership for a user.
    I was trying with this API (*oracle.iam.identity.rolemgmt.api*) and Interface RoleManager.revokeRoleGrant(roleKey,userKeys,evaluatePolicies). I am getting errors when I try to Import the api oracle.iam.identity.rolemgmt.api as Import cannot be resolved. which is the exact jar that I should add in the build path?
    I have added all the 25 jars of lib but still it is not resolved.
    And is this the correct API for removing the role membership for a user?
    please share the sample code snippet if any of you have already have that functionality?
    Edited by: Venu on Aug 24, 2011 3:00 PM

    Venu wrote:
    Guys, I am trying to remove a role membership for a user.
    I was trying with this API (*oracle.iam.identity.rolemgmt.api*) and Interface RoleManager.revokeRoleGrant(roleKey,userKeys,evaluatePolicies). I am getting errors when I try to Import the api oracle.iam.identity.rolemgmt.api as Import cannot be resolved. which is the exact jar that I should add in the build path?
    I have added all the 25 jars of lib but still it is not resolved.
    And is this the correct API for removing the role membership for a user?
    please share the sample code snippet if any of you have already have that functionality?
    Edited by: Venu on Aug 24, 2011 3:00 PMYou don't need to use 25 jars from the lib in your client code. Just need to use 3 jars which are bundled in the OIM_HOME\server\client\oimclient.zip\lib folder and wlfullclient.jar. The oracle.iam.identity.rolemgmt.api is in oimclient.jar which is in the oimclient.zip\lib folder.
    HTH

  • Update Quotation API

    Dear All,
    I need to update Quotation from oracle back-end in Purchasing. Is there any API to do that or any alternative way?
    Any input on this would be highly appreciated.
    Thanks,
    Astik

    Hi Astik,
    You may try using "Purchasing Documents Open Interface" [http://docs.oracle.com/cd/A60725_05/html/comnls/us/po/puthpu10.htm]
    Regards,
    G V Ranjith

  • Update center _ALWAYS_ wants to update Java API reference

    why is it that even if I run the update for JSC back to back in two consecutive sessions it will always want to update the Java API reference? it is changing that often??

    Hi jakeochs,
    This problem still persists. I have opened a change request on your behalf. Thanks for bringing it to notice.
    Regards,
    Creator Team.

  • Dinamicaly assign Worksets, Pages, iViews to a Role using the APIs ?

    Hi,
    Has someone built a Role via Webdynpro coding?
    Hope someone has done it and could help.
    Thanx in advanced!
    Kind Regards,
    Gerardo J

    Hi Shanti,
    thanx alot for the help! actually folowing documentation in the help.sap.com I found this:
    "PCD Roles: These are semantic objects that represent collections of content that can be assigned to a user.
    There is no public API for accessing these roles."
    here I paste the link
    http://help.sap.com/saphelp_nw70/helpdata/en/44/43863b2e641193e10000000a155369/frameset.htm
    I Guess then is no way to modify the Role via API to achieve this, or this is only on 7.0 and now it is posible on 7.1?
    Thanx in Advanced!
    Kind Regards,
    Gerardo J
    Edited by: Gerardo Jiménez on Jan 31, 2011 11:58 AM

  • Adding a role thru oim API

    Hi Experts,
    I am getting role from object form and the user will be added to this role once the provisioning is completed to a resource.
    If I want to pass this role to child form and then trigger corresponding addroletask in schedule task using Oracle API, please let me know the process and steps that I have to take care. If you have any sample code just for my reference, plz post it here.

    Here is the Code which you can refer. Change it per your requirement
    process Key = ORC_KEY
    long formKey = formInstanceIntf
                                  .getProcessFormDefinitionKey(processKey);
                        int formVersion = formInstanceIntf
                                  .getProcessFormVersion(processKey);
                        tcResultSet childTable = formInstanceIntf
                                  .getChildFormDefinition(formKey, formVersion);
                        long childDefKey = 0L;
                        for (int i = 0; i < childTable.getRowCount(); i++) {
                             childTable.goToRow(i);
                             if (childTable.getStringValue(
                                       "Structure Utility.Table Name").equalsIgnoreCase(
                                       "UD_ADSTDPRO")) {
                                  childDefKey = childTable
                                            .getLongValue("Structure Utility.Child Tables.Child Key");
                                  break;
                        tcResultSet childData = formInstanceIntf
                                  .getProcessFormChildData(childDefKey, processKey);
    //if want to remove the value
    for (int j = 0; j < childData.getRowCount(); j++) {
                             childData.goToRow(j);
    long childPrimaryKey = childData
                                            .getLongValue("UD_ADSTDPRO_KEY");
    formInstanceIntf.removeProcessFormChildData(
                                            childDefKey, childPrimaryKey);
    //if want to add a value
    HashMap proxyMap = new HashMap();
    proxyMap.put("UD_ADSTDPRO_PROXY_ADDRESS", SAMPLE VALUE);
    formInstanceIntf.addProcessFormChildData(childDefKey,
                                            processKey, proxyMap);

Maybe you are looking for

  • ATI 1900 XT dead

    My ATI 1900XT in my trusty 2006 2x2.66 Mac Pro has now gone to the happy hunting ground -- it will sometimes work, but most of the time, it just pumps a couple milliseconds of vertically sheared video out to the monitor and then goes black again. Tha

  • IPhoto: re-enabling photo stream every time?

    i'm not using aperture (read here that some people are using both and then have problems) and i've enabled photostreamed on all my devices and sucessfuly synced my photos on my mac. however, every now and again, (i think every time i reboot) iphoto w

  • Exporting photos with editing changes

    Hi, I am new to LightRoom. This question might be stupid, but I am having trouble exporting my photos and maintaining the editing changes that I have made. Here are the specifics: I made changes to many raw photos using LR on my desktop computer (Mic

  • My full library is not on my phone but showing in my itunes

    I have copy all music and songs checked to sync...  Any help???

  • HT4854 trouble downloading mountain lion

    I just bought mountain lion at the app store and it says it is downloading, but the progress bar below the icon in my doc remains empty (pure white).  I'm trying to upgrade from 10.6.8 (Snow Leopard).  Any idea why it's not working?