[WP 6.1] Invalidate Puma Cache - Websphere

This is a discussion on [WP 6.1] Invalidate Puma Cache - Websphere ; Hi, In my portal application, it happens that some LDAP user attributes are modified by an external application. I'd like to see those changes "instantly" (at worst after the next logout/login) visible in the PumaUser. I know it's possible to ...

+ Reply to Thread
Results 1 to 6 of 6

Thread: [WP 6.1] Invalidate Puma Cache

  1. [WP 6.1] Invalidate Puma Cache

    Hi,

    In my portal application, it happens that some LDAP user attributes are modified by an external application.
    I'd like to see those changes "instantly" (at worst after the next logout/login) visible in the PumaUser.

    I know it's possible to turn off Puma cache, but I think it's not a great idea for performance consideration.
    Is there a way to invalidate programmaticly Puma cache, at best only for current user?

    Regards,

    Fabrice.

  2. Re: [WP 6.1] Invalidate Puma Cache

    Hi,
    I try to invalidate puma cache as any other Dynacache object.


    +InitialContext ic = new InitialContext();+
    +DistributedMap dMap1 = (DistributedMap)ic.lookup("ws/com.ibm.wps.puma.DN_User_Cache");+
    +...+
    +dMap1.invalidate(currentUserDN);+


    But I have exception :
    javax.naming.NameNotFoundException: Context: vmok/nodes/vmok/servers/WebSphere_Portal, name: ws/com.ibm.wps.puma.DN_User_Cache: First component in name ws/com.ibm.wps.puma.DN_User_Cache not found. [Root exception is org.omg.CosNaming.NamingContextPackage.NotFound: IDLmg.org/CosNaming/NamingContext/NotFound:1.0]


    What is the problem ? Am I in the good way?

    Thanks for any help,

    fabrice.

  3. Re: [WP 6.1] Invalidate Puma Cache

    In fact that very easy to clear Puma cache for a user with 6.1 SPI.
    You need to use reload(PumaUser) method.


    +com.ibm.portal.um.portletservice.PumaHome service = (com.ibm.portal.um.portletservice.PumaHome) psh.getPortletService(com.ibm.portal.um.portletser vice.PumaHome.class);+
    +PumaController pController = service.getController(request);+
    +PumaProfile pp = service.getProfile(request);+
    +com.ibm.portal.um.User pu = pp.getCurrentUser();+
    +pController.reload(pu);+

    Don't forget that there is also cache on VMM level.

    Regards,

    Fabrice.

  4. Re: Invalidate Puma Cache

    On Mar 11, 8:02*am, f.chap...@acamaya.com wrote:
    >
    > Don't forget that there is also cache on VMM level.
    >


    Thanks for the puma code sample. That's very useful. How do you clear
    the VMM cache?

    Craig

  5. Re: [WP 6.1] Invalidate Puma Cache

    Don't forget that there is also cache on VMM level.

    Fabrice,

    How do you invalidate the cache on VMM level?

    thnx

    joey

  6. Re: [WP 6.1] Invalidate Puma Cache

    Great!

    Thank you very much for this piece of information this was really killing me.

    Oh and for disabling the caches for VMM take a look at the following technote. This also gave me problems a while back.

    [Changes made directly in the LDAP do not become visible after logging out and in|http://www-01.ibm.com/support/docvie...d=swg21286136]

+ Reply to Thread