Xdoclets with Kodo 4.1.4
I want to migrate from Kodo 3.0.3 tod 4.1.4, which means that I change to JDO 2.0
I have my business objects created with a generator that works fine with JDO 1.0 doclet parsing.
But using the jdoclet task with the jdo spec 2.0 leads, when enhancing, to the following warning (ANT task):
[mappingtool] 14:44:21,574 [ INFO] openjpa.MetaData - The metadata for "com.oepag.kdms.common.domain.DateiTypDomain" declares the "persistence-capable-superclass" attribute. This attribute is no longer used. Ignoring.
The DateiTypDomain looks as follows:
* DateiTypDomain
* @jdo.persistence-capable persistence-capable-superclass="com.framework.common.ndomain.AbstractDomain" identity-type="application" objectid-class="com.framework.common.ndomain.AbstractDomain$AbstractDomainID"
public final class DateiTypDomain extends AbstractDomain
The AbstractDomain looks as follows:
* @jdo.persistence-capable identity-type="application"
* objectid-class="com.framework.common.ndomain.AbstractDomain$AbstractDomainID"
* @jdo.class-vendor-extension vendor-name="kodo" key="data-cache"
* value="full-cache"
public abstract class AbstractDomain implements NDomain, Comparable
The recreation of the database tables indicates that the mapping strategies (here flat mapping) were not interpreted well.
My question: Do I have to change the doclets created in the classes, and if how or do I also have to create the mapping files (jdo) with my generator to create JDO 2.0 standard
If the same exact app and code works with 4.0 with the same ForeignKeyDeleteAction setting, I suggest that you open a case with support.
This property hasn't changed since 4.0
http://e-docs.bea.com/kodo/docs41/full/html/ref_guide_mapping_defaults.html
Laurent
Similar Messages
-
GenerationType.AUTO doesn't work correctly with Kodo and MySQL
Greetings,
I'm migrating applications from JBoss/Hibernate to WebLogic/Kodo. The following column annotation:
@Id
@Column(name="CUSTOMER_ID")
@GeneratedValue(strategy = GenerationType.AUTO)
public long getCustomerId()
is supposed to generate auto-increment primary key in mysql. This is what happens with Hibernate. With Kodo, this seems to be equivalent with GenerationType.TABLE as a table named openjpa_sequence_table is created, containing sequence values. So what should one do in order to be able to use true auto-increment strategy with MySQL and Kodo ?
Many thanks in advance,
NicolasHi Nicolas,
By setting the generation strategy to AUTO, you're essentially letting the JPA provider choose which strategy to use. It looks like Kodo is using the TABLE strategy by default and Hibernate is using the IDENTITY strategy here. You can set the strategy to IDENTITY if you want Kodo to behave similarly to Hibernate. However, it's worth pointing out that there may be a reason for Kodo not using the IDENTITY strategy by default.
The docs at: http://edocs.bea.com/wls/docs103/kodo/full/html/ref_guide_pc_oid.html#ref_guide_pc_oid_pkgen_autoinc
point out the following:
"Statements inserting into tables with auto-increment / identity columns cannot be batched. After each insert, Kodo must go back to the database to retrieve the last inserted auto-increment value to set back in the persistent object. This can have a negative impact on performance. "
- Matt -
How can I use the ScrollTablePane with kodo ?
How can I use the ScrollTablePane with kodo, taking a result Query as
a Collection and throw it into the ScrollTablePane , if it not possible ,
Is there a Component which I can do it ?
Thanks , Marco Aurelio.Marco-
I am not familiar with any "TableScrollPane" classes. Can you clarify
whether this is some 3rd party custom component, or something you have
written?
Note that we do not provide any pre-build graphical data components with
Kodo, but we do intend to provide some examples in the future.
In article <cl1hn7$9ep$[email protected]>, Marco Aurelio Bueno wrote:
>
How can I use the TableScrollPane with kodo, taking a result Query as
a Collection and throw it into the ScrollTablePane , if it not possible ,
Is there a Component which I can do it ?
Thanks , Marco Aurelio.--
Marc Prud'hommeaux
SolarMetric Inc. -
How can I use the TableScrollPane with kodo
How can I use the TableScrollPane with kodo, taking a result Query as
a Collection and throw it into the ScrollTablePane , if it not possible ,
Is there a Component which I can do it ?
Thanks , Marco Aurelio.Marco-
I am not familiar with any "TableScrollPane" classes. Can you clarify
whether this is some 3rd party custom component, or something you have
written?
Note that we do not provide any pre-build graphical data components with
Kodo, but we do intend to provide some examples in the future.
In article <cl1hn7$9ep$[email protected]>, Marco Aurelio Bueno wrote:
>
How can I use the TableScrollPane with kodo, taking a result Query as
a Collection and throw it into the ScrollTablePane , if it not possible ,
Is there a Component which I can do it ?
Thanks , Marco Aurelio.--
Marc Prud'hommeaux
SolarMetric Inc. -
What's the Best Open Source DB for use with Kodo?
Hi everyone,
In terms of ease of setup and use, tools to view info in the database, and least difficulty in
running with Kodo, what is the best open source database to use? I'm use to using Oracle and
SQLPlus. I need to use an open source DB for a learning environment, and I'd like your informed
opinion.
Thanks,
David EzzioI have been using postgresql 7.1 with Kodo for a while with mostly positive results, and currently
have it deployed with Kodo 2.2.3. I prefer it to mysql because its feature set is a little richer,
and supports transactions natively. My experience with mysql (without jdo - I haven't tried it with)
is good, but there were little things missing in mysql 3.x, e.g. the ability do do a join in a
DELETE statement.
BTW, there are some severe problems somewhere in the 2.2.4 release with postgresql if you intend to
eventually deploy on it. It also apparently has some problems invoking postgresql's indices, making
it a little less than optimal. But as a learning environment, it's what I'd recommend.
-Mike
Marc Prud'hommeaux wrote:
David-
Here is the rundown of the databases I have experience with:
MySQL: Fairly simple to install (especially if you run Debian Linux), but
configuration, especially adding users, can be a pain. A separate open
source project called "mysql-navigator" makes it fairly easy to do
simple queries, inserts, etc. In most of my tests it outperforms
PostgreSQL, but your mileage will vary. It has a sane CLI that supports
modern features like line history, etc (unlike the horrific SQLPlus).
PostgreSQL: People often say that it is a more "academically
correct" database than MySQL. I've also found it to be quite a bit
easier to set up. Their GUI (called "pgaccess") is simplistic, but does
most things you need. Has a CLI similiar to MySQL's.
HypersonicSQL: By far the easiest to set up (just drop the jar in your
CLASSPATH), but is java only, can be rather slow, and has no GUI tools
available that I know of (except various free vanilla-JDBC GUI tools).
We feel that Kodo works quite well with all these DBs. The MySQL JDBC
driver seems a bit less buggy than Postgres', but their transaction
support is very recent and not very well tested. If I had to pick one or
the other, I would probably go with MySQL.
David Ezzio <[email protected]> wrote:
Hi everyone,
In terms of ease of setup and use, tools to view info in the database, and least difficulty in
running with Kodo, what is the best open source database to use? I'm use to using Oracle and
SQLPlus. I need to use an open source DB for a learning environment, and I'd like your informed
opinion.
Thanks,
David Ezzio--
Marc Prud'hommeaux [email protected]
SolarMetric Inc. http://www.solarmetric.com
Kodo Java Data Objects Full featured JDO: eliminate the SQL from your code--
Mike Bridge -
ForeignKeyDeleteAction=null not working with Kodo 4.1.2 and Mysql 5
Hello,
i am trying to use Kodo 4.1.2, together with mysql 5.0
my kodo.properties says:
openjpa.jdbc.MappingDefaults: jdo(ForeignKeyDeleteAction=null)
and i am expecting an sql-statement something like:
ALTER TABLE mytable ADD FOREIGN KEY (bar) REFERENCES othertable(foo) ON DELETE SET NULL;
but all i got is:
ALTER TABLE mytable ADD FOREIGN KEY (bar) REFERENCES othertable(foo);
Kodo 4.0 didn't have any problems with that. Also, in Kodo 4.1.2 other ForeignKeyDeleteActions (like 'cascade' oder 'default') are working like expected.
What am i doing wrong? Where can i find some upgrade instructions? Is this a bug?
Thanks in advance,
MarkusIf the same exact app and code works with 4.0 with the same ForeignKeyDeleteAction setting, I suggest that you open a case with support.
This property hasn't changed since 4.0
http://e-docs.bea.com/kodo/docs41/full/html/ref_guide_mapping_defaults.html
Laurent -
Using Tangosol Coherence in conjunction with Kodo JDO for distributing caching
JDO currently has a perception problem in terms of performance. Transparent
persistence is perceived to have a significant performance overhead compared
to hand-coded JDBC. That was certainly true a while ago, when the first JDO
implementations were evaluated. They typically performed about half as well
and with higher resource requirements. No doubt JDO vendors have closed that
gap by caching PreparedStatements, queries, data, and by using other
optimizations.
Aside from the ease of programming through transparent persistence, I
believe that using JDO in conjunction with distributed caching techniques in
a J2EE managed environment has the opportunity to transparently give
scalability, performance, and availability improvements that would otherwise
be much more difficult to realize through other persistence techniques.
In particular, it looks like Tangosol is doing a lot of good work in the
area of distributed caching for J2EE. For example, executing parallelized
searches in a cluster is a capability that is pretty unique and potentially
very valuable to many applications. It would appear to me to be a lot of
synergy between Kodo JDO and Tangosol Coherence. Using Coherence as an
implementation of Kodo JDO's distributed cache would be a natural desire for
enterprise applications that have J2EE clustering requirements for high
scalability, performance, and availability.
I'm wondering if Solarmetric has any ideas or plans for closer integration
(e.g., pluggability) of Tangosol Coherence into Kodo JDO. This is just my
personal opinion, but I think a partnership between your two organizations
to do this integration would be mutually advantageous, and it would
potentially be very attractive to your customers.
BenMarc,
Thanks for pointing that out. That is truly excellent!
Ben
"Marc Prud'hommeaux" <[email protected]> wrote in message
news:[email protected]...
Ben-
We do currently have a plug-in for backing our data cache with a
Tangosol cache.
See: http://docs.solarmetric.com/manual.html#datastore_cache_config
In article <[email protected]>, Ben Eng wrote:
JDO currently has a perception problem in terms of performance.
Transparent
persistence is perceived to have a significant performance overheadcompared
to hand-coded JDBC. That was certainly true a while ago, when the firstJDO
implementations were evaluated. They typically performed about half aswell
and with higher resource requirements. No doubt JDO vendors have closedthat
gap by caching PreparedStatements, queries, data, and by using other
optimizations.
Aside from the ease of programming through transparent persistence, I
believe that using JDO in conjunction with distributed cachingtechniques in
a J2EE managed environment has the opportunity to transparently give
scalability, performance, and availability improvements that wouldotherwise
be much more difficult to realize through other persistence techniques.
In particular, it looks like Tangosol is doing a lot of good work in the
area of distributed caching for J2EE. For example, executingparallelized
searches in a cluster is a capability that is pretty unique andpotentially
very valuable to many applications. It would appear to me to be a lot of
synergy between Kodo JDO and Tangosol Coherence. Using Coherence as an
implementation of Kodo JDO's distributed cache would be a natural desirefor
enterprise applications that have J2EE clustering requirements for high
scalability, performance, and availability.
I'm wondering if Solarmetric has any ideas or plans for closerintegration
(e.g., pluggability) of Tangosol Coherence into Kodo JDO. This is justmy
personal opinion, but I think a partnership between your twoorganizations
to do this integration would be mutually advantageous, and it would
potentially be very attractive to your customers.
Ben--
Marc Prud'hommeaux [email protected]
SolarMetric Inc. http://www.solarmetric.com -
MANIFEST.MF included with kodo-persistence.rar
The MANIFEST.MF included with the kodo-persistence.rar in kodo 4.1.1 has only info about "JDO" and not "JPA". Was it incorrectly packaged? Is there another kodo-persistence.rar that can be downloaded for JCA? Here are the contents of the MANIFEST.MF in kodo-4.1.1/jca/persistence/META-INF/kodo-persistence.rar
Premain-Class: kodo.enhance.PCEnhancerAgent
Main-Class: kodo.enhance.PCEnhancer
Built-By: BEA Systems, Inc.
Implementation-Vendor: BEA Systems, Inc.
Implementation-Version: 4.1.1
OpenTools-UI: kodo.jdbc.integration.jbuilder.KodoTools
OpenTools-Build: kodo.jdbc.integration.jbuilder.KodoBuilder
OpenIDE-Module: kodo.jdbc.integration.netbeans/1
OpenIDE-Module-Name: Kodo
OpenIDE-Module-Short-Description: Kodo for SunOne-NetBeans
OpenIDE-Module-Install: kodo/jdbc/integration/netbeans/KodoModule.class
OpenIDE-Module-Module-Dependencies: org.netbeans.modules.java/1 > 1.7
OpenIDE-Module-Layer: kodo/jdbc/integration/netbeans/kodo-layer.xml
Name: kodo/
Specification-Title: Java Data Objects
Specification-Vendor: Sun
Implementation-Vendor: BEA Systems, Inc.
Specification-Version: 2.0.0
Implementation-Version: 4.1.1
Implementation-Title: kodo
Name: kodo/jdbc/integration/netbeans/KodoMenuAction.class
OpenIDE-Module-Class: Action
Name: kodo/jdbc/integration/netbeans/MappingDataLoader.class
OpenIDE-Module-Class: Loader
Install-Before: org.openide.loaders.XMLDataObject, org.netbeans.module
s.xml.core.XMLDataObject
Name: kodo/jdbc/integration/netbeans/JDODataLoader.class
OpenIDE-Module-Class: Loader
Install-Before: org.openide.loaders.XMLDataObject, org.netbeans.module
s.xml.core.XMLDataObjectThe manifest should be seen only as a file that can contain information about the files packaged in a JAR file. There is no requirement to contain information about all the files packaged in the jar.
You are using the correct rar file.
Laurent -
Tranaction with KODO JCA and DAO
Hi,Abe,
I use KODO JCA with JBoss3.2.1.We encounter some problem with transaction.We use CMT(Container Management Transaction)provider by JBoss EJB container.
the seniario is:
public class SessBeanA iimplements SessionBean{
public void method(){
A a_new A();
a.method1();
B b_new B();
b.method2();
public class A{ _
method1(){
//use KODO jdo insert one record. _
public class B{
method2(){
//use DAO query the record insert.
method() inSessBeanA is configued use CMT and start new tranction when called.
We want to keep a.method1() and b.method2() in same transaction(method1() and method2() use transaction created by method()).but unfortunately,as they use different DB connection instance(one is from KODO JDO JCA,the other is from direct JDBC),they didn't keep in same transaction.so b.method2() can't find the record insert by a.method1() because method1() hasn't commit.
you know,as for complexity,we can't use only KODO for insert/query,we had to use other technology like DAO.Would you pls tell us how to keep KODO JDO call and our DAO call in same transaction?
Regards,
geduoConsider getting a database connection from Kodo using JDBCStoreManager,
i.e.
KodoPersistenceManager.getStoreManager().getConnection() or
KodoPersistenceManager.getConnection() I think.
Then you'll get the same connection Kodo is using and hence the same
transaction associated with it.
Alex.
geduo wrote:
This is a multi-part message in MIME format.
------=_NextPart_000_001D_01C3CF8B.2D85C0D0
Content-Type: text/plain;
charset="gb2312"
Content-Transfer-Encoding: quoted-printable
Hi,Abe,
I use KODO JCA with JBoss3.2.1.We encounter some problem with =
transaction.We use CMT(Container Management Transaction)provider by =
JBoss EJB container.
the seniario is:
public class SessBeanA iimplements SessionBean{
public void method(){
A a=3Dnew A();
a.method1();
B b=3Dnew B();
b.method2();
public class A{ =20
method1(){
//use KODO jdo insert one record. =20
public class B{
method2(){
//use DAO query the record insert.
method() inSessBeanA is configued use CMT and start new tranction when =
called.
We want to keep a.method1() and b.method2() in same =
transaction(method1() and method2() use transaction created by =
method()).but unfortunately,as they use different DB connection =
instance(one is from KODO JDO JCA,the other is from direct JDBC),they =
didn't keep in same transaction.so b.method2() can't find the record =
insert by a.method1() because method1() hasn't commit.
you know,as for complexity,we can't use only KODO for insert/query,we =
had to use other technology like DAO.Would you pls tell us how to keep =
KODO JDO call and our DAO call in same transaction?
Regards,
geduo
------=_NextPart_000_001D_01C3CF8B.2D85C0D0
Content-Type: text/html;
charset="gb2312"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; charset=3Dgb2312">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV>
<DIV><FONT face=3DArial size=3D2>Hi,Abe,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I use KODO JCA with JBoss3.2.1.We =
encounter some=20
problem with transaction.We use CMT(Container Management =
Transaction)provider by=20
JBoss EJB container.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>the seniario is:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV>
<DIV><FONT face=3DArial size=3D2>public class SessBeanA iimplements=20
SessionBean{</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> public void=20
method(){</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> A =
a=3Dnew=20
A();</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> =20
a.method1();</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> B =
b=3Dnew=20
B();</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> =20
b.method2();</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> }</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV></DIV>
<DIV><FONT face=3DArial size=3D2>public class A{ =
</FONT></DIV>
<DIV>
<DIV><FONT face=3DArial size=3D2> =
method1(){</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> =
//use KODO=20
jdo insert one record. </FONT></DIV></DIV>
<DIV><FONT face=3DArial size=3D2> }</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>public class B{</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> =
method2(){</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> =
//use DAO=20
query the record insert.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2> }</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>method() inSessBeanA is configued =
use CMT and=20
start new tranction when called.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>We want to keep a.method1() and =
b.method2() in same=20
transaction(<STRONG>method1() and method2() use transaction =
created</STRONG>=20
<STRONG>by method()).</STRONG>but unfortunately,as they use different DB =
connection instance(one is from KODO JDO JCA,the other is from direct =
JDBC),they=20
didn't keep in same transaction.so b.method2() can't find the record =
insert by=20
a.method1() because method1() hasn't commit.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>you know,as for complexity,we can't use =
only KODO=20
for insert/query,we had to use other technology like DAO.Would you pls =
tell us=20
how to keep KODO JDO call and our DAO call in same =
transaction?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Regards,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>geduo</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV></DIV></BODY></HTML>
------=_NextPart_000_001D_01C3CF8B.2D85C0D0-- -
Exception running enhancement with Kodo 3.x metadata
156 INFO [main] kodo.Tool - Enhancer running on type "class
com.peacetech.dts.jdo.TemplateContentImpl".
Exception in thread "main" java.lang.NoSuchMethodError:
kodo.meta.AbstractMetaDataFactory.access$001(Lkodo/jdo/Deprecate
dJDOMetaDataFactory;)Lkodo/meta/MetaDataRepository;
at
kodo.jdo.DeprecatedJDOMetaDataFactory$ExtensionTranslatingParser.<init>(DeprecatedJDOMetaDataFactory.java:238
at
kodo.jdo.DeprecatedJDOMetaDataFactory.newParser(DeprecatedJDOMetaDataFactory.java:113)
at kodo.jdo.JDOMetaDataFactory.getParser(JDOMetaDataFactory.java:86)
at kodo.jdo.JDOMetaDataFactory.load(JDOMetaDataFactory.java:117)
at
kodo.meta.MetaDataRepository.getMetaDataInternal(MetaDataRepository.java:432)
at
kodo.meta.MetaDataRepository.getMetaData(MetaDataRepository.java:274)
at kodo.enhance.PCEnhancer.<init>(PCEnhancer.java:113)
at kodo.enhance.PCEnhancer.run(PCEnhancer.java:3806)
at kodo.enhance.PCEnhancer.run(PCEnhancer.java:3754)
at kodo.enhance.PCEnhancer.main(PCEnhancer.java:3720)Hi Abe,
Great to have you back on this newsgroups. If release of 4.1 is expected
within next couple of months we would rather wait with migration
Thank you
Alex
<Abe White> wrote in message news:[email protected]..
I believe this is a known bug. If this is a blocking problem, please
contact support and request a patch. Tell them it's CR 285141. -
Getting Weblogic to work with Kodo
Hi,
Based on the documentation found here
http://docs.solarmetric.com/j2ee_tutorial_jca_installation.html#j2ee_tutorial_generic
I had created a startup class, with changes to the default JNDI name and
added an import line of javax.jdo.*
I also had to place kodo-jdo-runtime.jar and jdo-1.0.1.jar into the
classpath of the weblogic server to have it loaded by Weblogic without
class not found errors.
The new problem now while loading Weblogic server is as follows
Failed to invoke startup class "WLS_JNDI_BIND",
javax.jdo.JDOFatalUserException : Exception thown by
getPersistenceManagerFactory(Properties)
NestedThrowables:
java.lang.reflect.InvocationTargetException
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at WS_JNDI_Bind.startup(WLS_JNDI_Bind.java:55)
....etc
Please advice.Tan,
JCA is by far the preferred method of deploying into an appserver (in
fact spec perscribed). The configuration is straightforward (in WL,
just unjar, edit your classpath appropriately and edit ra.xml). Code
changes are minimal, mostly involving removing transactional code if
using managed transactions and looking up via JNDI via a static factory.
See the J2EE tutorial. Also read the section on XA DataSources as
most Weblogic defined datasources are managed as well.
Also, Kodo's datasource includes a wide range of performance features
and flexibilty which may or may not be exposed in WebLogic's datasource.
Tan wrote:
Up till now, we have been connecting our apps to DB servers using kodo
through jdbc drivers and for some operations, using direct jdbc connection
without jdo. We decided that this should change to a 3 tier architecture
with weblogic as middle tier to reduce the burden on our applications and
to harness the advantages provided by weblogic.
As you may have guess, the transition would be best done with minimal
changes to code and configuration.
Correct me if i am mistaken here : After reading through the
documentation,
the impression gained was that deploying through startup class is a much
more straight forward operation with only minor code changes required for
getting the persistencefactorymanager and the persistencemanager. On the
server side, only a startup class needs to be deployed.
As for JCA, it seems to be a relatively new technology applied in this
context. Although detailed information was given on how to deploy it on
weblogic, little documentation was provided on its operation and its
effects on the client applications using kodo (Eg: the changes required)
and the implications that may arise using this technology. Can anyone fill
me in on this, or point me to a kodo documentation that might explain
things better?
As a matter of fact, both the methods will be tried out eventually. I am
making a fact list of both methods before making the decision on which
method to use.
Please advice.
Tan
Patrick Linskey wrote:
FYI, I think it's more common to deploy Kodo into Weblogic via JCA, not
via a startup class, as described at:
http://docs.solarmetric.com/j2ee_tutorial_jca_installation.html#j2ee_tutorial_weblogic
Is there any reason why you're using a startup class instead of JCA
deployment?
-Patrick
Steve Kim
[email protected]
SolarMetric Inc.
http://www.solarmetric.com -
Running JDO 1.0 TCK suite with Kodo 2.3.1
Hi folks,
to get a picture of Kodo 2.3.1 JDO 1.0 compliance I tried to run the TCK
and got a security exception when the PeristenceManagerFactoy is created
(see below). Is there a way to prevent the DefaultConfiguration accessing
the system properties or make the TCK test harness install a different
security manager? I can run a single test case of the suite via the main
method (But that would be tedious to do for all test cases of the test
suite.).
Here's the security exception text:
Executing command via 127.0.0.1,port=3974,localport=1907
Assertion A10.4-2 (AccessingFieldsInPredelete) unexpected exception
javax.jdo.JDOFatalUserException: Exception thrown by
getPersistenceManagerFactory(Properties)
NestedThrowables:
java.lang.reflect.InvocationTargetException
javax.jdo.JDOFatalUserException: Exception thrown by
getPersistenceManagerFactory(Properties)
NestedThrowables:
java.lang.reflect.InvocationTargetException
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at com.sun.jdotck.JDO_Test.getPMF(JDO_Test.java:202)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run2(AccessingFieldsInPredelete.java:116)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run(AccessingFieldsInPredelete.java:103)
at
com.sun.javatest.lib.ExecStdTestSameJVMCmd.run(ExecStdTestSameJVMCmd.java:104)
at com.sun.javatest.agent.Agent$Task.executeCommand(Agent.java:826)
at com.sun.javatest.agent.Agent$Task.execute(Agent.java:757)
at com.sun.javatest.agent.Agent$Task.handleRequest(Agent.java:615)
at com.sun.javatest.agent.Agent.handleRequestsUntilClosed(Agent.java:384)
at com.sun.javatest.agent.Agent.access$0(Agent.java:362)
at com.sun.javatest.agent.Agent$1.run(Agent.java:262)
at java.lang.Thread.run(Thread.java:484)
NestedThrowablesStackTrace:
java.lang.reflect.InvocationTargetException: java.lang.SecurityException:
Action forbidden by JavaTest: checkPropertiesAccess
at
com.sun.javatest.JavaTestSecurityManager.checkPropertiesAccess(JavaTestSecurityManager.java:97)
at java.lang.System.getProperties(System.java:488)
at
com.solarmetric.kodo.conf.DefaultConfiguration.loadProperties(DefaultConfiguration.java:92)
at
com.solarmetric.kodo.conf.DefaultConfiguration.loadDefaults(DefaultConfiguration.java:55)
at
com.solarmetric.kodo.conf.SimpleConfiguration.<init>(SimpleConfiguration.java:82)
at
com.solarmetric.kodo.conf.SimpleConfiguration.<init>(SimpleConfiguration.java:69)
at
com.solarmetric.kodo.impl.jdbc.JDBCSimpleConfiguration.<init>(JDBCSimpleConfiguration.java:53)
at
com.solarmetric.kodo.impl.jdbc.JDBCPersistenceManagerFactory.getPersistenceManagerFactory(JDBCPersistenceManagerFactory.java:54)
at java.lang.reflect.Method.invoke(Native Method)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at com.sun.jdotck.JDO_Test.getPMF(JDO_Test.java:202)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run2(AccessingFieldsInPredelete.java:116)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run(AccessingFieldsInPredelete.java:103)
at
com.sun.javatest.lib.ExecStdTestSameJVMCmd.run(ExecStdTestSameJVMCmd.java:104)
at com.sun.javatest.agent.Agent$Task.executeCommand(Agent.java:826)
at com.sun.javatest.agent.Agent$Task.execute(Agent.java:757)
at com.sun.javatest.agent.Agent$Task.handleRequest(Agent.java:615)
at com.sun.javatest.agent.Agent.handleRequestsUntilClosed(Agent.java:384)
at com.sun.javatest.agent.Agent.access$0(Agent.java:362)
at com.sun.javatest.agent.Agent$1.run(Agent.java:262)
at java.lang.Thread.run(Thread.java:484)Christian-
We use out own junit to javatest adaptor to run the TCK, which is
why we never identified this problem. Version 2.3.2 (which will
be released very soon) will catch SecurityExceptions when trying
to do System.getProperties(), so you should be able to run it in
Sun's javatest harness.
In the meantime, you should be able to run it by doing one of the
following:
1. Specifying the property javatest.security.noSecurityManager=true
when running javatest, or
2. Set javatest.security.allowPropertiesAccess=true
In article <[email protected]>, Christian Huter wrote:
Hi folks,
to get a picture of Kodo 2.3.1 JDO 1.0 compliance I tried to run the TCK
and got a security exception when the PeristenceManagerFactoy is created
(see below). Is there a way to prevent the DefaultConfiguration accessing
the system properties or make the TCK test harness install a different
security manager? I can run a single test case of the suite via the main
method (But that would be tedious to do for all test cases of the test
suite.).
Here's the security exception text:
Executing command via 127.0.0.1,port=3974,localport=1907
Assertion A10.4-2 (AccessingFieldsInPredelete) unexpected exception
javax.jdo.JDOFatalUserException: Exception thrown by
getPersistenceManagerFactory(Properties)
NestedThrowables:
java.lang.reflect.InvocationTargetException
javax.jdo.JDOFatalUserException: Exception thrown by
getPersistenceManagerFactory(Properties)
NestedThrowables:
java.lang.reflect.InvocationTargetException
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at com.sun.jdotck.JDO_Test.getPMF(JDO_Test.java:202)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run2(AccessingFieldsInPredelete.java:116)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run(AccessingFieldsInPredelete.java:103)
at
com.sun.javatest.lib.ExecStdTestSameJVMCmd.run(ExecStdTestSameJVMCmd.java:104)
at com.sun.javatest.agent.Agent$Task.executeCommand(Agent.java:826)
at com.sun.javatest.agent.Agent$Task.execute(Agent.java:757)
at com.sun.javatest.agent.Agent$Task.handleRequest(Agent.java:615)
at com.sun.javatest.agent.Agent.handleRequestsUntilClosed(Agent.java:384)
at com.sun.javatest.agent.Agent.access$0(Agent.java:362)
at com.sun.javatest.agent.Agent$1.run(Agent.java:262)
at java.lang.Thread.run(Thread.java:484)
NestedThrowablesStackTrace:
java.lang.reflect.InvocationTargetException: java.lang.SecurityException:
Action forbidden by JavaTest: checkPropertiesAccess
at
com.sun.javatest.JavaTestSecurityManager.checkPropertiesAccess(JavaTestSecurityManager.java:97)
at java.lang.System.getProperties(System.java:488)
at
com.solarmetric.kodo.conf.DefaultConfiguration.loadProperties(DefaultConfiguration.java:92)
at
com.solarmetric.kodo.conf.DefaultConfiguration.loadDefaults(DefaultConfiguration.java:55)
at
com.solarmetric.kodo.conf.SimpleConfiguration.<init>(SimpleConfiguration.java:82)
at
com.solarmetric.kodo.conf.SimpleConfiguration.<init>(SimpleConfiguration.java:69)
at
com.solarmetric.kodo.impl.jdbc.JDBCSimpleConfiguration.<init>(JDBCSimpleConfiguration.java:53)
at
com.solarmetric.kodo.impl.jdbc.JDBCPersistenceManagerFactory.getPersistenceManagerFactory(JDBCPersistenceManagerFactory.java:54)
at java.lang.reflect.Method.invoke(Native Method)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(Unknown Source)
at com.sun.jdotck.JDO_Test.getPMF(JDO_Test.java:202)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run2(AccessingFieldsInPredelete.java:116)
at
com.sun.jdotck.api.instancecallbacks.AccessingFieldsInPredelete.run(AccessingFieldsInPredelete.java:103)
at
com.sun.javatest.lib.ExecStdTestSameJVMCmd.run(ExecStdTestSameJVMCmd.java:104)
at com.sun.javatest.agent.Agent$Task.executeCommand(Agent.java:826)
at com.sun.javatest.agent.Agent$Task.execute(Agent.java:757)
at com.sun.javatest.agent.Agent$Task.handleRequest(Agent.java:615)
at com.sun.javatest.agent.Agent.handleRequestsUntilClosed(Agent.java:384)
at com.sun.javatest.agent.Agent.access$0(Agent.java:362)
at com.sun.javatest.agent.Agent$1.run(Agent.java:262)
at java.lang.Thread.run(Thread.java:484)
Marc Prud'hommeaux [email protected]
SolarMetric Inc. http://www.solarmetric.com
Kodo Java Data Objects Full featured JDO: eliminate the SQL from your code -
Hello!
I have been using kodo 4.1.2 as my backend for a long time now without touching it.
I did some work on my maven repository recently, and I am no longer able to use the cached version of openjpa due to this problem:
[INFO]
[ERROR] BUILD ERROR
[INFO]
[INFO] Failed to resolve artifact.
GroupId: org.apache.openjpa
ArtifactId: openjpa
Version: 0.9.5-incubating
Reason: Unable to download the artifact from any repository
org.apache.openjpa:openjpa:pom:0.9.5-incubating
When I check out the openjpa site, this version is not there.
If I try any more recent version, including 0.9.6-incubating, I get this error during my build:
java.lang.NoSuchFieldError: brokerPlugin
This happens when I run the kodo.ant.PCEnhancerTask.
Note that openjpa 0.9.5 is no longer available.
Can anybody suggest how I can fix the brokerPlugin problem?
Thank you!
=DavidMy apologies. Since the Kodo traffic is minimal on this forum I typically ping the team to look at posted issues and missed this one. I will get someone to look at this today.
Doug -
Kodo 2.4 integration with IBM WSAD (IBM)
I am using WSAD (IBM/eclipse) 4.0.3. with Kodo 2.4. I have kodo installed,
but whenever I
attempt to use it I get the following error.... I appears that KODO can't
find the workbenchSite,
I have checked the KODO install and it does list the org/eclipse/ui in its
needed files....and I have
verfiied that the ui directory is present and that workbenchsite is present
in the jar.
I get this error whenever I try to use any of the features on Kodo menu....
Log: Fri Dec 13 12:22:03 CST 2002
1 org.eclipse.core.resources 4 Unhandled exception caught in event loop.
Log: Fri Dec 13 12:22:03 CST 2002
4 org.eclipse.ui 0 org/eclipse/ui/IWorkbenchSite
java.lang.NoClassDefFoundError: org/eclipse/ui/IWorkbenchSite
at
com.solarmetric.modules.integration.eclipse.AbstractAction.getView(AbstractA
ction.java:31)
at
com.solarmetric.modules.integration.eclipse.AbstractMetadataAction.run(Abstr
actMetadataAction.java:44)
at org.eclipse.ui.internal.PluginAction.run(PluginAction.java:125)
at
org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(Action
ContributionItem.java:407)
at
org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionCont
ributionItem.java:361)
at
org.eclipse.jface.action.ActionContributionItem.access$0(ActionContributionI
tem.java:352)
at
org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(A
ctionContributionItem.java:47)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled
Code))
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled
Code))
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled
Code))
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled
Code))
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled
Code))
at org.eclipse.ui.internal.Workbench.run(Workbench.java:656)
at
org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.jav
a:815)
at org.eclipse.core.boot.BootLoader.run(BootLoader.java:285)
at java.lang.reflect.Method.invoke(Native Method)
at org.eclipse.core.launcher.Main.basicRun(Main.java:151)
at org.eclipse.core.launcher.Main.run(Main.java:442)
at org.eclipse.core.launcher.Main.main(Main.java:315)It appears that in our released version, a different compiler broke our
Eclipse 1.0 support (and for apps based on Eclipse 1.0 such as WSAD 4).
We will get this resolved before the next patch release.
Sorry for any inconvenience this may have caused.
Brian Smith wrote:
Here is the list of files in the solarmetrics.... directory:
list of files in the com.solarmetric.kodo_0.9.0
xml-apis.jar
xercesImpl.jar
xalan.jar
serp_license.txt
serp.jar
plugin.xml
plugin.properties
log4j-1.2.6.jar
kodo-reverse-schema.jar
kodo-jdo-runtime.jar
kodoJDO.library
jta-spec1_0_1.jar
jndi.jar
jdo1_0.jar
jdbc-hsql-1_7_0.jar
jdbc2_0-stdext.jar
jca1.0.jar
jakarta-commons-logging-1.0.2.jar
hypersonic_license.txt
classes12.zip
icons folder
"Brian Smith" <[email protected]> wrote in message
news:[email protected]...
We are running NT 4 for the OS
Yes, this except is from the .log file, the screen just a message that Ihad
an error with the UI (subsystem) and I had to find the .log file to get
something meaningful.
I still don't have a great idea what the root cause of the problem is.
I will get a list of the files in kodo subdirectory when I get intomorrow,
I followed the
directions and copied all of the KODO-JDO-2.4.0 jar files there, but Iwill
get the exact
set for you.
Brian
"Steve Kim" <[email protected]> wrote in message
news:[email protected]...
What OS are you running on? Is this from the .log or from the screen?
If the latter, could you send us the applicable portion of the IDE log
(its $your_eclipse_directory/workspace/.metadata/.log)?
Could you also post a list of the files in your
$your_eclipse_dir/plugins/com.solarmetric.kodo_0.9.0 durectory?
Brian Smith wrote:
I am using WSAD (IBM/eclipse) 4.0.3. with Kodo 2.4. I have kodo
installed,
but whenever I
attempt to use it I get the following error.... I appears that KODOcan't
find the workbenchSite,
I have checked the KODO install and it does list the org/eclipse/ui inits
needed files....and I have
verfiied that the ui directory is present and that workbenchsite ispresent
in the jar.
I get this error whenever I try to use any of the features on Kodomenu....
Log: Fri Dec 13 12:22:03 CST 2002
1 org.eclipse.core.resources 4 Unhandled exception caught in event
loop.
Log: Fri Dec 13 12:22:03 CST 2002
4 org.eclipse.ui 0 org/eclipse/ui/IWorkbenchSite
java.lang.NoClassDefFoundError: org/eclipse/ui/IWorkbenchSite
at
com.solarmetric.modules.integration.eclipse.AbstractAction.getView(AbstractA
ction.java:31)
at
com.solarmetric.modules.integration.eclipse.AbstractMetadataAction.run(Abstr
actMetadataAction.java:44)
at org.eclipse.ui.internal.PluginAction.run(PluginAction.java:125)
at
org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(Action
ContributionItem.java:407)
at
org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionCont
ributionItem.java:361)
at
org.eclipse.jface.action.ActionContributionItem.access$0(ActionContributionI
tem.java:352)
at
org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(A
ctionContributionItem.java:47)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled
Code))
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled
Code))
atorg.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled
Code))
at
org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled
Code))
atorg.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled
Code))
at org.eclipse.ui.internal.Workbench.run(Workbench.java:656)
at
org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.jav
a:815)
at org.eclipse.core.boot.BootLoader.run(BootLoader.java:285)
at java.lang.reflect.Method.invoke(Native Method)
at org.eclipse.core.launcher.Main.basicRun(Main.java:151)
at org.eclipse.core.launcher.Main.run(Main.java:442)
at org.eclipse.core.launcher.Main.main(Main.java:315) -
How to specify table name using xdoclet
Hi
I'm trying to specify a table name using xdoclet 1.2.
I've tried the @sql.table, but that ain't working (no table mapping name is
writen to the *.jdo)
I've tried using the @jdo.class-vendor-extension with key=table and
value=tablename, but that ain't working either.
I guess number two approach ain't working because kodo want table name
extension inside another extension like this:
<extension vendor-name="kodo" key="jdbc-class-map" value="base">
<extension vendor-name="kodo" key="table" value="tablename"/>
</extension>
But, how do I specify the above using xdoclet?
Regards
JesperOk.
Is it possible somehow to just tell kodo to use another table name without
having to create mapping extensions for collections and stuff. Even better
if one could specify a table name prefix to be used on all tables.
My problem is that I need use kodo on an existing database having tables
names that conflict with kodo's auto-generated tables names. The schematool
will then try alter these tables :-(
Regards
Jesper
"Stephen Kim" <[email protected]> wrote in message
news:[email protected]...
When you use metadata mapping extensions, you should not generate
.mapping files as all that info is stored in the .jdo file. You should
instead set kodo.jdbc.MappingFactory to metadata.
Jesper Ladegaard wrote:
Thanks.
However, I still can't get it to work.
I've created a java class named Role with xdoclet like this:
* @jdo.persistence-capable
* @jdo.class-vendor-extension
* vendor-name="kodo" key="jdbc-class-map" value="base"
* @jdo.class-vendor-extension
* vendor-name="kodo" key="jdbc-class-map/table" value="BW_ROLE"
* @jdo.class-vendor-extension
* vendor-name="kodo" key="jdbc-class-map/pk-column" value="JDOID"
Xdoclet generates a jdo file like this:
<jdo>
<package name="dk.pine.users.services.model">
<class name="Role"
identity-type="datastore"
<!-- end class tag --><extension vendor-name="kodo"
key="jdbc-class-map"
value="base">
</extension>
<extension vendor-name="kodo"
key="jdbc-class-map/table"
value="BW_ROLE">
</extension>
<extension vendor-name="kodo"
key="jdbc-class-map/pk-column"
value="JDOID">
</extension>
<field name="users"
default-fetch-group="true"
<!-- end field tag --><collection
element-type="dk.pine.users.services.model.User"
embedded-element="false"
<!-- end collection tag --></collection>
<extension vendor-name="kodo"
key="inverse-owner"
value="roles">
</extension>
</field>
</class>
</package>
</jdo>
Now I run the mappingtool (with option refresh) and it generates a
mapping
file like this:
<mapping>
<package name="dk.pine.users.services.model">
<class name="Role">
<jdbc-class-map type="base" pk-column="JDOID"
table="dbo.ROLE0"/>
<jdbc-version-ind type="version-number"column="JDOVERSION"/>
<jdbc-class-ind type="in-class-name" column="JDOCLASS"/>
<field name="description">
<jdbc-field-map type="value" column="DESCRIPTION"/>
</field>
<field name="name">
<jdbc-field-map type="value" column="NAME0"/>
</field>
<field name="systemRole">
<jdbc-field-map type="value" column="SYSTEMROLE"/>
</field>
<field name="users">
<jdbc-field-map type="many-many"
element-column.JDOID="JDOID" ref-column.JDOID="ROLES_JDOID"
table="dbo.USER0_ROLES"/>
</field>
</class>
</package>
</mapping>
I expected it to create a BW_ROLE, but it create a ROLE0 table????
"Stephen Kim" <[email protected]> wrote in message
news:[email protected]...
You can use slashes to denote sub extensions.
See the example near the bottom of this link:
http://solarmetric.com/Software/Documentation/3.0.3/docs/ref_guide_integrati
on_xdoclet.html
Jesper Ladegaard wrote:
Hi
I'm trying to specify a table name using xdoclet 1.2.
I've tried the @sql.table, but that ain't working (no table mapping
name
>>
is
writen to the *.jdo)
I've tried using the @jdo.class-vendor-extension with key=table and
value=tablename, but that ain't working either.
I guess number two approach ain't working because kodo want table name
extension inside another extension like this:
<extension vendor-name="kodo" key="jdbc-class-map" value="base">
<extension vendor-name="kodo" key="table" value="tablename"/>
</extension>
But, how do I specify the above using xdoclet?
Regards
Jesper
Steve Kim
[email protected]
SolarMetric Inc.
http://www.solarmetric.com
Steve Kim
[email protected]
SolarMetric Inc.
http://www.solarmetric.com
Maybe you are looking for
-
Report for invoices project wise
Hello All, I need a report where I can see the invoices project wise i.e (PS module and SD module) I am looking for invoices details project wise is there any standard report which I can check that how many invoices have been raised for a particular
-
PO created in SRM not showing in ERP
Dear All; We are using SRM7, classic scenario. The buyer converted a SC to PO then deleted it in ERP. The SC appeared again in SoCo He created another PO but it did not get transfeered to ERP. In Related document of the SC, it shows the Deleted PO w
-
Please explain to me what the "red alert symbol" means within the Family Base Alert Messages. Also, is there a way to see the text message details posted to my child's phone through my Family Base account? Or is that only possible by physically tak
-
Problem viewing pdf in print mode
I am able to download and view pdf files, but when I go to print them I sometimes get a file that looks like the correct pdf file but there is no text in the file. It has the formatting correct, but the text is absent. I am using Mac OS 10.6.8, Firef
-
Hiiiiiiiiiiiiiiii Experts, I have a problem.When I am attaching material to an activity , it is taking base unit of measure which has been defined in material master as default.In case of stock item as item category it allows me to change the unit.B