Multiple key cache lookup cases for the same values

Hi,
Just curious whether someone else on this forum has dealt with this use case: we'd like to use the Coherence cache to store objects of say class Foo with fields a and b (Foo(a,b)) using a as the key. The named cache is backed by a database and puts will insert into the corresponding Foo table and gets will either result in a cache hit or read through using a CacheStore implementation we'd write.
Now, for the 2nd requirement, we need to look up the same objects using field b (or a combination of different fields for that matter). Currently we are thinking of a 2nd named cache that maps b onto Foo(a,b) with a possible optimization that the 2nd cache will map b onto a so the client doing the get can turn around and query the first cache using a. Puts in the first cache will add entries to the second cache to keep the 2nd cache up to date with a -> b mappings. The optimization prevents Foo being stored in two caches.
Note that we will not store all entries for Foo in the cache as the sheer number of expected entries makes this option not feasible hence we cannot rely on a cache query (using indexes) to look the object up.
Any comments on this approach or ideas on how to implement this differently?
Thanks!
Marcel.

Hi Marcel,
That is correct, QueryMap only operates on entries that are in-memory; there is no way to "query-through" a cachestore for example.
Given that, I think that your proposed approach (of maintaining a separate b->a mapping) makes sense.
thanks,
-Rob

Similar Messages

  • Release By two Users for the  same Value

    Friends
    I have an existing PO rel. strategy where the range is 1-10000USD  . This is currently released by one user. Now due to business requirement  client wants to introduce one additional user to release the PO as well for the same  value range.
    In a nutshell for the value range  USD 1-10000 , There will be two approvers with two different rel. codes. How do I achieve this?
    Thanks
    samuel

    Dear,
    Check this : Release Procudure for Purchase Order
    Hope Helpful to your requirement.
    Regards,
    Syed Hussain.

  • Is it possible to store a multiple indexes for the same value extractor?

    I ran into a situation where there were different queries that I was interested in doing that might have benefitted from having several indexes, sorted differently, but for the same ValueExtractor() instance.
    Is this good practice, is it recommended, and is there a clean way to do it? It seemed like the only way I could logically "trick" the system into it would be passing some sort of "query type" constant into the ValueExtractor when it was created, and then making the equals and hashCode() methods on the ValueExtractor delegate to the constant for equality, but this seemed like a massive hack.

    Hi Kris,
    First, try without each value extractor and see how the different queries compare in performance. You may find that you need only one. If you find otherwise, please let us know because it may indicate a good area for additional optimizations.
    Second, you are correct that the value extractor is the key of the index, and thus to have two indexes on the same value, you will need two different value extractors (i.e. the hashcode/equals comment you made.)
    Peace,
    Cameron Purdy
    Tangosol, Inc.
    Coherence: Easily share live data across a cluster!

  • Multiple BOM Explosion in MD04 for the same material

    Dear PP Gurus,
    Scenario is make to order. BOM is created for production usage (1) & sales usage (5) for a Header material. Routing also exists for the same.
    Once i run MRP at plant level or material level after creating sales order , BOM is expoded multiple times i.e. 3- 4 times but proposals ( planned orders) are created as per requirements.But BOM explosion when we click on show overview tree is happening multiple times which should not happen.
    Our client business is not getting hampered by this but still he doesnt want explosion multiple times and to be precise it should not happen.
    Can anyone pls. throw some light on this .
    Thanks in advance . Answers will be rewarded for sure.
    regards,
    Nagraj Vasmate

    Hello Nagraj,
    In MD04, On overview tree, it explodes all possible BOM for the header material.
    System will explode all valid BOM's with usage 5 and 1 for that specific material.
    Reg
    Samson

  • FIM CALs on multiple instance of FIM Portal, for the same users

    Hi,
    We have FIM Sync, FIM Service/Portal & SSPR deployed (Server #1). We have licensed the server components of FIM, as well as the user CALs (2000 users).
    Due to business requirements, if we now deploy another FIM Sync and FIM Service/Portal (Server #2) - I understand we will require server licenses.
    However, since we already have the 2000 FIM CALs (being used on Server #1), my understanding is that we do not need to purchase another 2000 CALs, as we will be managing the same 2000 users on the new FIM Service/Portal server.
    Is this understanding correct?
    Thanks,
    SK

    On Wed, 18 Mar 2015 03:28:53 +0000, Shim Kwan wrote:
    So in addition to the FIM Server licenses, we will require yet another 2000 FIM CALs?
    My educated guess is yes, but you should really be checking with your
    Microsoft account rep.
    Paul Adare - FIM CM MVP
    All that blue light from Orthanc at night? That was
    Saruman, trying to moderate
    -- news.admin.palantir-abuse.sightings.

  • Multiple instances of APPS for the same database?

    Since upgrading to 11.5.10, we are not able to have multiple instances of APPS open for the same database. Prior to the upgrade we could which allowed a person to have 2 sessions open with different responsibilities, thus not having to switch each time.
    Is there a profile setting/patch etc which will allow this again?
    thanks

    In my case I think the company's main requirement was to have two separate environments (PROD and TEST) open at the same time which I think is fine.
    From memory (don't quote me on this) I don't think the old Personal Home Page is supported from 11.5.10.2 or something.
    I think another option was rather than have multiple sessions, add the two functions you are trying to access to the same menu/responsibility then you can open both at the same time.
    I just use favourites with one forms function from each responsibility and hardly click on or attempt to navigate the responsibility function list ... this mimics the old functionality.
    Also created a few "Copy Favourites" concurrent programs to copy favourites from one user to another or to all users of a responsibility.
    Re the old vs new feel - I know the feeling ;-) Ages ago I logged an SR to see if the dynamic tree portlet you get when you integrate with Portal could be used within core Apps, but wasn't possible per standard. Also thought of throwing together a greasemonkey script to achieve the same, but haven't gotten round to that ;-) and it wouldn't work with IE ... maybe one of the OAF gurus might read this and have a crack at it ?!
    Gareth

  • SCD - source sets where multiple changes exist for the same natural key

    I am using the Oracle SCD type2 method (end date old record and insert the new record) which was working fine until my source set contained multiple changes for the same natural key. Does anyone know of a way to handle this?
    Thanks

    Hello,
    I think, the way of handling multiply changes of NK is totally depend on business requirements for your project.
    There could be number of approaches for this. For example:
    - all changes but the last are considered active during one day, going subsequently right after previously existed SCD record;
    - all changes but the last are considered “active” depending on its occurrence within “fact” data (as far as you consider NK change based on some attribute set - probably some of attributes show themselves within “fact” data)
    - etc.
    So, make an agreement upon this with your customer – and ETL design decision will follow immediately.
    Sergey

  • Oracle Coherence*Web and BlazeDS: Multiple FlexSessions created for the same HttpSession

    Hi all,
    I have searched this forum and found a lot of good information from Alex Glosband and others about the infamous "Detected duplicate HTTP - based FlexSessions, generally due to the remote host disabling session cookies. Session coolkies must be enable to manage the client connection correctly." message.
    It seems, however, none of the cases are identical to ours. This is ours:
    - Resin 3.1.9
    - Oracle Coherence 3.7.1 with Coherence*Web (session replication)
    With this setup we get the "Detected duplicate HTTP..." message on the first attempt to use BlazeDS and on every subsequent call.  The same client and server code works fine in a local sessions setup.  With Coherence 3.3 (currently our production environment) it seems to occur less frequently, but still as frequent as it is a major issue for us.  It fails even with a single node using in-process distributed caching in our test setup (as well as with multi node out of process caching in our staging environment, for Coherence knowledgeable the resin app server runs with tangosol.coherence.session.localstorage=true in the first case and false in the second).
    Both the listener and message broker are mapped as "Coherence aware" in web.xml[1] so that they should use clustered sessions.
    We have been digging a bit and we found out that if we commented out lines 427 and 434 of flex.messaging.endpoints.BaseHTTPEndpoint from version 4.0.0.14931 it seems to mask the bug.  We added some logging in the setupFlexClient method and it seems that we get more or less a new FlexSession for each and every call - but they have the same cookie and thus underlying HttpSession. I.e. the list returned from flexClient.getFlexSessions() keeps growing. Thus we are not so keen on going to production with that memory leak and the above mentioned ugly hack of commenting out the detection of duplicates.
    We use request scope for the remote object, but could in theory use any scope as we do not really have any state on the object itself, it is all HttpSession state and return values that are key (logon is performed prior to doing the first blaze call, in pure forms and ajax, and it is not a timing issue in that regard we are seeing).
    Hope someone can shed some light on what can be happening. Is there any "reference testing"[2] or something when the FlexSessions are created that makes them being created as new? Where are they created?  We do not know the inner workings of the BlazeDS source, we just watched the call trace of the unwanted invalidation and found that to be line 427 of flex.messaging.endpoints.BaseHTTPEndpoint.
    Can we disable FlexSessions?  Since the flex and plain html parts of the app share the sessions, we always use FlexContext.getHttpRequest().getSession() anyway, never storing any state directly in the FlexSession or on the remote object. Or maybe there is a config option to help us with this detection (or creation) of multiple FlexSessions?
    Cheers and TIA,
    -S-
    [1] - For instance, this i the message broker servlet def:
    <servlet>
    <servlet-name>MessageBrokerServlet</servlet-name>
      <display-name>MessageBrokerServlet</display-name>
    <servlet-class>com.tangosol.coherence.servlet.api22.ServletWrapper</servlet-class>       
    <init-param>
    <param-name>coherence-servlet-class</param-name>
    <param-value>flex.messaging.MessageBrokerServlet</param-value>
    </init-param>       
    <init-param>
    <param-name>services.configuration.file</param-name>
    <param-value>/WEB-INF/flex/services-config.xml</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
    </servlet>
    [2] - As you undertstand this is speculation based on pure air, but it could be that in Coherence there was a serialization/deserialization happening somehow that would break such a test?

    Just a quick update, it seems things are running in a stable fashion (and without visible memory leaks, just keeping the latest FlexSession) with these changes in BaseHTTPEndpoint:
         * Overrides to guard against duplicate HTTP-based sessions for the same FlexClient which will occur if the remote host has disabled session
         * cookies.
         * @see AbstractEndpoint#setupFlexClient(String)
        @Override
        public FlexClient setupFlexClient(String id) {
            log.debug("setupFlexClient start id " + id);
            FlexClient flexClient = super.setupFlexClient(id);
            // Scan for duplicate HTTP-sessions and if found, invalidate them and throw a MessageException.
            // A request attribute is used to deal with batched AMF messages that arrive in a single request by trigger multiple passes through this
            // method.
            boolean duplicateSessionDetected = (FlexContext.getHttpRequest().getAttribute(REQUEST_ATTR_DUPLICATE_SESSION_FLAG) != null);
            if (!duplicateSessionDetected) {
                List<FlexSession> sessions = flexClient.getFlexSessions();
                log.debug("Client has " + sessions.size() + " sessions.");
                int n = sessions.size();
                if (n > 1) {
                    int count = 0;
                    for (int i = 0; i < n; i++) {
                        if (sessions.get(i) instanceof HttpFlexSession)
                            count++;
                        if (count > 1) {
                            FlexContext.getHttpRequest().setAttribute(REQUEST_ATTR_DUPLICATE_SESSION_FLAG, Boolean.TRUE);
                            duplicateSessionDetected = true;
                            break;
            // If more than one was found, remote host isn't using session cookies. Kill all duplicate sessions and return an error.
            // Simplest to just re-scan the list given that it will be very short, but use an iterator for concurrent modification.
            int i = 0;
            if (duplicateSessionDetected) {
                List<FlexSession> sessions = flexClient.getFlexSessions();
                log.debug("Detected sessions from client: " + sessions);
                for (FlexSession session : sessions) {
                    if (session instanceof HttpFlexSession && i < sessions.size()) {
    //                    log.debug("----> sessionId: " + session.getId());
    //                    Enumeration e1 = session.getAttributeNames();
    //                    while (e1.hasMoreElements()) {
    //                        Object key = e1.nextElement();
    //                        log.debug("--------->" + key + "--------->" + session.getAttribute((String) key));
    //                    session.invalidate();
                        flexClient.sessionDestroyed(session);
                    i++;
                // Return an error to the client.
    //            DuplicateSessionException e = new DuplicateSessionException();
    //            e.setMessage(ERR_MSG_DUPLICATE_SESSIONS_DETECTED);
    //            throw e;
            return flexClient;
    It is not exactly beautiful (to say the least), but if it does the trick I might just be pragmatic enough to go with it... NB: I am of course not proposing this as a patch to this file or anything, it is just an ugly hack for our specific case, but maybe the information can help the BlazeDS team find the root cause making it incompatible with Coherence*Web.
    Will give it a test run on our staging servers.

  • Multiple DEVL_PROJECT_ID for the same model in CZ_DEVL_PROJECTS Table.

    Hi,
    Did anyone came across this issue!! I am triggering the config engine from back and and trying to pick up a model but it has multiple devl_project_id's. :(
    I could see multiple DEVL_PROJECT_ID for the same model in CZ_DEVL_PROJECTS Table. Apart from DEVL_PROJECT_ID and created_by_date every thing looks the same.
    Below are the 2 records the data from the table
    select * from CZ.CZ_DEVL_PROJECTS where product_key = '122:17056' and DEVL_PROJECT_ID in (12943,15321)
    DEVL_PROJECT_ID     NAME     ORIG_SYS_REF     CREATION_DATE     LAST_UPDATE_DATE     PERSISTENT_PROJECT_ID     MODEL_TYPE
    12943     ASI XXX MODEL(122 17056)     OPTIONAL:122:17056     12/18/2012 10:01     12/18/2012 10:01     11100     A
    PRODUCT_KEY     ORGANIZATION_ID     INVENTORY_ITEM_ID     BOM_CAPTION_RULE_ID     NONBOM_CAPTION_RULE_ID
    122:17056     122     17056     802     801
    15321     ASI XXX MODEL(122 17056)     OPTIONAL:122:17056     12/26/2012 23:10     12/26/2012 23:10     11100     A     
    122:17056     122     17056     802     801
    Thanks in advance,
    -vijay

    It can be possible to have multiple devl_project_id for the same model in cz_devl_projects Table.
    Case -1 : When you delete the existing model and re-import again.
    case 2:
    When you publish the model locally, it will create the same copy of the record with different devl_project_id, creation_date, last update_date etc..\
    You can see that for published records the last_updat_login, checkout_user will be null and for the original model, last_update_login,checkout_user (if model is locked) will not be null.
    -Murali
    Edited by: 907569 on Jan 8, 2013 10:55 AM

  • Multiple Partners for the same customer in Message tracking of SEEBURGER

    Hi,
    This is for third party customers which use EDI messages. We have for one customer multiple partner numbers configured in Partner profile. I would like to know while configuring the trading partners in SEEBURGER Message Tracking, can we have multiple keys for the same customer for multiple partners for an INVOIC02. Like the following keys:
    12345_INVOIC02
    34567_INVOIC02
    45678_INVOIC02

    Hi Satya,
    you can define for a vendor/customer several partner functions with different        
    adresses. You can create certain partner roles several times.               
    If you create a purchase order, than you can choose the wanted              
    address and partnerrole on the header level. In the standard system you     
    can use the patner role 'OA' ordering address and for the finance           
    the 'IP' Invoice presented by.
    I hope I was able to help you.
    Kind regards,
    Zsuzsanna

  • Ip sla operations with different keys for the same destination

      Hi all,
    the customer wants to use different ip sla operations for the same destination (ip sla responder). From the first source router he uses key key1 and from the second source router he uses key key2. The ip sla responder responds only for the first router which uses the key key1.:-( Is it a normal behaviour? Can I use different keys for different ip sla operations for the same ip sla responder?
    See the configuration on the responder:
    key chain test
    key 1
      key-string 7 *key1*
    key 2
      key-string 7 *key2*
    ip sla key-chain test
    ip sla responder
    He tried to use ip sla responders on:
    Ciscu 2911
    Cisco IOS Software, C2900 Software (C2900-UNIVERSALK9-M), Version 15.2(4)M3, RELEASE SOFTWARE (fc2)
    Cisco 881
    Cisco IOS Software, C880 Software (C880DATA-UNIVERSALK9-M), Version 15.1(4)M4, RELEASE SOFTWARE (fc1)
    Thank you.
    Roman

    Thomas,
    Have a look at:
    http://www.cisco.com/en/US/docs/ios-xml/ios/sec_conn_dmvpn/configuration/15-2mt/sec-conn-dmvpn-share-ipsec-w-tun-protect.html#GUID-2B448241-FD10-4F3B-BFF8-DFD44982D235
    If you're using one tunnel source you need to use one ipsec profile, unless you're running (a) p2p tunnel which you're not in this case.
    While you MAY have some luck with sharing/unsharing among different interface I'm afarid it will not be ever mentioned as supported.
    The situation will change with upcomfing 3.10 and 3.11 IOS XE releases (and corresponding IOS releases).
    M.

  • Multiple shipping addresses for the same supplier (depending on the symbol)

    Hello ,can we set up multiple shipping addresses for the same supplier (depending on the symbol)?
    .& How..
    Thanks

    a delivery adedress has nothing to do with a certain supplier, except you are talking about subcontracting (do you?)
    a delivery address specifies an address where you want the supplier to send the goods to.
    if it is a third party PO, then the delivery address is derived from ship-to partner of the sales order.
    in case of a standard order to stock, the delivery address is coming from the storage location address (if maintained). if no storage location address is maintained, then SAP takes the address from your plant.
    You can manually add a delivery address in MEAN transaction and then manually assign in POs delivery address tab.
    here you can as well take the address from any address already in your system (e.g. any customer or vendor).

  • Data not adding for the same Key up in Infocube

    Hi,
    My Dataflow goes like this:  Datasource  -> DSO -> Infocube.
    I have created 2 DSO's for Deliveries Header & Delivery Item Seperately which gets data from 2LIS_11_VCHDR & 2LIS_11_VCITM Datasources.  Both DSO's have Delivery Number & Fiscal Year variant as Key.  20 records are getting loaded to each DSO's seperately.  Both the DSO's have the same Delivery Numbers & Fiscal year Variant for this 21 Records in their respective Loads as given below:
                                     DSO 1                                                                  DSO 2
    S.No.       Deliver No.    Fiscal Year Var.                          Delivery No.       Fiscal Year Var.
       1               12345                     V3                                          12345                         V3
       2               28456                      V3                                          28456                        V3
       3               34986                      V3                                          34986                        V3
    Now, I am loading data from this 2 DSO's to one Infocube, Deliveries Infocube.  The problem is, after the Data load, when i go to the Contents of the Infocube, I could see 42 records.  As per Infocube, it should add up the values for the same key.  My Delivery numbers & Fiscal year vairant are the same in both the DSO's, so i should have got only 21 records.  Why is the Infocube not adding up the records in this case, am i missing anything here?
    Thanks & Regards,
    Murali

    Hi Murali,
    As you are loading data from two different sources, there are two different requests and that is why you are getting 42 records, if you want to check the data consistency then create a query on top of this infocube and then check the values of key figures for delivery no's. or verify your data through query.
    If you don't want to create query then you can use aggregation option from the display data of Infocube.
    If you compress both the requests then you will see only 21 records in infocube.
    Regards,
    Durgesh.

  • When I enter an event in iCal, soon thereafter multiple other "New Event" notices (one to four) appear for the same day. If I delete these unwanted "New Event" notices, they later reappear -- sometimes multiplying like rabbits. Any suggestions?

    When I enter an event in iCal, soon thereafter multiple other "New Event" notices (one to four) appear for the same day. If I delete these unwanted "New Event" notices, they later reappear -- sometimes multiplying like rabbits. Any suggestions?

    Well, using iMovie to rearrange clips in a mini DV video edited by another program is extremely time consuming. I found a workaround. It still takes time, but it's much faster than rearranging the clips using iMovie.
    The workaround is as follows. Bring up Finder and go to the directory where your event's clips are stored (typically ~/Movies/iMovie Events/<name of event>). It helps to setup Finder to be in Cover Flow mode, so you can see the beginning of each clip. Then, sort the files in ascending order by the 'Date Modified' field. This makes Finder sort the files in the same order that they were imported from the mini DV tape. Clips with timecodes have the naming convention "clip-<year>-<month>-<day> hour;minute;second.dv". Clips without timecodes use another naming convention. With the files sorted by "Date Modified" in Finder, rename clips as needed so that the date/time in their file names are in ascending order. Note: when you rename a file, you need to restart iMovie. I suggest not running iMovie while renaming files.
    I believe the file date/timestamp is only accurate to the second. Occasionally, there may be a couple of clips that have the same date/timestamp. This may cause the ordering to not be correct. The best way to find these is through iMovie. To modify a file's date/time, right click on the clip in the event in iMovie, and then select "Adjust Clip Date and Time...".
    So, this workaround is a lot easier and faster than trying to rearrange things from scratch in iMovie. But it's still time consuming. Creating a project out of an already edited video should take less than 5 minutes (not counting import time), but that's not the case.
    I submitted an enhancement request to Apple asking if they can add an option to sort an event's clips in the order that they were imported by iMovie. Those who have the same issue as me, I suggest you submit an enhancement request as well.
    Anyone have any other suggestions?
    Thanks.

  • Multiple MM schedule lines for the same date

    Hello All Gurus,
    I am facing a problem where the MM schedule lines are divided into various quantites for the same date. For example on 02/11/2010 the total quantity is 120, it is appearing in the below form in ME38:
    02/11/2010 - 40
    02/11/2010 - 40
    02/11/2010 - 40
    Although this is not an error, but my client is not happy with this. Can someone tell me why I am getting this error? Is it because of the rounding value that we maintain in MRP 1 view of material master record? Or is there any other setting that I am missing?
    Please let me  know. I would be very much thankful to you.
    Thanks and Regards,
    Umakanth

    Hi,
    Before changing the setup, note that sometimes it is beneficial to split one demand into multiple delivery schedules. Especially if the demand is bigger than equipment type (container/truck etc.). If you want to manage inbound transportation for such delivery schedules, it is much simpler to do this when each delivery schedule is not bigger than one equipment.
    Regards,
    Dominik Modrzejewski

Maybe you are looking for

  • How do i send hyperlink to a text box within the same page

    how do i send hyperlink to a text box within the same page on iweb

  • Audio and Video out of Sync in Encore 2.0

    Here's my issue: I opened a project in Encore 2.0 that was an Encore 1.5 project. I have one timeline with a 2 hour movie and the AC3 audio file that goes with it. Encore 1.5 played the audio and video in sync from the timeline and burned discs with

  • Selection in IP for flat file Load

    Hi Experts , I Want to know can I have selections available for an IP which is created for Flat file as data source. your early response is highly appreciated. Regards Patil

  • Private inner class and static private inner

    Hi, I understand the concept and usage of inner classes in general. When should we go for a private inner class and when for a static private inner class? I tried searching but it wasn't of much help. Basically I need to design a caching solution in

  • Some services in maintenance state after reboot

    Hi, I installed solaris 10 and everything ran fine for a month. I recently upgraded memory on the server and when I rebooted, some of the services were put in the maintenance mode. Here is the solaris 10 release info: bash-3.00# cat /etc/release Sola