Getting ClassCastException if the QueryResultsCachePolicy is set

hi,
the code down below is executed without any problem if the line:
query.setQueryResultsCachePolicy(....)
is commented out.
ReadAllQuery query = new ReadAllQuery(exampleObject.getClass());
query.useMapClass(TreeMap.class, propertyName);
query.setExampleObject(exampleObject);
query.setQueryByExamplePolicy(policy);
==> query.setQueryResultsCachePolicy(new QueryResultsCachePolicy(new TimeToLiveCacheInvalidationPolicy(60000)));
TreeMap<Serializable, T> result = (TreeMap<Serializable, T>) persistence.getSession().executeQuery(query);
return result;
Uncommenting the same line result ClassCastException:
Caused by: java.lang.ClassCastException: java.util.TreeMap
at oracle.toplink.queryframework.ReadAllQuery.cacheResult(ReadAllQuery.java:213)
at oracle.toplink.internal.descriptors.ObjectBuilder.buildObject(ObjectBuilder.java:441)
at oracle.toplink.internal.descriptors.ObjectBuilder.buildObjectsInto(ObjectBuilder.java:746)
at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.buildObjectsFromRows(DatabaseQueryMechanism.java:170)
at oracle.toplink.queryframework.ReadAllQuery.executeObjectLevelReadQuery(ReadAllQuery.java:477)
at oracle.toplink.queryframework.ObjectLevelReadQuery.executeDatabaseQuery(ObjectLevelReadQuery.java:874)
at oracle.toplink.queryframework.DatabaseQuery.execute(DatabaseQuery.java:671)
at oracle.toplink.queryframework.ObjectLevelReadQuery.execute(ObjectLevelReadQuery.java:835)
at oracle.toplink.queryframework.ReadAllQuery.execute(ReadAllQuery.java:445)
at oracle.toplink.internal.sessions.AbstractSession.internalExecuteQuery(AbstractSession.java:2293)
at oracle.toplink.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1107)
at oracle.toplink.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1091)
at oracle.toplink.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:1050)
I'm using:
TopLink, version: Oracle TopLink - 11g Technology Preview 3 (11.1.1.0.0) (Build 071214)
Could you please tell me what I'm doing wrong
reagrds,

Nope, they are free to do a factory restore, sorry :/
Also most thieves are very clever so will easily find a way around the passcode or will find some way of getting access to the phone.

Similar Messages

  • HT201441 i have bought a second hand iphone 4s which is stilllinked to previous owners itunes ID.I cant get his details off him as he has his money and is blanking me. I can't get anything on the phone after setting up the language.HELP!!

    I cannot activatea second hand iphone 4s as i don't have previous owners itunes ID. I can't get anything on the phone after setting the language as its asking for activation. Please can anyone help ???? Ideally i would like to get it back to factory settings and start afresh but right now i would settle for anything. Should say i only have the phone and charger, no box so no details

    Unfortunately, the only one who can help is the previous owner.  Otherwise you will not be able to activate and use the phone.  Apple can't/won't help you with this either.

  • SP1 does not get installed when the machine is set to Japanese Language, software push through sccm 2012

    Hi,
    Please help me with the below issue, iam trying to deploy Service pack 1 on Windows 7 , 32 Bit OS
    SP1 does not get installed when the machine is set to Japanese Language, software push through sccm 2012 , it does gets installed of installed manually, by remoting into the machine
    also it gets installed through sccm when the machine is set to english language, 
    Thank you
    Tanoj
    OSLM ENGINEER - SCCM 2007 & 2012

    Hi Friends,
    we are deploying the SP1 via SCCM 2012 , and the success rate is around 50 %, its a Light touch installation where user will initiate the installation via Software Center ( Web based )
    i was able to gather few errors , and this are the errors which failed during SP1 Installation 0x800f0828,
    some errors which sccm reports display are 
    11171
    10008
    10021-
    17031 - 
    1602 - User Cancelled installation
    113 - No more internal file identifiers available
    10070 - File handle reference is no longer available
    10050 - A socket operation encountered a dead network
    11170  - The task sequence manager could not successfully complete execution of the task sequence
    i could not find the reason for some of the errors, also i am looking for a fix/woraround if any
    Also i have noticed that in few computers the task seq failed at a place where after the sp1 installation a reboot happens and then PGP BYPASS utility is uninstalled, it did not start the PGP bypass uninstall after reboot
    is there a way to cut short the Task seq and keep it simple ?
    right now its like this 
    1. checking for prerequisite : checks for OS Name and OS version
    2. installs PGP Bootgaurd Bypass
    3. System Restart
    4. Installing Windows 7 Service Pack 1
    5. Final Restart
    6. uninstall PGP Bootgaurd Bypass
    Regards
    Tanoj
    OSLM ENGINEER - SCCM 2007 & 2012

  • Itunes 10.6.1.7 I have 2 sets of playlists the first set displays greyed out lists and does not work The second set is fine. How do I get rid of the non working set of playlists?

    I have 2 sets of playlists in the sidebar of itunes. I have recently upgraded to 10.6.1.7 but this condition remains the same
    The top list refers to greyed out listings and does not function
    The list below works fine
    How do I get rid of the "false" list?

    I think the greyed out playlists must be listed from your device which is set up to mirror your library. Because the device is synced you can't edit content directly on the device. From the top of the left-hand column do you have?
    Library > Music, Movies...
    Store > iTunes Store, iTunes Match...
    Devices > <Your Device> > Music, Movies, and all the other "dummy" lists...
    Genius > Genius, Genius Mixes...
    Playlists > iTunes DJ, and then all your playlist folders and playlists...
    If so then that is perfectly normal when your device is connected, either directly or over wi-fi and you have the lists expanded. Simply click the small triangle to the left of the device name to hide all the playlists.
    tt2

  • How do I get rid of the moderate nat setting on my xbox 360?

    I tried following the link in a previous threads but it doesn't seem to work. I have wrt54g wireless G braodband router. I'm also running on firefox. I want my router to say open not moderate, so I can play Halo with my friend.

    Open routers set up page using http://192.168.1.1 ….you will get username & password screen …leave username blank & under password use admin.
    Click on “applications & gaming” tab…under port range forward use 88 & 3074 ports forwarded for Ip – 192.168.1.50….check enable….click save settings.
    Click on set up look for MTU …make it manual …change the size to 1365
    On X-BOX use static Ip …subnet mask…gateway & DNS numbers as on routers set up page.
    Also configure the wireless settings same as in router.
    Let me know if the connection still shows NAT moderate.

  • Since recent updates, I have noticed that my apps close automatically when I am distracted. In some cases it is time consuming to sign back in and get back to the task I was doing. Is it possible to change a setting so the apps will stay open?

    Since recent updates of iOS, I have noticed when using my iPad that my apps close automatically when I have to leave the room or am otherwise distracted for a few minutes. It is sometimes time consuming to sign back in and get back to the task where i left off. Is there a setting I can change so it will keep the apps open until I am ready to close them? Thanks for your help.

    Did you have this problem before Restoring you iPad?
    If you did then did you restore with a backup. You may have reinstalled something that is conflicting in this back up
    If not then sounds like either something went array with the clean install or a hardware issue.
    I know it's long winded but have you tired a clean install then downloading the apps again?
    PJRS

  • My apple tv 2 says I can't stream music from my iTunes library on my iMac without settng up iTunes Match. I don't want to set up iTunes match. How can I get back to the pre-Match system which let me just use home sharing to stream music from computer to A

    When I click on the Music tab on my Apple TV 2, a message tells me I have to set up iTunes Match to stream music from my iTunes library on my iMac. I don't want to set up and pay for iTunes Match. How can I get back to the pre-Match system which let me just use home sharing to stream music from computer to Aple TV

    Ditto.
    You need to look for your itunes library under Computers and select it, then music.
    Music column is for web based content not local content, just to confuse everyone.
    AC

  • I am running OS10.6.8 and have a mail box duplication. I use gmail and when I open my mail I have both the Apple Mail and another set of boxes for Gmail. Both get all mail and when I delete from one, it deletes from the other. How can I get rid of the dup

    I am running OS10.6.8 and have a mail box duplication. I use gmail and when I open my mail I have both the Apple Mail and another set of boxes for Gmail. Both get all mail and when I delete from one, it deletes from the other. How can I get rid of the dup

    Hi,
    According to your descriptioin, I don't think this is system problem, it should be Intel driver problem. It would be contact Intel to confirm this issue whether this is their driver problem.
    Roger Lu
    TechNet Community Support

  • How do I get all the information to set up an email on my iPhone?

    For example. I'm trying to set up my college email. How do I know what the Host name  for the incoming server and the Outgoing server host name?

    You would get that information from the college IT department. They will provide you with the information you need to set it up. It may be on the college's website, depending on how they may post it. It should say something to the affect of "setting up student email on mobile devices".

  • HT1212 i have a problem, my iphone is disabled and i can not get into it. the power button does not work and the computer i used before i do not have. icloud was not set up on it either. And it will not allow me to connect to my itunes. So what can i do t

    i have read ur forgotten password or device disabled after entering wrong password. iphone is desabled dont have computer i conected it to before and power button is broke so how can i get back into my iphone?

    You will have to restore the phone and set up as New. See: http://support.apple.com/kb/HT1212. The part you need is near the bottom, "If you have never synced your device with iTunes...". You will lose any content that is not backed up in iCloud.

  • My kids set up itune account on my computer and no one remembers the password.  I want to start my own itunes account, but I would like to get some of the music off this account.  Any suggestions?

    my kids set up itune account on my computer years ago and no one remembers the password.  They started new accounts on their macs.   I want to start my own itunes account, but I would like to get some of the music off this account.  Any suggestions?

    The easiest way would probably be to recover the data of the old account and change it to match your current info, after that you can continue to use the account without any problems. To recover your account go to: Apple - My Apple ID
    Alternatively if you want to start a new account do it and then contact iTunes support to see if the y can transfer your purchases (I know of cases on which they have done it)

  • I forgot my password to get inot email on Thunderbird. How do I retrieve the password or set a new one?

    When I ttry to get my email through Thunderbird, it is now asking me for my password, but I have forgotten it, it has been so long since I have been asked for it. How do I retrieve the password, or set a new one?
    YOU CANNOT EMAIL ME MY ANSWER SINCE I CANNOT OPEN MY EMAIL. CALL at 240-305-7128 or email at [email protected]
    == This happened ==
    Every time Firefox opened
    == yesterday

    You need to go to the website of your email provider, only there can you change your password, or let them send you a new one to a different address. Thunderbird can't help you with that.

  • I have a new iPhone 5C, have the sounds alerts set up. But I'm not getting sound alerts for new voicemail, only the red circle on the screen.  How can I make the sound alert work?

    I have a new iPhone 5C, have the sounds alerts set up. But I'm not getting sound alerts for new voicemail, only the red circle on the screen.  How can I make the sound alert work?

    I have had this same problem for weeks now with my 4S.  I just got a new 5S after being extremely frustrated and the same thing - no sounds.  After searching posts all over, I couldn't find a solution. I just told my friend of the issue and he asked "Do you have the Do Not Distrub on?"  I didn't even know such a function existed.  Upon looking that was exactly the issue.
    To resolve, go to Settings> Do Not Disturb> Manual.  If it is green, turn it off.  You will now get phone calls and text alerts.
    This functionality is also on your quick access utility menu (slide up menu).  I assume this is how it was enabled on my phone.
    I will post on other sites since I searched for weeks for this solution and didn't see it anywhere.  Good luck!

  • I keep getting an error message that says "The administrator has set policies to prevent this installation" when I try to install iTunes.  I have tried everything on the website.

    I keep getting an error message that says "The administrator has set policies to prevent this installation" when I try to install iTunes.  I have tried everything on the website.  When i try to remove the components of iTunes I get the same message.  How can I download iTunes?

    Let's try something relatively simple. Download and save a copy of the installer to your hard drive (don't run the install on line and don't start the install just yet):
    http://www.apple.com/itunes/download/
    Now right-click on the iTunesSetup.exe (or iTunes64Setup.exe) that you downloaded and select "Run as administrator".
    Does that go through any better for you?

  • I downloaded the new 4.0..I don't like how everything is set up now. How do I get it back how it was set up on the page? Plus my cache doesn't work now.

    I would like to know how to get it back how it was set up for bookmarks, history etc. I don't like how it is set up now.

    If your library was working on your computer and then popped up empty all of a sudden then this might be what you need...
    Empty/corrupt library after upgrade/crash
    Hopefully it's not been too long since you last upgraded iTunes, in fact if you get an empty/incomplete library immediately after upgrading then with the following steps you shouldn't lose a thing or need to do any further housekeeping. In the Previous iTunes Libraries folder should be a number of dated iTunes Library files. Take the most recent of these and copy it into the iTunes folder. Rename iTunes Library.itl as iTunes Library (Corrupt).itl and then rename the restored file as iTunes Library.itl. Start iTunes. Should all be good, bar any recent additions to or deletions from your library.
    See iTunes Folder Watch for a tool to catch up with any changes since the backup file was created.
    When you get it all working make a backup!
    tt2

Maybe you are looking for

  • Unmatch a PO from a cancelled Invoice

    Hello Gurus, we have a PO whose line is fully matched with an Invoice in AP. but now the invoice is cancelled by the user. Now the user needs to book the PO line for another new invoice. but the po line is not showing available for matching as the to

  • How come some of my "top sites" in safari won't show the pages?

    I had to restore my system and now some of the TOP SITES in safari wont show the pages and only show the black page.  If I click on the black page, it loads the page, but it stays black in top sites.  Any help would be nice thanks

  • How do I create a list which compiles data from all lists on the sharepoint?

    I have many pages to my sharepoint which all have separate task lists. On my overview page I want to create a list so that all the tasks and data inputted into the other task lists on the site are compiled together in one list. This way I have a long

  • Converting from Word to .pdf distorts formatting

    When I convert a Word document to a .pdf, when I have a bulleted list and the first sentence of each bullet is underlined, format gets distorted when I print to .pdf. I've retyped the document from scratch and experimented with a few different fonts

  • Spaces and multiple screens

    Hi, I have a second screen hooked up to my iMac. I would like to set up spaces so that Mail and iCal are always displayed on the second screen as I move through my various spaces. Is that possible? In other words, only my main screen changes, second