Toplink and UUID

If I persist a UUID using toplink that looks like 550e8400-e29b-41d4-a716-446655440000 in java, it is saved in som other format in the database. It starts with ACED....
What format is this? Is there some easy way in sql to convert between these formats? Why is it stored like this instead of 550e8400-e29b-41d4-a716-446655440000? Better indexing?
Thanks,
/Magnus

Could you please explain why this spring config from http://www.oracle.com/technology/products/ias/toplink/preview/how-to/toplink-jpa-spring.html :
<bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
<property name="dataSource" ref="dataSource"/>
<property name="jpaVendorAdapter">
<bean class="org.springframework.orm.jpa.vendor.OracleTopLinkJpaVendorAdapter">
<property name="showSql" value="true"/>
          <property name="databasePlatform" value="oracle.toplink.platform.database.oracle.OraclePlatform"/>
</bean>
</property>
          <property name="jpaProperties">
               <props>
                    <prop key="toplink.weaving">false</prop>
          <prop key="toplink.logging.level">FINEST</prop>
               </props>
          </property>
</bean>
Produces this output:
INFO: Building JPA container EntityManagerFactory for persistence unit 'em'
[TopLink Finest]: 2007.05.30 12:52:35.005--ServerSession(8303462)--Thread(Thread[main,5,main])--property=toplink.weaving; value=false
[TopLink Finest]: 2007.05.30 12:52:35.037--ServerSession(8303462)--Thread(Thread[main,5,main])--property=toplink.orm.throw.exceptions; default value=true
[TopLink Finer]: 2007.05.30 12:52:35.052--ServerSession(8303462)--Thread(Thread[main,5,main])--Searching for default mapping file in file:/C:/Documents%20and%20Settings/maghei/Skrivbord/HibernateFilterDemo/build/
[TopLink Config]: 2007.05.30 12:52:35.224--ServerSession(8303462)--Thread(Thread[main,5,main])--The alias name for the entity class [class se.lantmateriet.ormtest.domain.User] is being defaulted to: User.
[TopLink Config]: 2007.05.30 12:52:35.255--ServerSession(8303462)--Thread(Thread[main,5,main])--The column name for element [protected int se.lantmateriet.ormtest.domain.DomainEntity.id] is being defaulted to: ID.
[TopLink Config]: 2007.05.30 12:52:35.271--ServerSession(8303462)--Thread(Thread[main,5,main])--The column name for element [private java.util.UUID se.lantmateriet.ormtest.domain.DomainEntity.uuid] is being defaulted to: UUID.
[TopLink Config]: 2007.05.30 12:52:35.271--ServerSession(8303462)--Thread(Thread[main,5,main])--The column name for element [private java.lang.String se.lantmateriet.ormtest.domain.User.username] is being defaulted to: USERNAME.
[TopLink Config]: 2007.05.30 12:52:35.271--ServerSession(8303462)--Thread(Thread[main,5,main])--The column name for element [private boolean se.lantmateriet.ormtest.domain.User.activated] is being defaulted to: ACTIVATED.
[TopLink Finest]: 2007.05.30 12:52:35.271--ServerSession(8303462)--Thread(Thread[main,5,main])--property=toplink.weaving.changetracking; default value=false
[TopLink Finest]: 2007.05.30 12:52:35.271--ServerSession(8303462)--Thread(Thread[main,5,main])--property=toplink.weaving.lazy; default value=true
[TopLink Finest]: 2007.05.30 12:52:35.271--ServerSession(8303462)--Thread(Thread[main,5,main])--end predeploying Persistence Unit em; state Predeployed; factoryCount 1
And this config:
<bean id="emTest" class="se.lantmateriet.ormtest.persistence.em.TopLinkEntityManager" factory-method="getEntityManagerFactory">
</bean>
Where TopLinkEntityManager getEntityManagerFactory starts toplink like this:
EntityManagerFactoryProvider entityManagerFactoryProvider = new EntityManagerFactoryProvider();
     entityManagerFactory = entityManagerFactoryProvider.createEntityManagerFactory("em", new HashMap());
and creates this output:
[TopLink Finest]: 2007.05.30 12:52:35.365--ServerSession(14615608)--Thread(Thread[main,5,main])--property=toplink.weaving; value=false
[TopLink Finest]: 2007.05.30 12:52:35.365--ServerSession(14615608)--Thread(Thread[main,5,main])--property=toplink.orm.throw.exceptions; default value=true
[TopLink Finer]: 2007.05.30 12:52:35.365--ServerSession(14615608)--Thread(Thread[main,5,main])--Searching for default mapping file in file:/C:/Documents%20and%20Settings/maghei/Skrivbord/HibernateFilterDemo/build/
[TopLink Config]: 2007.05.30 12:52:35.380--ServerSession(14615608)--Thread(Thread[main,5,main])--The alias name for the entity class [class se.lantmateriet.ormtest.domain.User] is being defaulted to: User.
[TopLink Config]: 2007.05.30 12:52:35.380--ServerSession(14615608)--Thread(Thread[main,5,main])--The column name for element [protected int se.lantmateriet.ormtest.domain.DomainEntity.id] is being defaulted to: ID.
[TopLink Config]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--The column name for element [private java.util.UUID se.lantmateriet.ormtest.domain.DomainEntity.uuid] is being defaulted to: UUID.
[TopLink Warning]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--Ignoring default serialization on element [private java.util.UUID se.lantmateriet.ormtest.domain.DomainEntity.uuid] within entity class [class se.lantmateriet.ormtest.domain.User] since a @Convert is specified.
[TopLink Config]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--The column name for element [private java.lang.String se.lantmateriet.ormtest.domain.User.username] is being defaulted to: USERNAME.
[TopLink Config]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--The column name for element [private boolean se.lantmateriet.ormtest.domain.User.activated] is being defaulted to: ACTIVATED.
[TopLink Finest]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--property=toplink.weaving.changetracking; default value=false
[TopLink Finest]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--property=toplink.weaving.lazy; default value=true
[TopLink Finest]: 2007.05.30 12:52:35.396--ServerSession(14615608)--Thread(Thread[main,5,main])--end predeploying Persistence Unit em; state Predeployed; factoryCount 0
The interesting thing is that the spring setup completely ignores @Converter and @Convert. Why????
Thanks,
/Magnus

Similar Messages

  • Difference between UUID: DocumentID AND UUID:InstanceID

    Hi All,
             This is my first query in this forum. Hope I am into the right location.
              Can anyone please tell me what is the difference between UUID: DocumentID and UUID:InstanceID? AND
               Based on what properties these ID's will be created?
       Your immediate reply is highly appreciated.
      Thanks in advance and Regards,
      Adobe User.

    It appears FAT's and NTFS's UUIDs are not true UUIDs, whatever it means :)
    All Linux filesystems support filesystem UUIDs; FAT and NTFS filesystems don't support true UUIDs, but are still listed in /dev/disk/by-uuid with a unique identifier
    http://wiki.debian.org/Part-UUID#Via_UUIDs
    Also, I'm trying to comprehend how LVM and LUKS fit into the picture... As far as I can tell, they are not filesystems, like ext4 or ntfs. They are transparent containers. The data itself are stored inside these containers. Containers are basically responsible for knowing how to get the data. Therefore, how come LUKS can support LABELs? I thought LABELs are part of a filesystem, aren't they?
    Last edited by x-yuri (2013-06-12 13:20:29)

  • JDeveloper, Toplink, and ADF advice.

    We have application that was completely developed JDeveloper 10.1.3/4 with Toplink, JSF, ADF, and Session Facade; extremely similar to the SRDemo.
    I am want to upgrade to JDeveloper 11g; however, the ADF Faces JSF will be migrated to Apache MyFaces Trinidad.
    1. Why would this be better than migrating to ADF Faces 11g? Pros and cons?
    2. Is Apache MyFaces Trinidad the future of Oracle's ADF?
    3. What would be the best approach for upgrade to Toplink and ADF 11g?
    Thank you.

    1. Why would this be better than migrating to ADF Faces 11g? Pros and cons?It won't be better than using ADF Faces 11g - it is just more feasible for automatic conversion - we can't do automatic conversion from ADF FAces 10.1.3 to ADF Faces 11g since the UI capabilities are so drastically different. We migrate to Trinidad to allow you to combine Trinidad and ADF Faces 11g in the same application. (You can't use ADF Faces 10.1.3 and 11g in the same application).
    2. Is Apache MyFaces Trinidad the future of Oracle's ADF?No. ADF Faces Rich Client is the present and future. Those are based on Trinidad.
    3. What would be the best approach for upgrade to Toplink and ADF 11g?The basic thing to do is open the application in JDeveloper 11g - things should work after the migration.
    Then you can start leveraging new capabilities such as the new ADF Faces 11g UI in new parts of the application.
    You might want to ask on the TopLink forum if they have any specific migration tips.

  • BUG!?! Toplink and XE in Jdev 10g Rel 3 SU4

    Good ... evening/morning ... everyone! :-)
    Trying to follow (teach using) the tutorial on creating an Web App using Toplink
    and ADF Faces. After creating the Map I am getting problems on the Java object
    generation. I get the exception:
    java.lang.NullPointerException
    at oracle.ideimpl.log.TabbedLogManager.getMsgPag (TabbedLogManager.java:101)
    at oracle.toplink.addin.log.POJOGenerationLoggingAdapter.updateTask(POJOGenerationLoggingAdapter.java:42)
    at oracle.toplink.addin.mappingcreation.MappingCreatorImpl.fireTaskUpdated(MappingCreatorImpl.java:1049)
    at oracle.toplink.addin.mappingcreation.MappingCreatorImpl.generateMappedDescriptorsForTables(MappingCreatorImpl.java:231)
    at oracle.toplink.addin.mappingcreation.MappingCreatorImpl.generateMappedDescriptorsForTables(MappingCreatorImpl.java:201)
    at oracle.toplink.addin.wizard.jobgeneration.JobWizard$1.construct(JobWizard.java:401)
    at oracle.ide.util.SwingWorker$1.run(SwingWorker.java:119)
    at java.lang.Thread.run(Thread.java:595)
    and JDev get in a endless loop in the generation progress dialog. The only
    difference from the tutorial setting is XE instead of a full server!
    Hope someone have some hints; just let me know if further details of the setting
    is needed!
    Dan.

    Good ... evening/morning ... everyone! :-)
    Trying to follow (teach using) the tutorial on creating an Web App using Toplink
    and ADF Faces. After creating the Map I am getting problems on the Java object
    generation. I get the exception:
    java.lang.NullPointerException
    at oracle.ideimpl.log.TabbedLogManager.getMsgPag (TabbedLogManager.java:101)
    at oracle.toplink.addin.log.POJOGenerationLoggingAdapter.updateTask(POJOGenerationLoggingAdapter.java:42)
    at oracle.toplink.addin.mappingcreation.MappingCreatorImpl.fireTaskUpdated(MappingCreatorImpl.java:1049)
    at oracle.toplink.addin.mappingcreation.MappingCreatorImpl.generateMappedDescriptorsForTables(MappingCreatorImpl.java:231)
    at oracle.toplink.addin.mappingcreation.MappingCreatorImpl.generateMappedDescriptorsForTables(MappingCreatorImpl.java:201)
    at oracle.toplink.addin.wizard.jobgeneration.JobWizard$1.construct(JobWizard.java:401)
    at oracle.ide.util.SwingWorker$1.run(SwingWorker.java:119)
    at java.lang.Thread.run(Thread.java:595)
    and JDev get in a endless loop in the generation progress dialog. The only
    difference from the tutorial setting is XE instead of a full server!
    Hope someone have some hints; just let me know if further details of the setting
    is needed!
    Dan.

  • Toplink and VPD

    Hi,
    In a three-tier architecture, has anyone successfully implemented VPD in combination with Toplink and a ConnectionPool?
    When all my web-users are connecting to the database with the same (connection pool) credentials, how, when and where do I tell my database who is really logged in (web-user) and thus how to set the specific VPD for that web-user?
    Thanks. I already read another post on this forum mentioning that VPD support would be included in an upcoming release of TopLink.
    Re: toplink and Oracle VPD
    I also heard of a patch to download. Can anyone verify this?

    Just to add an extra question: Is it true that when one is using chained Toplink actions in a request-response cycle that each action will fetch its own connection from the pool and thus for each time a connection is fetched the VPD needs to be set again?
    This in contrast with BC4J, where all actions in a request-response cycle will share the same application module and thus the same connection.
    Bottom line: how to configure Toplink so that for each fetched connection it tells the database: "Hey, its me again, please set the application context (VPD) to my own personal values, so I will only see my own records"?
    . And to clean it up nicely: just before the connection is released to the pool: "Ok, I'm done, please reset the application context, so other users will not be bothered by my context".
    Hard to believe nobody has tried this before.

  • What are the difference between TopLink and TopLink Essentials...?

    What are the difference between TopLink, TopLink Essentials, EclipseLink and TopLink Essentials-GlassFish?
    What is the difference of their functions?
    Edited by: qkc on Nov 21, 2009 10:52 AM

    Difference between TopLink and ToPLink Essentials:
    TopLink Essentials are the reference implementation (RI) of JPA, is an open source effort that is licensed under the Common Development and Distribution License (CDDL) v1.0. It can be freely downloaded and used under the terms of this license agreement. This means, you can only use it for the management of persistence and orm with Java EE and Java SE. The binary distribution of TopLink consist of 2 jars:
    * toplink-essentials-agent.jar: contains Java Persistence API; XML Schemas and TopLink essentials implementation
    * toplink-essentials.jar: contains java agent class requires in a standolane Java SE application
    In addition to TopLink Essentials that makes the JPA implementation alive, Oracle offers its Oracle TopLink product (10.1.3) that contains an earlier preview binary of JPA and also offers developers additional object-relational capabilities, object-XML mapping (JAXB), non-relational mapping using Java 2.0 Connector Architecture (JCA).
    Let's wait other person to answer these questions.

  • Can I implement the ORM task without TopLink and Hibernate?

    Can I implement the ORM (Objest/Relational Mapping) task without TopLink and Hibernate tools?

    Any opinions are welcome.

  • Behaviour of updateObject and writeObject in toplink and eclipse link

    Hi all ,
    Please let us know if there is any difference between updateobject and writeobject being used in toplink and eclipselink.jar ?
    It would be greatly helpful if someone can say the scenarios to use both the objects in eclipselink.jar .
    Thanks in advance.
    Regards
    Mythili

    In general you should not use either of these, but either use JPA, or use the UnitOfWork.
    updateObject and writeObject are only defined in a single user DatabaseSession.
    updateObject will just update the object, it assumes the object exists
    writeObject can either insert or update an object, it first performs a doesExist check to see if an insert or an update should be done.
    James : http://www.eclipselink.org

  • Desktop Conference 2005 includes Java, TopLink and more

    Checkout Desktop Conference 2005 (www.desktopconference2005.org or www.odtug.com) for information on Desktop Conference 2005, the virtual conference webcast sponsored by Oracle, ODTUG, and BIDW SIG of OAUG. It's powered by Oracle's Collaboration Suite Web Conferencing and features all-star presenters and exceptional technical content February 15-17. Since it's virtual, there's no need to travel. All you need is a PC and internet connection.
    Java/J2EE topics include J2EE, Web Services, JSF, Struts, ADF, BPEL, Frameworks, TopLink and more. Java/J2EE experts include Rod Johnson, Bruce Tate, Richard Monson-Haefel, Paul Dorsey, Toon Koppelaars, and Sri Rajan.
    Oracle Java/J2EE experts include Dai Clegg, Duncan Mills, Avrom Faderman, Steven Davelaar, Frank Nimphius, Tugdual Grall, Sue Harper, Jonas Jacobi, Anuj Jain, Stacen Anderson, Katarina Obradovic-Sarkic, and David Shaffer.
    Great keynotes addresses include Oracle's Thomas Kurian, Senior VP, Development OAS. The conference has a lot to offer so I hope you can check it out. Thanks. Maggie Tompkins

    There are several sessions done by the JDeveloper Product Management as well as several sessions done by othre users of JDeveloper. Check out both the Java track and the Oracle track.
    See the detailed agenda here:
    http://www.desktopconference2005.org/03-agenda/index.html
    Can be a nice opportunity to "go" to a conference if your company is on a tight travel budget.

  • TopLink and Stored Procedures

    Hi all
    We are migrating an application made with MS ASP's to a full blown J2EE application using ADF, JSF and toplink, atm we've used the mapping abilities from toplink and have saved lots of work, however i'd like to know if there's aw ay to map the Stored procedures the same way you map the tables. This would be a great time saving routine, if not available we might have to write it but I thought we would ask here first. Any pointers?
    greetings!

    TopLink does fully support invoking stored procedures for any query. It is not available in the graphical mapping editors but is available through the API. Look in the documentation for StoredProcedureCall.
    Doug

  • How to use jta in toplink and stateless session bean EJB 3.0?

    I have an application with techologies jsf,stateless session bean, adf, toplink
    generated by toplink workbench.
    In web side ı want to use two methods in stateless session bean which are updated
    different tables. I call these methods in my page backing bean.
    I also want to JTA in web side. My first methods is done correctly, but second method has an error. I wanto to rollback all transaction.
    How can ı do that? with using JTA in Toplink...

    Yuichi
    Did you manage to solve this?  I'm doing something similar and seeing the same problem, although they're up to 7.3 SP7.
    Any help greatly appreciated.
    Lewis

  • Hot delpoyment with TopLink and Stateless Session Beans

    What is the recommended procedure for making hot deployment of Stateless session beans work with toplink in WLS 7.0sp1 and oc4j (9.0.3)
    My current setup is as follows using WLS 7.0sp1:
    A stateless session bean is accessing toplink enabled persistent java classes via the SessionManager. I'm currently using the class loader of the stateless session bean:
    * Method in stateless session bean
    * Return the TopLink Session (based on the wls stateless session bean demo)
    public Server getSession() {
              return (Server)SessionManager.getManager().getSession("ejb_sessionbean", this.getClass().getClassLoader());
    Everything is working as such. My session bean can read and write the persistent java classes. However if I redeploy the stateless session bean jar file the toplink session is not reinitalized. This means that new settings in the session.xml are not used. I addition I get other errors.
    I'm having toplink on the server classpath. The toplink enabled persistent classes are in the stateless session bean jar file.
    Thanks
    Henrik

    What is the recommended procedure for making hot deployment of Stateless session beans work with toplink in WLS 7.0sp1 and oc4j (9.0.3)
    Everything is working as such. My session bean can read and write the persistent java classes. However if I redeploy the stateless session bean jar file the toplink session is not reinitalized. This means that new settings in the session.xml are not used. I addition I get other errors.
    I'm having toplink on the server classpath. The toplink enabled persistent classes are in the stateless session bean jar file.Henrik,
    This is a recent post note I found on the same topic:
    It all hinges on whether the TopLink ServerSession class has
    been loaded by a classloader which is actually thrown away
    during the hot deployment process. If this is the case, then
    hot deployment causes the ServerSession to go out of scope
    and finalize methods take care of logging it out properly.
    If you deploy your TopLink Project on the Sytem class path then
    it definately won't work. You'd have to restart the server every time.
    But if the TopLink Project is deployed inside of an .ear file
    and if you pass the correct ClassLoader to the
    SessionManager.getSession( .... ) call then TopLink Session will
    be re-started when you hot deploy the .earBased on this, the solution might be to deploy your EJBs in an ear file. Everything else looks OK. Can you try this and let us know?
    Thanks,
    Pete Farkas

  • TopLink and 9iAS/OC4J 9.0.2

    We are working on project that have
    to work with 9iAS/OC4J 9.0.2, upgrade
    to OC4J 9.0.3 in NOT an option.
    Our J2EE application will only use
    Servlets/JSP (NO EJBs), we need
    to do O/R mapping from Servlets to db.
    How can we install / use TopLink (9.0.3
    or earlier version) from 9iAS/OC4J 9.0.2 ?
    Regards, Radomir.

    Hi Radomir,
    This shouldn't be a problem, the easiest way to set things up would be to place the TopLink.jar file in the \j2ee\home\lib folder of OC4J v9.0.2. If there is something specific that you would like answered in terms of application deployment or setup and configurations, just ask.
    Darren Melanson

  • TopLink and Java 1.4

    Does TopLink support Java 1.4? If not, does anybody know when this is planned? Thanks.

    There were some bugs in the 1.4.0 JDK that appear to be fixed in 1.4.1. I know of customers and our field staff are using 1.4.1 successfully. It is not "officially" supported but known to work, and I am under the impression that 1it will be officially supported in the 9.0.4 release scheduled in the first half of 03.
    - Don
    Does TopLink support Java 1.4? If not, does anybody know when this is planned? Thanks.

  • EJB3 and/or Toplink and setting context for VPD

    We are looking at moving to the latest version of jdeveloper and taking advantage of the ejb3 and/or toplink features for the model part of applications. I have a question on how to set the vpd context using this new model. Currently we use:
    Jdeveloper 10.1.2.1
    Oracle application server 10g R2 Enterprise Edition ver 10.1.2.0.2
    OracleOCI driver
    Oracle 9i database
    Our database access is in regular java beans where we get a connection from the pool , set the context for the current user (by running a stored procedure on the connection) perform the required data access and then release the connection. It looks like when you use Toplink or EJBs with CMP the database access is out of the developer's control. How will I be able to set the context for each connection ( it's different for each user) once I move to the new model?

    Thank you. That looks like exactly what I need, at least for toplink. I have been told though, that since we are deploying to the OC4J container and it will manage persistence and since EJB 3 simplifies the creation of entity beans that we should use EJB 3 entity beans and a session facade for the model and not add toplink as it would be an extra layer we don't really need , would you agree?

Maybe you are looking for