Moving to EclipseLink (SessionCustomizer problem)

Hello

I moved from Toplink Essentials to EclipseLink with Tomcat 6.0.18 and I have this problem:

The two uses EclipseLink, I created two web applications. Due to the use of non-jta-datasources, I created two applications JPAEclipseLinkSessionCustomizer as shown here: http://wiki.eclipse.org/EclipseLink/Examples/JPA/Tomcat_Web_Tutorial

When I launch an application, everything works fine. As soon as I launch another application that uses EclipseLink, I got an exception:

Exception [EclipseLink-28014] (Eclipse - 1.1.1.v20090430 persistence Services - r4097): org.eclipse.persistence.exceptions.EntityManagerSetupException
Description of the exception: the Exception was thrown during the processing of property (eclipselink.session.customizer) with the value (hlaseni. JPAEclipseLinkSessionCustomizer).
Inner exception: java.lang.ClassCastException: hlaseni. JPAEclipseLinkSessionCustomizer cannot be cast to org.eclipse.persistence.config.SessionCustomizer

Can anyone help?

Thank you

PERSISTENCE. XML
<? XML version = "1.0" encoding = "UTF-8"? >
< persistence version = "1.0" xmlns = "http://java.sun.com/xml/ns/persistence" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance" xsi: schemaLocation = "http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" >
< name of persistence - unit = "hlaseniPU" transaction-type = "RESOURCE_LOCAL" >
org.eclipse.persistence.jpa.PersistenceProvider < provider > < / provider >
< non-jta-data-source > java: comp/env/jdbc/Hlaseni < / non-jta-data-source >
hlaseni.entity.Zmeny < class > < / class >
< exclude-no classes listed > true < / exclude-no classes listed >
Properties of <>
< name = "eclipselink.session.customizer property" value = "hlaseni. JPAEclipseLinkSessionCustomizer "/ >"
< name = "eclipselink.logging.level property" value = "INFO" / > "
< / properties >
< / persistence - unit >
< / persistence >

CLASS JPAEclipseLinkSessionCustomizer:
package hlaseni;
to import javax.naming.Context;
Import javax.naming.InitialContext;
Import org.eclipse.persistence.config.SessionCustomizer;
Import org.eclipse.persistence.sessions.JNDIConnector;
Import org.eclipse.persistence.sessions.Session;

/ public class JPAEclipseLinkSessionCustomizer implements SessionCustomizer {}
Public Sub customize(Session session) throws Exception {}
JNDIConnector connector = null;
Context context = null;
try {}
context = new world;
If (null! = context) {}
Connector = session.getLogin () .getConnector () (JNDIConnector); Possible EAC
connector.setLookupType (JNDIConnector.STRING_LOOKUP);
System.out.println ("_JPAEclipseLinkSessionCustomizer: set" + connector.getName ());
} else {}
throw new Exception ("_JPAEclipseLinkSessionCustomizer: context is null");
}
} catch (Exception e) {}
e.printStackTrace ();
}
}
}

Pavel,
Hi, our two applcations are different to where eclipselink.jar is located in the catalina classpath tree.
Try mobile eclipselink.jar in your 2nd application plus high in the classpath tree in the tomcat/lib directory.
See
http://wiki.Eclipse.org/EclipseLink/examples/JPA/Tomcat_Web_Tutorial#EclipseLink_JAR_location

T1) is there a reason why you need to distribute a version of eclipselink in your 2nd application - the recommended approach is to use a shared library overall in tomcat/lib unless a particular application needs a specific version of the jar.
Q2) is your first job EclipseLink application use a tomcat/jlib eclipselink.jar (same place as the javax.persistence jar)
Q3) take the source of data of the equation: being able to run your 2nd application very well you using jdbc parameters instead of a non - jta data source, try to replace the datasource property with the properties for a direct connection javax.persistence.jdbc

http://wiki.Eclipse.org/EclipseLink/examples/JPA/Tomcat_Web_Tutorial#Direct_connection_.28RESOURCE_LOCAL.29_Persistence.XML

Thank you
/Michael

Tags: Fusion Middleware

Similar Questions

  • Moving files between disks problem cases

    I followed the instructions to move my Documents to another hard drive. The source was an internal SSD flash drive, the other disc was a typical internal hard drive. I use Windows 7 Professional.

    I do not give the new location a file but simply transferred on the disc, which had other files it contains.

    After moving Outlook stopped working because he could not find the necessary files.

    He wouldn't let me reverse the process until (hopefully), I could remember what was already on my 2nd drive before transfer and delete these files. He then I would reverse the Outlook process so now OK.

    If I follow the correct procedure, why Outlook did stop working and what other damage could cause such a transfer?

    Because although the wording of the utility indicates moving the "My Documents" folder move he actually just the contents of the folder to the new location.

    Assuming that the dialog shows the C:\Users\votre_nom_utilisateur\My Documents path you have two options.

    On the destination drive, create the path where you want the files, use the Browse button to select the new path and then move

    Or (and much simpler) select the current path, remove ONLY the part 'C' and replace it with "D" (if it's the new drive letter) so it reads D:\Users\votre_nom_utilisateur\My Documents and select move. Now, he must create the new path, move the files and folders and update the pointers.

    Make sure that Outlook is not running when you make the change.

  • moving files after computer problems

    The macbook pro that I used for all my homework for a class, died, and now I am forced to transfer files from the hard drive the computer via firewire. I created a website for a class, unfortunately the class is not a class of web, and I don't know much about dreamweaver, just trying to create something simple. However the I don't know that move files outside dreamweaver is a very bad idea, so I am nervous. Is there an easy way to move files without any problem? I am not very practical with the program, so any help would be appreciated. As you can understand, I would like to move the files as soon as possible...

    Copy the folder root DW site and all its contents to a new location.
    Open DW on the new computer. Adjust the site definition to point in the
    newly located root folder. Bada bing, bada boom. You are finished.

    --
    Murray - ICQ 71997575
    Adobe Community Expert
    (If you * MUST * write me, don't don't LAUGH when you do!)
    ==================
    http://www.projectseven.com/go - DW FAQs, tutorials & resources
    http://www.dwfaq.com - DW FAQs, tutorials & resources
    ==================

    "J_Watson" wrote in message
    News:ft6300$1rk$1@forums. Macromedia.com...
    > The macbook pro that I used for all my homework for a class, died, and
    > now, I
    > have to transfer files from the hard drive the computer via firewire. I have
    > was
    > creating a site for a Web class, unfortunately the class is not a website
    > class, and
    > I do not know much about dreamweaver, just trying to create something
    > simple.
    > I know that move files outside dreamweaver, however it is a very bad
    > idea,.
    > so I'm nervous. Y at - it an easy way to move files without any
    > problems?
    > I'm not handy with the program, so any help would be appreciated. As
    > you
    > can understand, I would like to move the files as soon as possible...
    >

  • Moving thin model w / Clones related

    We have 6 thin gold models put in service and have filled the data store that they are on. Long story how it happened. The process that is used is a user of Clones in the workspace using a linked clone and then deploys the machine from there.

    I need to spread thin between other data warehouses provisioned templates so that it does not happen in the future but I understand that if I use the action to consolidate to move one of these models, it will affect all the related clones. Is this correct?

    If so is there another way to move a thin model to a new data store and do not break the linked clones?

    The only other option is to make a copy\clone of the model and moving it, but the problem with that is that it converts the Thin Thick model as we use LM 4.0.2. So if I cloned the model and it converted to thickness is there a way to get Thin again?


    Then I could take these new thin models and spread them out and those that can be used as the 'old' is not deployed.

    Thanks for reading so far and suggestions.

    Option 1: Move an existing model and all the virtual machines:

    SSMove moving (cut and paste) a clone tied together tree between data warehouses.  However, I would like to you to be on Lab Manager 4.0.4 (final version), as it has a few minor improvements to the tool.

    You must also cancel the deployment of all the virtual machines that are related to this.

    Option 2: move the template only via a full consolidation.

    This movement of the model only.  The model gets consolidated to the new data store.  The new virtual machines configured from the model will go to the new data store where the vmdk.

    The previous VMs will always exist and work.  As they are removed, the space will be released on the previous drive.  If all the vmdk related to the orignial tree is removed, then the entire tree will be cleaned.

  • Icons are not displayed properly in Gmail when the zoom level is between 150 and 200%

    Icons in Gmail will not correctly displayed in Firefox at all zoom levels. The problem does not occur in less than 150% zoom levels or levels of zoom to 200% or more. Levels of zoom between (150%) correct icons are not displayed until the mouse passes on their location.

    The attached pictures show screen shots to 140% (OK), 150% (problems shown, before moving the mouse), 150% (problems shown, after moving the mouse), 190% (problems) and 200% (now OK again)

    The problem was not resolved by disabling extensions, go to mode without failure or update Firefox.

    Firefox and extensions/plugins are all fully patched.

    You can try to disable hardware acceleration in Firefox.

    • Tools > Options > advanced > General > Browsing: "use hardware acceleration when available.

    You will need to close and restart Firefox after enabling/disabling this setting.

  • What process is used to move the personal files of AT &amp; T Yahoo to Thunderbird

    I help my cousin put in place his laptop Windows 8.1. She has records in AT & T Yahoo that contain files that she wished to migrate to Thunderbird. I would like to copy its files of Thunderbird, but cannot determine a process.
    I moved her contacts without problem.

    Thunderbird account setting database included only POP for ATT, but you can override that by clicking manual config.

    In the link I provided are these settings
    IMAP imap.mail.att .net 993 smtp.mail.att .net 465 Yes

    Allows you to set up the manual configuration.

  • Portege Z30-A-191 - the cursor starts to move by itself

    Hello. I have a problem with the touchpad: sometimes (but quite often) the cursor starts to move by itself in a diagonal direction. Finally he stops, moving independently, but the problem can resume later. When the problem occurs, the notebook computer becomes unusable.

    I ask a technician here at my work, focus on the problem, and he said that the drivers are up to date.

    Is there any solution for this?

    Can you please do a little test. Remove the driver for the touchpad from the system and check its operation with "standard driver. Please send us comments.

  • Missing files from Yahoo

    I get a message when I try to open my Yahoo Games site. It reads "Windows can not find http:// login.yahoo.com/config/reset_cookies_tokens...and it lists a whole lot more including Messenger." When I click OK it is then up to my counter top. I am able to access my yahoo and everything what it with the exception of the application of games. Is there a way to retrieve this file from a download? I tried everything I know to solve this problem.

    maydoll,
    It seems that it may have moved to a gambling problem, something a little more.  But here are some things you can try if you still experience the problem.

    System File Checker

    Disk error checking
    Mike - Engineer Support Microsoft Answers
    Visit our Microsoft answers feedback Forum and let us know what you think.

  • Unable to second monitor installation

    Original title - display settings are not saved

    I just bought a second monitor.  I want this monitor as an extension of my primary monitor.  When I go to display settings and try to attach the second monitor, check extend the desktop to this monitor and apply, it always comes back to 1 monitor, default settings.  How can I save the new settings?

    Did you install appropriate drivers for the new monitor - if this isn't the case, please get it from the manufacturer of the monitor and install them (even if you've used versions on the disc that came with the monitor, updates that can solve this problem may be available).  The second monitor work at all in any configuration dual monitor?  The second monitor actually works at all - did you see images and screens on this subject?  Are you sure that the second monitor is compatible with the video card, it is attached (some integrated video cards and even additional cards do not have a lot of power and unable to properly run a screen wide and high resolution - and may not work at all or may work only partially or sporadically problems).  I try right here dismiss the possibility that there may be a material, the connection or compatibility issue before moving on to software problems.

    See the following article: http://windows.microsoft.com/en-us/windows-vista/Understanding-multiple-monitors.  If this doesn't resolve the problem, then wait the right for links to see also articles and check as well (and they can also lead to even more).  In the end, you should be able to access all items from Microsoft on setting up, troubleshooting and configuration of two monitors in Vista.  Hopefullly an article will identify you missed a step or point out exactly where is the problem. I suspect that the system is not properly configured to use two monitors and that is why you are having this problem.  I don't think that he "s it does not save the settings (if this can be a symptom) as much as it is that the system doesn't fully recognize it is in dual screen mode - although I don't know why because I don't know what you've done to put in place.

    Here's a simple article on how to setup two monitors-, but I suspect it is perhaps too simplistic to this situation (although it may report a fundamental issue that must be treated):http://www.ehow.com/how_5960696_setup-windows-vista-desktop-computers.html.

    Here is another article on setting up two monitors in Vista: http://www.instructables.com/id/How-to-setup-dual-monitors-with-Microsoft-Vista/.  Note You must press the next button to move from page to page, as it is spread over several pages.

    I hope this helps.

    Good luck!

    Lorien - MCSA/MCSE/network + / has + - if this post solves your problem, please click the 'Mark as answer' or 'Useful' button at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • Impossible to get HP Photosmart C4780 print after recent move

    I recently moved from the France to the Spain.  My 3 year old printer has moved forward so no problems were anticipated, but...

    I uninstalled the printer and then tried to reinstall with the disc.  All goes well until the page "select printer - Add Print queue.  He asked me to launch the Print & Fax system preferences by clicking on the button Print & Fax.  What I've done.  I then clicked on the devices icon in the bar of the browser (where was my printer).  However, he said that I needed to click on the button Add to select the device and then stop the system preferences.

    There is NO button 'Add' on this page.

    If I go on the button continue it says that I did not add a print queue for my device and it will not be printed.

    I went to the HP support to download the latest software and drivers (several times), but after going through the movements tells me "this software is currently unavailable.  Please contact the printer manufacturer for the latest version of the software.  When I go the the website of HP and do what she wants to download the software tells me "software update service is currently not available.  "Please try again later".

    To say that I am frustrated with this is an understatement.  All solutions?

    Here is a link to software for OS x 10.7 Lion software for your printer, it might be the only one that comes close.

    Best regards

    ERICO

  • File access denied: "you must be authorized to perform this action."

    When you try to repair Windows (using the Windows installation disc) starts the repair process set by mistake some files on my data partition, which is not the system drive: folder 'Boot' and the file 'bootmgr. "

    My system disk is c:\ drive and data drive is d:\

    When you try to delete these files, I have the above error, despite the fact that I have all rights to do.

    Any thoughts?

    Thank you

    JAS

    JA

    The startup folder should be placed somewhere other than the OS partition, while the repair has been made.  They are both necessary and moving them can cause problems.  If you continue to remove them, I'd do a backup first.  You could try to remove in safe mode, or try to remove with a 3rd party app called Treesize (by Jam software).  If these two you could take possession of their (google it).  Either the 'system' or the trusted installer currently has the files even though an admin you can not delete them.

  • several monitors, anchored app automatically change screen

    Hello

    I want to describe what looks like a bug - or undocumented - feature I have meet several times.

    I work with 2 monitors (left and right). I use to work mainly on the right monitor, with Mail and Skype on the left.
    I use the Win8 Skype App from the store, anchored on the screen left and Outlook 2010 full screen on the side - so that they share the screen.

    The question is if I activate other apps or passage to the modern user interface to open another application of the RIGHT of the screen (if I have another application to open getting on the upper left corner or activation of the user interface of the bot left corner), Skype is now anchored on the RIGHT screen automatically, forcing me to move back to the left and moved.

    No problem if I have this on the left screen or use the Start button to access the modern user interface. (Start button opens the modern UI on the monitor where the application is grounded - everywhere where I've anchor it)

    There's a config or a workaround or a current patch for it?
    I tend to make the mistake all the time that I'm looking for especially on the right screen. I don't want it to change everything I open the modern user interface to the left or to the right.

    Thank you

    Hi Nicolas,.

    The way he is now, it seems the app moves to some early screen screen is available on. It isn't a work around for this and it seems to work as it should because the app is part of the start screen.

  • Landing Page forms BREAK-APART, even when grouped inside the envelope.

    It has been my intention to keep my entire design as simple as possible Web site portfolio while structuring each landing page gallery a bit differently from the other.

    I am not at all interested to dazzle viewers with a background image of the film or the Parallax scrolling eye candy; No CSS only drop shadows and other - it is not so much about the site as it comes to the work that my presentation is to share with others.

    I am a newbie for Muse - ALTHOUGH I worked with an earlier version of Dreamweaver during the last decade-plus building websites that still works fine on the desktop screens. (SEE http://phoenixlightroomenterprise.com/ AND http://locationswest.com/) These sites seem to same scale relatively well on a phone with a minimum of pinch and zoom required... And just a quick note here: the "Arizona Land Company/REMOTE" site ('locationswest' link) that I designed in 2007/8 was well established before the call to the 'sensitive design' using this old Dreamweaver 2004 application.

    I knew that that many film producers and directors and Production managers were already working on small screen display 1440 x 900 "Macbook" - laptops type of day - -so I developed and built TWO VERSIONS of this Web site, one for laptops (practices to watch while travelling in a motorhome 'production') and the 'Big screen' version for managers who would most probably be sitting in front of a screen "Cinema Display" at them or in their offices.

    It is my reading comprehension as well online that I can scrape upward, looking at all the promo-vids individual for Muse by Adobe and others so excited by its potential for making designers lives more carefree and fulfilling of this Muse has been SPECIFICALLY developed to be creative ("Easy Breezy"), yet simple and intuitive.

    I guess, somehow, I'm just not see it.

    Here is an another short screencast illustrating problems, the challenges I seem unable to cross in Muse.

    It's more of a problem was seen with a widget (him and his team) Developer twisted almost from one day to the next and then uploaded for all users of Muse work with FREE ( WidgetsForMuse). Problem SOLVED by "Vex" and his colleagues; BUT THEN I started to experience problems that I kept, added a text field below the widget on the page I've been designing (SEE this discussion forum > Muse Breakpoint problems within Simple layout ).

    I just want to put my 'Imaging Services' project; produce all my landing pages and related content pages so get on with development on the meeting with new customers and creating new photo illustrations. And, you know? Begin to UNDERSTAND HOW Muse really works! So far I find 'rhyme' or 'reason'... *.

    I hope you guys can help me better understand what I'm doing wrong.

    I am VERY THANKFUL for your time to help me, help each of us struggling with an app that initially seemed like a good idea when I started, emigrated to work with the Dreamweaver more complex. mm

    Hi Michael,

    When I read your post, I started to think it was a way of including spam, as I'm not clear as to exactly what you're asking, (sorry if I'm the evil spam part).

    Looking at the 2 sites that you have accessed to, I see that you are still using tables for layout, which unfortunately does not work well when you generate sensitive page layouts. It is possible that moving to Muse, (similar problems exist when moving to reagents layouts in Dw) will force you to rethink the way the page layouts should work, a concept which causes most of the people who move from the simple adaptation layouts a lot of problems, which will be much more difficult for a person passing of tables layouts css layouts (in dry weight) or how Muse made layouts.

    When you do responsive layouts, (Muse & Dw), it is necessary to have an idea of how the different page layouts will look like, and what sizes of device that you want to use for the page layouts, as it is not simply a case of patterns which flow into each other, but over every provision being an individual design. The old resizing of the browser, as did it with Adaptive presentations is no longer considered a good idea, because it does not give a good impression of how the layout appears actually on the various formats, (smartphone, Tablet, desktop, tv).

    So for you help to better (and better understand the problems you are experiencing), it would be useful if you could give an idea of how you want to different page layouts actually watch and break down your questions to individual problems.

  • When importing duplicate folder

    I recently got a new Macbook Pro 13 "and upgraded to LR 6, I moved my library without problem but when I import photos into a folder LR creates a duplicate outside of the original parent folder folder."  I can't move the photos in the right folder, since technically they are already there! The pictures on my hardrive are in the correct folder, but LR creates just a duplicate folder name?  Help please!

    Hi jonathanb,.

    When you import the image in Lightroom, you must choose the Option 'Add' instead of copy.

    See the screenshot below.

    Let us know if that helps.

    Kind regards

    Mohit

  • You can use SubVar in header data load rule?

    I think it's a 'no '.  We get a data file:

    Jan | FY13. Petty cash | Dept200 | Forecasts | Working | 25.00

    We want to ignore the 6th "fieldwork" and instead load the data that the & subvar Version has the value.   I try it and it does not work but maybe someone thought new a way forward in the DLR?

    Thank you

    Yes you can do it. I found problems when I got it that the last value of multiple values in the header. moving forward fixed my problem to just put in as & variablename or a certain number of members

    & variablename, 'Real', 'nextdim' without the quotes around the variable and the commas between the names of members. You don't mention what version you're on, but I think the oldest supported version is 9.3.1

Maybe you are looking for