Cache Problem, Please

I have two different type objects, one refer another, using one to one mapping.
At first, I get the parent object, and then I also get the child object, using session.executeQuery, as you know, toplink will get the child object from the cache, as my database is modified by another program, so I use session.refreshObject(chindObject) to refresh the child object, and then I modify the child object and succuess, but when i get the parent object again, i find the childobject didnot be modified, and the parent pointer to childobject is the old address, but the toplink cache address of childobject has been changed.
I cant use session.refreshObject(parentObject) to refresh the parentObject, because I have many parent object. and my database may be modified by another program. so what can do?

Thank your responses, the following function is my adding and modifying function, please help me check it whether or it is right, thx!!!
And I used SoftCacheWeakIdentityMap. and whether all the searching function must use roq.dontCheckCache() to insure that the searching result is the latest data? if so, my cache is dirt cheap.
public static PersistenceObject getObjectByOid(Session session, Class clazz, String oid)
throws DomainServiceException {
String funcName = "getObjectByOid()";
try {
ReadObjectQuery roq = new ReadObjectQuery();
roq.setReferenceClass(clazz);
roq.setSelectionCriteria((new ExpressionBuilder()).get("oid").equal(oid));
roq.dontCheckCache(); //Use the Statement instead of session.refreshObject
PersistenceObject pObj = (PersistenceObject)session.executeQuery(roq);
integrator.logDebug(funcName, "session.executeQuery(): clazz: "+clazz+", oid:"+oid);
session.printIdentityMap(ProcessingMethod.class);
if (pObj != null){
//session.removeFromIdentityMap(pObj);
session.printIdentityMap(ProcessingMethod.class);
return pObj;
} catch (Throwable e) {
integrator.logError(funcName, "Input: clazz: "+clazz);
integrator.logError(funcName, "Input: oid: "+oid);
throw new DomainServiceException(e);
public static String addOrUpdateObject(Session session,PersistenceObject pObj, String userId)
throws DomainServiceException {
String funcName = "addOrUpdateObject()";
String oid = null;
Produce produce1 = (Produce)session.executeQuery("SelectyByOid", Produce.class, "51");
session.printIdentityMap(Produce.class);
if (pObj != null) {
// try to retrieve the corresponding object from DB.
if (pObj != null) {
//session.removeFromIdentityMap(pObj); // remove the pObj from identity map to make sure the object we get in the next line is from DB.
integrator.logDebug(funcName, "removeFromIdentityMap is called");
session.printIdentityMap(ProcessingMethod.class);
PersistenceObject pObjFromDB = (PersistenceObject) this.getObjectByOid(session, pObj.getClass(), pObj.getOid());
integrator.logDebug(funcName, "QueryService.getObjectByOid() is called");
// pObjFromDB = (PersistenceObject)session.refreshObject(pObjFromDB);
session.printIdentityMap(ProcessingMethod.class);
try {
UnitOfWork uow = session.acquireUnitOfWork(); // acquire the unit of work.
integrator.logDebug(funcName, "session.acquireUnitOfWork() is called");
uow.registerObject(pObjFromDB);
integrator.logDebug(funcName, "uow.registerObject() is called");
session.printIdentityMap(ProcessingMethod.class);
// merge the changes from pObj.
PersistenceObject pObjClone = (PersistenceObject) uow.mergeCloneWithReferences(pObj);
integrator.logDebug(funcName, "uow.mergeCloneWithReferences() is called");
updateObjHistory(uow, pObjClone, userId); // update the changelog.
integrator.logDebug(funcName, "updateObjHistory() is called");
uow.commit();
integrator.logDebug(funcName, "uow.commit() is called");
Produce produce2 = (Produce)session.executeQuery("SelectyByOid", Produce.class, "51");
oid = pObj.getOid();
} catch (DatabaseException dbException){
integrator.logError(funcName, dbException.getMessage());
dbException.printStackTrace();
if (dbException.getCause() instanceof SQLException) {
SQLException sqlException = (SQLException)dbException.getCause();
if (sqlException.getErrorCode() == 1){  // unique constraint violated.
throw new DuplicateRecordException(dbException);
} else {
throw new DomainServiceException(dbException);
return oid;

Similar Messages

  • Dynamic Calc processor cannot lock more than [100] ESM blocks during the calculation, please increase CalcLockBlock setting and then retry(a small data cache setting could also cause this problem, please check the data cache size setting).

    Hi,
    Our Environment is Essbase 11.1.2.2 and working on Essbase EAS and Shared Services components.One of our user tried to run the Cal Script of one Application and faced this error.
    Dynamic Calc processor cannot lock more than [100] ESM blocks during the calculation, please increase CalcLockBlock setting and then retry(a small data cache setting could also cause this problem, please check the data cache size setting).
    I have done some Google and found that we need to add something in Essbase.cfg file like below.
    1012704 Dynamic Calc processor cannot lock more than number ESM blocks during the calculation, please increase CalcLockBlock setting and then retry (a small data cache setting could also cause this problem, please check the data cache size setting).
    Possible Problems
    Analytic Services could not lock enough blocks to perform the calculation.
    Possible Solutions
    Increase the number of blocks that Analytic Services can allocate for a calculation:
    Set the maximum number of blocks that Analytic Services can allocate to at least 500. 
    If you do not have an $ARBORPATH/bin/essbase.cfg file on the server computer, create one using a text editor.
    In the essbase.cfg file on the server computer, set CALCLOCKBLOCKHIGH to 500.
    Stop and restart Analytic Server.
    Add the SET LOCKBLOCK HIGH command to the beginning of the calculation script.
    Set the data cache large enough to hold all the blocks specified in the CALCLOCKBLOCKHIGH setting. 
    Determine the block size.
    Set the data catche size.
    Actually in our Server Config file(essbase.cfg) we dont have below data  added.
    CalcLockBlockHigh 2000
    CalcLockBlockDefault 200
    CalcLockBlocklow 50
    So my doubt is if we edit the Essbase.cfg file and add the above settings and restart the services will it work?  and if so why should we change the Server config file if the problem is with one application Cal Script. Please guide me how to proceed.
    Regards,
    Naveen

    Your calculation needs to hold more blocks in memory than your current set up allows.
    From the docs (quoting so I don't have to write it, not to be a smarta***:
    CALCLOCKBLOCK specifies the number of blocks that can be fixed at each level of the SET LOCKBLOCK HIGH | DEFAULT | LOW calculation script command.
    When a block is calculated, Essbase fixes (gets addressability to) the block along with the blocks containing its children. Essbase calculates the block and then releases it along with the blocks containing its children. By default, Essbase allows up to 100 blocks to be fixed concurrently when calculating a block. This is sufficient for most database calculations. However, you may want to set a number higher than 100 if you are consolidating very large numbers of children in a formula calculation. This ensures that Essbase can fix all the required blocks when calculating a data block and that performance will not be impaired.
    Example
    If the essbase.cfg file contains the following settings:
    CALCLOCKBLOCKHIGH 500  CALCLOCKBLOCKDEFAULT 200  CALCLOCKBLOCKLOW 50 
    then you can use the following SET LOCKBLOCK setting commands in a calculation script:
    SET LOCKBLOCK HIGH; 
    means that Essbase can fix up to 500 data blocks when calculating one block.
    Support doc is saying to change your config file so those settings can be made available for any calc script to use.
    On a side note, if this was working previously and now isn't then it is worth investigating if this is simply due to standard growth or a recent change that has made an unexpected significant impact.

  • When opening Bridge (CS6) I get the following message: "Bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to correct the situation" I tried and after selecting purge cache it does not a

    When opening Bridge (CS6) I get the following message: "Bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to correct the situation" I tried and after selecting purge cache it does not allow me to select OK. Also Bridge keeps saying "Building Criteria" with the spinning wheel and nothing happens. I tried uninstalling and reinstalling to no avail. Please help:)

    Maybe a Preferences reset can help:
    Numerous program settings are stored in the Adobe Bridge preferences file, including display, Adobe Photo Downloader, performance, and file-handling options.
    Restoring preferences returns settings to their defaults and can often correct unusual application behavior.
    Press and hold the Ctrl key (Windows) or the Option key (Mac OS) while starting Adobe Bridge.  
    In the Reset Settings dialog box, select one or more of the following options:  
      Reset Preferences 
    Returns preferences to their factory defaults. Some labels and ratings may be lost. Adobe Bridge creates a new preferences file when it starts.
    Purge Entire Thumbnail Cache
    Purging the thumbnail cache can help if Adobe Bridge is not displaying thumbnails properly. Adobe Bridge re-creates the thumbnail cache when it starts.
    Reset Standard Workspaces
    Returns Adobe predefined workspaces to their factory default configurations.
    Click OK, or click Cancel to open Adobe Bridge without resetting preferences.   

  • My bridge is not working normally and keep given me this message : bridge encountered a problem and is unable to read the cache . Please try purging the central cache in cache preferences to correct the situation

    My bridge is not working normally and keep given me this message : bridge encountered a problem and is unable to read the cache . Please try purging the central cache in cache preferences to correct the situation

    And did you then actually purge the cache?
    Please realize that you have given ZERO details.
    BOILERPLATE TEXT:
    Note that this is boilerplate text.
    If you give complete and detailed information about your setup and the issue at hand,
    such as your platform (Mac or Win),
    exact versions of your OS, of Photoshop (not just "CS6", but something like CS6v.13.0.6) and of Bridge,
    your settings in Photoshop > Preference > Performance
    the type of file you were working on,
    machine specs, such as total installed RAM, scratch file HDs, total available HD space, video card specs, including total VRAM installed,
    what troubleshooting steps you have taken so far,
    what error message(s) you receive,
    if having issues opening raw files also the exact camera make and model that generated them,
    if you're having printing issues, indicate the exact make and model of your printer, paper size, image dimensions in pixels (so many pixels wide by so many pixels high). if going through a RIP, specify that too.
    etc.,
    someone may be able to help you (not necessarily this poster, who is not a Windows user).
    a screen shot of your settings or of the image could be very helpful too.
    Please read this FAQ for advice on how to ask your questions correctly for quicker and better answers:
    http://forums.adobe.com/thread/419981?tstart=0
    Thanks!

  • I have master suite cs6. on mac osx. bridge has been quitting unexpectedly. Also, getting message at start up that states that "bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to corr

    I have master suite cs6. on mac osx. bridge has been quitting unexpectedly. Also, getting message at start up that states that "bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to correct the situation" I have purged the cache several times and adjusted settings with no change. I also downloaded the entire suite and installed. Do I need to uninstall all of the programs before installing the suite? There is not an option to install only Bridge from the install package.

    Maria,
    Topic or subject titles should be clear, pertinent and concise so that individual users can tell at a glance if they can help or not.
    That field is not for attempting to fit your entire question in there.
    Please keep this in mind next time you post.  Thank you.

  • Bridge Freez:  "Bridge encountered a problem and is unable to read the cache.  Please try purgin...'

    Bridge Freez:  "Bridge encountered a problem and is unable to read the cache.  Please try purgin...'

    I've had the same issue for years. I finally found a solution by resetting bridge to factory settings. Here's an article explaining how to fix the bridge cache issue.
    http://easttexashomestead.com/2014/08/adobe-bridge-cache-error-fixed-with-factory-reset/
    How to fix: "Bridge encountered a problem and is unable to read the cache.  Please try purging..."
    I hope this helps!

  • Bridge encountered a problem and is unable to read the cache. Please try specifying a new cache location in Cache Preferences to correct the situation.

    Bridge encountered a problem and is unable to read the cache. Please try specifying a new cache location in Cache Preferences to correct the situation.
    I have do this again and again and again but Bridge ask me to this each time a start up ??

    Maria,
    Topic or subject titles should be clear, pertinent and concise so that individual users can tell at a glance if they can help or not.
    That field is not for attempting to fit your entire question in there.
    Please keep this in mind next time you post.  Thank you.

  • Urgent: Please help: IE5 caching problem

    Hi all,
    I've a web page created by a servlet. Everytime I run this page with different parameters, the prevoius page is getting cached. I've to manually refresh the browser to see the new page.
    This is happening only on IE5 browser.
    I've included the following code in my servlet, but it didn't help.
    response.setDateHeader("Expires",0);
    response.setHeader("Pragma","no-cache");
    response.setHeader("Cache-Control","no-cache");
    <META http-equiv="Cache-Control" content="private, no-cache">
    <META http-equiv="Pragmal" content=" no-cache">
    <META http-equiv="Expires" content=" -1">
    I'm working on JRun 3.1, IIS 5.0.
    How do I prevent my pages from caching?Please help.
    Thanks,
    nkoneru

    Thanks for your reply. I'm aware that this is a IE5 bug, but is there any way I could force my pages to refresh (from the code), irrespective of the browser settings?
    The reason being: there are thousands of customers viewing these pages in IE 5.x, we cannot ask all of them to change their browser settings.
    Please let me know if there's anything else I can do.
    Thank you,
    nkoneru

  • I am facing a caching problem in the Web-Application that I've developed us

    Dear Friends,
    I am facing a caching problem in the Web-Application that I've developed using Java/JSP/Servlet.
    Problem Description: In this application when a hyperlink is clicked it is supposed to go the Handling Servlet and then servlet will fetch the data (using DAO layer) and will store in the session. After this the servlet will forward the request to the view JSP to present the data. The JSP access the object stored in the session and displays the data.
    However, when the link is clicked second time then the request is not received by our servlet and the cached(prev data) page is shown. If we refresh the page then request come to the servlet and we get correct data. But as you will also agree that we don't want the users to refresh the page again and again to get the updated data.
    We've included these lines in JSPs also but it does no good:
    <%
    response.setHeader("Expires", "0");
    response.setHeader("Cache-Control" ,"no-cache, must-revalidate");
    response.setHeader("Pragma", "no-cache");
    response.setHeader("Cache-Control","no-store");
    %>
    Request you to please give a solution for the same.
    Thanks & Regards,
    Mohan

    However, when the link is clicked second time then the request is not received by our servlet Impossible mate.. can you show your code. You sure there are no javascript errors ?
    Why dont you just remove your object from the session after displaying the data from it and see if your page "automatically" hits the servlet when the link is clicked.
    cheers..
    S

  • Bridge CS6 cache problem causes freeze

    MacPro early 2008, 10 mb RAM, Apple OSX 10.7.3, CS5 already installed.
    CS6 Beta was working fine until today.
    Now when I open Bridge CS6 I get "Bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to correct the situation."  I then try to purge the cache, but nothing happens and Bridge freezes.
    Worse, I cannot use my keyboard at all or perform any mouse click actions if Bridge is the active window.  I cannot close Bridge.  What I can do is alt/tab to another window, and then Force Close Bridge.
    I have tried restarting the MacPro but this does not solve the problem.
    The problem started earlier today after I re-edited a nef which I had previously edited in ACR 6.  I cancelled all the previous edits first.
    Also, yesterday I installed Little Snitch, which I have now uninstalled.
    There are no CrashReporter logs for the freezing problem.

    How is your disk free space?   When I loaded Bridge CS6 the default option was for 100% preview.  That takes a lot of time and space to build.  Can occupy gigs of space.
    I reset thumbnails to embedded.  Much smaller and faster and for me works just fine.

  • Few days before I brought one iphone 5 by second party and this phone make a unlock but it sometime have a cellular network most of time say no service can u solve this problem please and I put serial number it say this phone is replace can u help me for

    Few days before I brought one iphone 5 by second party and this phone make a unlock but it sometime have a cellular network most of time say no service can u solve this problem please and I put serial number it say this phone is replace can u help me for original serial number....

    If Apple's service database says that your iPhone was replaced, then Apple will no longer provide any service for that phone.
    First, get a new SIM from your cell carrier and see if that corrects the problem. If it does not, try the usual steps for addressing software problems: restart, reset, restore.
    http://support.apple.com/kb/HT1430
    http://support.apple.com/kb/HT1414
    If you try restoring from a backup and that doesn't fix the problem, try restoring to factory settings and, if the problem goes away, then sync back your apps and content. You'll lose the app data and settings, but if the problem is due to a corrupt cache or settings file, restoring to factory settings should cure it.
    If none of that helps, your device may have developed a hardware fault. Again, Apple will provide no service for it, so you will need to pay some independent repair shop to fix your iPhone.
    Regards.

  • Bridge CS6 Cache problem

    Have installed Photoshop CS6 and in using Bridge I get the message "Bridge encountered a problem and is unable to read the cache. Please try purging the central cache in Cache Preferences to correct the situation". If purge the central cache as instructed, on the start up of Bridge I get the same message and are unable to use Bridge.
    I am on a Mac using OSX 10.7.4
    Your help will be appreciated

    "Removing the Cache manual is fast, you only need time to rebuild cache,
    but that is something you can do with one click on the button an let it
    run overnight."  How do I do that?
    The path provided is for a Mac, there should be a similar path for Windows, maybe Curt can provide you this. The principals stay the same, you quit bridge, dump the cache file manual, restart Bridge (builds a new, empty but fresh cache folder) and when you point Bridge to a folder it start building the cache according your settings (ACR, HQ preview etc.)
    If you have a lot of subfolders just select the main folder, use the menu view / show items from subfolders and this means your main folder shows all the content of your subfolders in the content panel.
    This takes a while and according to your amount of files and file size as well as processor speed it can take several hours before it is finished. For best practice start this procedure as 'last of the day', leave your PC on for the night and let Bridge do its job. It takes a lot of resources and time for Bridge to cache so if it is the only task your PC has to do the better it will do it

  • Bridge cache problem! HELP!!

    Every time  I open Bridge I get an error message "Bridge encountered a problem and is unable to read Cache. Please try purging central cache to solve solution."  I have gone to the Edit tab, preference option and purged cache, but no luck. Message still pops up and is not allowing me to work on photos.  Please HELP!!

    Every time  I open Bridge I get an error message "Bridge encountered a problem and is unable to read Cache. Please try purging central cache to solve solution."
    I am using Adobe Bridge CS6 on Windows 8, with Canon 5D Mark III camera.  This issue has begun about two- three weeks ago.  Now, it has begun to intervene where I can't work on photos.  Bridge works too slow and freezes up and  I can't do anything. 
    I have tried fixing it by going to the
    Edit tab
    preference option
    and purged cache
    (several times). But no luck.  Message still pops up every time I open the program.
    Sometimes I get an error message saying Bridge has low memory and I need to restart the program. 
    Has anyone had this problem or know how or where I can find a solution?  I NEED to work on my photos ASAP! Any help will be greatly appreciated.

  • Bridge Cache problem

    Every time  I open Bridge I get an error message "Bridge encountered a problem and is unable to read Cache. Please try purging central cache to solve solution." 
    I am using Adobe Bridge CS6 on Windows 8, with Canon 5D Mark III camera.  This issue has begun about two- three weeks ago.  Now, it has begun to intervene where I can't work on photos.  Bridge works too slow and freezes up and  I can't do anything. 
    I have tried fixing it by going to the
    Edit tab
    preference option
    and purged cache
    (several times). But no luck.  Message still pops up every time I open the program.
    Sometimes I get an error message saying Bridge has low memory and I need to restart the program. 
    Has anyone had this problem or know how or where I can find a solution?  I NEED to work on my photos ASAP! Any help will be greatly appreciated.

    Every time  I open Bridge I get an error message "Bridge encountered a problem and is unable to read Cache. Please try purging central cache to solve solution."
    I am using Adobe Bridge CS6 on Windows 8, with Canon 5D Mark III camera.  This issue has begun about two- three weeks ago.  Now, it has begun to intervene where I can't work on photos.  Bridge works too slow and freezes up and  I can't do anything. 
    I have tried fixing it by going to the
    Edit tab
    preference option
    and purged cache
    (several times). But no luck.  Message still pops up every time I open the program.
    Sometimes I get an error message saying Bridge has low memory and I need to restart the program. 
    Has anyone had this problem or know how or where I can find a solution?  I NEED to work on my photos ASAP! Any help will be greatly appreciated.

  • Ghost Clip? RAM or Cache Problem?

    Here it is. ghost.psd is the source file
    Whta the hell is that? Where this clip come from? this is driving me crazy. always happens AE CS5(only CS5)
    I didn't change anything. ghost.psd just appeared from somewhere. there is no clip there.
    RAM problem? Cache Problem?
    I already formated PC a few times. And re-install CS5 many times. all kind of updates applied.
    please, help me.

    Wow. Thanks anyway. I can't apply it right now. So I will do that when I come back home.
    And let's you know the result.
    Thank you one more~

Maybe you are looking for

  • Can I share music between Mac and iPhone using bluetooth

    While I use Home Sharing to allow my phone and my wife's to access an iTunes library housed on my Macbook Pro, when we travel by air obviously we do not have Wi Fi available. I know I can buy a "Y" cable to connect two sets of earphones to my Mac so

  • How to change the view criteria at run time for af:query

    Hi, I've a usecase where I need to change the view criteria of the af:query at run time. Use case: ======= 1) Consider a check box (Show Emps Under Dept 10) in the query panel when user selects and clicks 'Search' button should show the employees und

  • CS3 FTP Issues in XPSP2

    Recently upgraded to DW CS3 on both my laptop and desktop, both of which were running DW MX2004. Both machines are XP SP2. I have an issue (across all of the hosting firms I use, 1&1, Omnis, etc) where my FTP puts will timeout excessively. I have to

  • SAP customer block table

    Hello, Can someone tell me the table where I can see the SAP customer block ? Thanks. Regards, Rajesh.

  • JAX-WS client error when calling web method

    My JAX-WS client is getting the following error when calling a web method: Exception in thread "main" javax.xml.ws.WebServiceException: No Content-type in the header! I'm using Eclipse as my development environment. I use the CXF facet to generate a