rect way
than 4.1.1 was?
Luckily we have pretty good test coverage on this and I am happy to fix those
wrong "To Dep PK"s in our model, but this might be something to look out for
for others as well.
Regards,
Tore Halset.
me, the benefit of the upgrade would be to clean up the code
> and start using the new style. So you might start by running search/replace
> on the constructor, and then clean up the rest by hand.
>
> Andrus
>
>
>> On Jul 4, 2022, at 11:15 PM, Tore Halset wrote
project.
% find . -type f -name \*java -exec grep -H new\ SelectQuery {} \;|wc -l
546
Regards,
Tore Halset,
On 6. feb. 2013, at 00:11, Aristedes Maniatis a...@maniatis.org wrote:
option 1: change the serial number when the classes change in some way: you
get InvalidClassException. Your code can catch this and invalidate the
session.
option 2: don't change the serial number and hope that Java
might lead to
java.io.InvalidClassException ... local class incompatible error.
So, what is best practice for serializing CDOs across changes to the class?
Regards,
Tore Halset.
();
extendedTypes.registerType(new ColorType());
extendedTypes.registerType(new WKTGeometryType(Geometry.class));
Btw, you should use 3.1B instead of 3.1M as B is newer.
Regards,
Tore Halset.
On Sep 17, 2012, at 02:11 , Juan José Gil wrote:
Hi,
I'm trying to use 3.1M3 version and I've noted
();
Andrus
On Aug 23, 2012, at 12:22 PM, Tore Halset wrote:
Hello.
I am playing with serialization of cayenne objects in trunk. This is the
first time I do (java) serialization of cayenne stuff. On deserialize I get
the following.
org.apache.cayenne.CayenneRuntimeException: [v.3.2M1
)
at org.apache.cayenne.Cayenne.objectForPK(Cayenne.java:383)
It looks like I should do a CayenneRuntime.bindThreadInjector(Injector), but
how should I create the Injector?
Regards,
Tore Halset.
mature jdbc
drivers lack full support of, so my guess is that you will have to work on that
first.
Good luck and keep us up to date! :)
Btw, anyone done something similar with OrientDB or Cassandra (CQL)?
Regards,
Tore Halset.
[1] http://cayenne.apache.org/running-unit-tests.html
On 14. aug
Hello.
I use the migrate-stuff during startup of my application. However, I have a
filter that only exectutes non-destructive merge-tokens. That is, I only
executes CreateTableToDb, AddColumnToDb, AddRelationshipToDb,
SetValueForNullToDb and SetColumnTypeToDb that expand the maxLength. I have
Hello.
On Sep 10, 2010, at 00:21 , Eric Lazarus wrote:
We are using cayenne 3.0M6 and Tomcat 6.0.20. (We used to use Cayenne 1.1 and
Tomcat 4.0.6 without this issue showing up.)
The problem occurs when we access one of the web apps then the other, in
either order. If you access the first
Hello.
I am deleting some rows via jdbc and want to update the cayenne stack with that
information. After issuing ctxt.invalidateObjects(...) the cayenne objects for
the deleted rows still have persistence state comitted. Is there a better trick
than invalidateObjects(...)?
- Tore.
:27 , Tore Halset wrote:
Hello.
I am deleting some rows via jdbc and want to update the cayenne stack with
that information. After issuing ctxt.invalidateObjects(...) the cayenne
objects for the deleted rows still have persistence state comitted. Is there
a better trick than
Well, processSnapshotChanges did not solve the problem either. I am now doing
deleteObjects() after deleting them via plain jdbc. It is not pretty, but works
well as long as the objects are in state COMITTED.
- Tore.
On Jun 7, 2010, at 12:27, Tore Halset wrote:
Hello.
This one seem
Hello.
I tried to implement support for streaming blobs back in 2006. Sorry, but it
never got completed. I still think it is a nice feature. If you want to work on
this issue, you might want to take a look at streaming_blob_try2.zip from
https://issues.apache.org/jira/browse/CAY-316
Regards,
Hello.
It is hard to tell where the memory problems are without looking at
the actual used memory. I normally use jmap to dump memory info and
then jhat on a different computer to analyze the dump.
jmap -dump:live,file=filename pid
jhat -J-Xmx10G filename
Depending on your heap size, jhat
Hello.
The cayenne way is like this:
ObjectContext ctxt =
Pessoa p = (Pessoa) ctxt.newObject(PessoaFisica.class);
p.setName(Gilberto);
p.setDateOfBirth(Date.valueOf(2009-01-01));
ctxt.commitChanges();
It seem strange at the beginning, but there are lots of benefits with
the context
This has been discussed a lot on java-...@lists.apple.com . It is a
bug with the latest update. If I remember correctly, it happens on
menues that are changed.
- Tore.
On Jul 9, 2009, at 9:11 , Andrus Adamchik wrote:
I can reproduce that too, and also I see other smaller differences
in
On Apr 8, 2009, at 3:28 , Aristedes Maniatis wrote:
On 08/04/2009, at 11:03 AM, Joseph Schmidt wrote:
* write the record to database, fetch it back again and
then you'll have the primary key
Than this is not the same transaction :(.
Correct. This is a limitation of how databases work, not
Hello.
That should be fine for read only web site. For web sites/pages where
the user will edit and save objects, I find it safer to use a single
ObjectContext pr request. With a session-shared ObjectContext, you can
get into some of the following situations:
1. A context with validation
Hello.
The new merge functionality in the modeler was created to handle this.
Firebird is not supported, but please try it out and report any problem.
- Tore.
On Dec 29, 2008, at 23:07, John Armstrong siber...@gmail.com wrote:
Hi everyone,
My database (Firebird) does not support boolean
Hello.
On 7. okt.. 2008, at 18.37, Pierre Lavignotte wrote:
Thanks Scott.
I didn't find this in the mail archive...
Do you mean define an entity WITHOUT the BLOB fields, and another,
pointing
on the same table, WITH ONLY the BLOB fields ?
I guess it will work but I thought there was a
On Sep 26, 2008, at 9:12 , Øyvind Harboe wrote:
Is there any way I can tell Cayenne to fail(throw exception) if it is
not able to enumerate the tables?
The jdbc driver/database did not return those tables in the list of
tables. You can try for your self with some simple jdbc code.
-
Hello.
The merger get the table info using DbLoader that does a
jdbcConnection.getMetaData().getTables() to pick up info on all the
tables. My guess is that the database/jdbc-driver simply does not list
the tables for your misconfigured user.
- Tore.
On Sep 25, 2008, at 9:32 , Øyvind
Thanks. I removed the cast.
- Tore.
On Sep 25, 2008, at 19:00, Scott Anderson wrote:
That method is defined in the DbAdapter interface; you don't need to
cast it. See MySQLMergerFactory (post CAY-1108 patch) for an example.
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL
On Aug 28, 2008, at 19:34, Scott Anderson wrote:
It looks like the DbMerger in 3.0M4 isn't properly detecting whether
NULL is allowed for columns when using MySQL. Is this another issue
that
has already been fixed in trunk?
I do not remember. Can you try with the latest build?
On Aug 28, 2008, at 21:03, Scott Anderson wrote:
Is it possible to detect this via jdbc?
A rather long-winded way to detect table type is:
SHOW CREATE TABLE [table name];
This will return the full CREATE TABLE instruction required to rebuild
that table. If this is already how you determine
Hello.
(This is related to merging)
Another option to solve the same would be to create a
AbstractToDbToken.mayRemoveInformation() that all ToDb tokens will
have to implement? Need to find a better name. What do you think?
Regards,
- Tore.
On Aug 27, 2008, at 8:25 , Øyvind Harboe wrote:
Hello.
Done.
https://issues.apache.org/cayenne/browse/CAY-1100
http://svn.apache.org/viewvc?view=revrevision=689594
Regards,
- Tore.
On Aug 27, 2008, at 08:25, Øyvind Harboe wrote:
I need to figure out if a change to the database would cause data
loss.
E.g. a user might *increase* the
Hello.
The modeler does this to be able to display the sql before executing
it. Create a subclass of MergerContext and override its
executeSql(String).
- Tore.
On Aug 26, 2008, at 9:51 , Øyvind Harboe wrote:
The merge stuff can produce some pretty wicked stuff.
However, I would like
On Aug 26, 2008, at 22:39, Scott Anderson wrote:
Moving this to the list, since it maybe useful to others-
I have been poking around, and I think I've figured out how to use it.
If I use DbGenerator, everything works great, but if I try to merge in
changes from a slightly out of sync schema
Hello.
There are still some things missing from the merge-package to be able
to create a complete database from scratch. Like the ability to
correctly order the tables that are to be created. However, I use
merging a lot more than generating.
Regards,
- Tore.
On Aug 22, 2008, at 10:53,
On Aug 22, 2008, at 13:36, Andrus Adamchik wrote:
Interesting... I am not using either for anything complex lately,
preferring manual SQL scripts executed with dbpatch Ant task, so I
am a bit out of the loop.
The sql-scripts is a very solid way to work, but some people would
probably
in the map.xml file.
Suggestions?
Thanks in advance.
--
Tìoraidh!
Rick Blair
Associate Technical Fellow
Boeing Phantom Works
Network Systems Technology
Information Management Program
M/S: 42-50
Voice: (206) 544-1610
From: Tore Halset [EMAIL PROTECTED]
Reply-To: user@cayenne.apache.org
Date
On 13. juni. 2008, at 17.33, Elena Doyle wrote:
How can I configure SSL in DomeinNode.driver.xml. Can somebody give
me an example.
Do you mean SSL connection between your cayenne based application and
the database? If so, this is a jdbc setup issue. Please take a look at
your jdbc
On 19. mai. 2008, at 09.20, Martin Thelian wrote:
thank you for the hints. I'll try the patch. Are there any pitfalls
when
using this patch?
No pitfalls that I have found. It solved the problem for us. We used
it in production for some time before we moved to a 3.0 milestone that
had
On 6. mai. 2008, at 17.43, Eric Polino wrote:
We were using derby and have decided to switch to postgresql. I have
changed all my adapters and drivers and they seem to be working
properly. I'm getting issues when I try to run my initialization
script that has always worked before.
What
On 30. april. 2008, at 17.08, Andrus Adamchik wrote:
IIRC Tore added boolean constant parsing to 3.0 some time ago. I
could be wrong of course. Are you on 2.0.x?
That was true/false as an expression element, not as a value. See jira
for examples.
Hello.
Perhaps not that related, but you might want to take a look at JSR-310
that tries to solve problems with the current java.util.Date co. You
should be able to create cayenne extended type(s) for JSR-310 until it
is supported by jdbc.
This video is a nice intro to JSR-310
On Jan 23, 2008, at 18:27, Mike Kienenberger wrote:
It's not a requirement to have the tables in the same Map, only the
same Domain.
Ok, thanks.
- Tore.
On Jan 23, 2008, at 4:15 , Adam Yocum wrote:
I know that Cayenne will not allow me to do this sort of join even
though technically the server can do it if you explicitly name all
the tables involved with a database prefix like the above example.
I though it should be possible to use the
have a minute, would you give a brief synopsis of how this will
be supported by the Modeler?
On Nov 27, 2007 8:26 AM, Tore Halset [EMAIL PROTECTED] wrote:
Hello.
I think this is handled by the merge-stuff I have worked on. It will
be included in the next 3.0 milestone.
https://issues.apache.org
Hello.
We are using M2 in production in a pretty busy system. We use only the
classic cayenne stuff, but it is working very well.
Regards,
- Tore.
On Nov 26, 2007, at 22:56, Malcolm Edgar wrote:
Hi All,
I would like to know peoples experience in using Cayenne 3.0M2 for
Production
On Oct 26, 2007, at 14:29 , Andrus Adamchik wrote:
On Oct 26, 2007, at 3:11 PM, Tore Halset wrote:
I am not so used to the Persistent interface. How can I get the
value for a given ObjAttribute in a Persistent object? If the
Persistent is a DataObject I could use readProperty.
Yes
Hello.
We have a to-many relationship that is used all over the application.
Each time someone goes over that to-many relationship they want to
take a look at the next to-many relationship as well.
A -- B -- C
To make this faster, I want to prefetch the relationship from B to C
each
Hello.
This does not sound like a cayenne issue any more. Here is what I
would do to get going.
* Remove the extra OS layer if you are still using it. Was it
Parallells?
* Update to latest PostgreSQL and JDBC driver.
* Use vacuum analyze and autovacuum
* Find slow queries and use
Hello.
Looks like you are using an uncomitted new object in a query. Could
you post your relevant java code?
- Tore.
On Sep 19, 2007, at 12:12 , Gary Jarrel wrote:
Hi Guys!
Any thoughts on what could be causing this during commit?
org.apache.cayenne.CayenneRuntimeException: [v.3.0M1
On Aug 6, 2007, at 21:18 , Kevin Menard wrote:
If you are planning to upgrade to Cayenne 3.0 or start a new project
with it, which of the following best fits your needs:
[ ] Java 1.4 support
[ X] Java 5 support
I am using java 5 all over. I like generics, love
java.util.concurrent and are
Hello.
Creating your own DataSource (wrapper) as suggested by Andrus should
give you good control over things that are happening and perhaps what
to do/fix.
I had a problem in some non-cayenne based code that did not close the
jdbc Connection and it was hard to know where the problem was
Hello.
I am reading this thread and just want to say that I am using cayenne
2.0.2, postgresql-8.2-504.jdbc3.jar and postgresql-8.2.3. Cayenne
uses jndi to get connections from a jboss-4.0.3 connection pooling. I
do not see the postgres, idle in transaction problem.
- Tore.
On Apr 25,
On Apr 2, 2007, at 15:05, jerome moliere wrote:
2007/4/2, Tore Halset [EMAIL PROTECTED]:
On Apr 2, 2007, at 11:02, jerome moliere wrote:
CREATE TABLE PAITINGS_TBL(painting_id int primary key,painting_data
bytea);
CREATE TABLE ARTISTS_BIO(artist_id int primary key, artist_text_bio
Hello.
We call this a flattened many to many relationship.
http://cayenne.apache.org/doc20/cayennemodeler-flattened-
relationships.html
After flattening you will be able to call city.getStates() and so on.
Regards,
- Tore.
On Mar 21, 2007, at 16:20, Michael Lepine wrote:
Hello all. I am
52 matches
Mail list logo