Re: MySQL deadlock exceptions

2014-08-05 Thread Ramiro Aparicio
El 05/08/2014 15:54, Andrus Adamchik escribió: After years working with MySQL I stumbled on a problem for the first time that seems rather old and common. MySQL would throw when 2 InnoDB transactions are trying to update the same row: com.mysql.jdbc.exceptions.jdbc4.MySQLTransactionRollbackExc

Re: Issue with distinct 3.1

2013-11-13 Thread Ramiro Aparicio
DISTINCT case, this could either be a yet unknown bug in the framework, or something in the app code. Andrus On Nov 13, 2013, at 1:15 AM, Aristedes Maniatis wrote: On 13/11/2013 3:59am, Ramiro Aparicio wrote: I am really not sure if current behaviour without distinct is ok, but at least it works

Issue with distinct 3.1

2013-11-12 Thread Ramiro Aparicio
ot sure if current behaviour without distinct is ok, but at least it works for me. Best regards. Ramiro Aparicio

3.2M1 first impressions

2013-11-11 Thread Ramiro Aparicio
object, instead query matched: " + objects.size()); } return objects.get(0); } I will tell you if I find something worth noting. Best regards. Ramiro Aparicio

Re: ServerRuntime Best Practice? [3.1]

2013-02-28 Thread Ramiro Aparicio
s for each user, etc. Thanks, mrg On Thu, Feb 28, 2013 at 10:28 AM, Ramiro Aparicio < ramiro.apari...@prot-on.com> wrote: El 28/02/2013 16:15, John Huss escribió: If it's a servlet app, then the runtime is created in CayenneFilter and bound to the thread for eac

Re: ServerRuntime Best Practice? [3.1]

2013-02-28 Thread Ramiro Aparicio
El 28/02/2013 16:15, John Huss escribió: If it's a servlet app, then the runtime is created in CayenneFilter and bound to the thread for each request and you access it via WebUtil.getCayenneRuntime(servletContext); Or you can get a context from the injector if you have bound that to a thread:

Entities without relation

2013-01-30 Thread Ramiro Aparicio
wledge I would want to now if something as "simple" is impossible to be queried using Expressions Ramiro Aparicio

Re: many2many + single table inheritance

2013-01-14 Thread Ramiro Aparicio
I have been working with inheritance a lot lately but finally I had to remove it from my model. If Base is an abstract class you will have problems at deleting A o Base child objects. Anyway in your case you want to make 3 relationships, A<-Base A->Base1 A->Base2 (the arrows are not for cardin

Re: Deleting object rendes an instanciation exception

2013-01-04 Thread Ramiro Aparicio
this exception does not map to any concrete subclass entity qualifier? Andrus On Jan 3, 2013, at 8:54 PM, Ramiro Aparicio wrote: Hi and happy new year to everyone, I am back with my happy inheritance one more time. I am using single table inheritance and just in case someone did not rememb

Re: Deleting object rendes an instanciation exception

2013-01-04 Thread Ramiro Aparicio
escribió: Hi Ramiro, Happy New Year to you too :) So is it possible that the database row that causes this exception does not map to any concrete subclass entity qualifier? Andrus On Jan 3, 2013, at 8:54 PM, Ramiro Aparicio wrote: Hi and happy new year to everyone, I am back with my

Deleting object rendes an instanciation exception

2013-01-03 Thread Ramiro Aparicio
Hi and happy new year to everyone, I am back with my happy inheritance one more time. I am using single table inheritance and just in case someone did not remember the model here is a simplification about it: abstract SessionLog it has relations to other tables as Log or User SessionLogApi and

Re: Intermittent errors with inheritance

2012-11-27 Thread Ramiro Aparicio
eally frustrating. Ramiro El 27/11/2012 13:40, Andrus Adamchik escribió: Hi Ramiro, Thanks for opening CAY-1775 and sorry for me not answering anything yet. Need to find some uninterrupted time to sit down and investigate this scenario. Thanks, Andrus On Nov 20, 2012, at 4:11 PM, Ramiro Apa

Intermittent errors with inheritance

2012-11-20 Thread Ramiro Aparicio
erver starts (and it continues to fail until a server restart). I will happily send more traces to try to catch the error if you tell me what do you need. Ramiro Aparicio

Re: Splitting model

2012-10-24 Thread Ramiro Aparicio
case I can think of is a Core module + extra optional modules that expands the model with new entities (and usually this needs relationships with core). Ramiro El 24/10/2012 14:24, Andrus Adamchik escribió: On Oct 24, 2012, at 2:58 PM, Ramiro Aparicio wrote: If thats possible even if the

Re: Splitting model

2012-10-24 Thread Ramiro Aparicio
f DataNode-agnostic mapping projects and Java-based stack assembly (that is made easy in 3.1) should give us ultimate mapping modularity. If there are scenarios not well covered by this, let's discuss. Andrus On Oct 24, 2012, at 2:19 PM, Ramiro Aparicio wrote: Hi, After upgrading t

Splitting model

2012-10-24 Thread Ramiro Aparicio
of something like that. Indeed I am not sure if it can be done as probably path to other modules models will not be the same when developing or at runtime, but I think it will be a very interesting feature for big projects. Ramiro Aparicio

Re: 3.1B1 Validation Exception

2012-10-11 Thread Ramiro Aparicio
s. We are rewriting the docs for 3.1. May need to clarify it there. (and sorry for the late reply). On Oct 10, 2012, at 3:17 PM, Ramiro Aparicio wrote: Umm we found the same pattern some time ago, and just moved our default values to onPostAdd, and I that is working fine for us, but I am not sure if

Re: 3.1B1 Validation Exception

2012-10-10 Thread Ramiro Aparicio
Umm we found the same pattern some time ago, and just moved our default values to onPostAdd, and I that is working fine for us, but I am not sure if we are using it with mandatory fields. El 10/10/2012 13:42, do...@xsinet.co.za escribió: Does anybody have any news on this, please ? Thanks. --

Re: Vertical inheritance with relationships

2012-10-10 Thread Ramiro Aparicio
able to traverse from activity_log to session_log_api/web as with plain vertical I did not found a way. Correct. On Oct 10, 2012, at 1:19 PM, Ramiro Aparicio wrote: Hi Andrus, Nice you were able to track the error, I finally yesterday changed the model to be horizontal inheritance and it

Re: Vertical inheritance with relationships

2012-10-10 Thread Ramiro Aparicio
t is the combination of the later that is giving us hard time), how about you keep the inheritance, but "unflatten" everything in subclasses, using individual ObjEntities and regular relationships for session_log_api and session_log_web? This should work more reliably. Thanks, Andrus

Re: Vertical inheritance with relationships

2012-10-08 Thread Ramiro Aparicio
ndent tables. If that doesn't help, yeah, you can send me the model. Andrus On Oct 8, 2012, at 2:44 PM, Ramiro Aparicio wrote: Hi Andrus, First of all thank you for all the effort and the fast reply time, I really appreciate your help with this issue. Then the bad news after some de

Re: Vertical inheritance with relationships

2012-10-08 Thread Ramiro Aparicio
l model so you can check everything is configured as it should (I think I double checked everything but just in case). I will try any workaround I am able to imagine and publish any new info. Ramiro Aparicio El 05/10/2012 23:12, Andrus Adamchik escribió: Oh, and actually I think we can f

Re: Vertical inheritance with relationships

2012-10-05 Thread Ramiro Aparicio
El 19/09/2012 22:12, Andrus Adamchik escribió: On Sep 19, 2012, at 11:24 AM, Ramiro Aparicio wrote: BTW I tried to do everything with 3.0.2 modeller and finally updated to 3.1.B1 modeller, Will the model created with 3.1.B1 modeller work with 3.0.2 runtime? (I want to update the runtime

Re: DI in 3.1

2012-10-05 Thread Ramiro Aparicio
is not injected, so right now I am out of options, can someone point me how Cayenne DI is working or how can I create a new context at 3.1? Thanks in advance for the help. Ramiro Aparicio

DI in 3.1

2012-10-04 Thread Ramiro Aparicio
injected, so right now I am out of options, can someone point me how Cayenne DI is working or how can I create a new context at 3.1? Thanks in advance for the help. Ramiro Aparicio

Vertical inheritance with relationships

2012-09-19 Thread Ramiro Aparicio
Hello, I am struggling with some problems mapping vertical inheritance clases: I have 5 classes in my business model: Session ClientSession inherits from Session WebSession inherits from Session User Device Using vertical inheritance I have all 5 tables and I have no problem mapping ClientSes

Nested contexts deadlock

2012-09-06 Thread Ramiro Aparicio
to time. Thanks in advance. Ramiro Aparicio

Stat gathering

2012-05-09 Thread Ramiro Aparicio
ustom QueryLogger either so I am lost. Maybe this is a marginal use case but I think this is a interesting feature for everyone using Cayenne in production enviroments to gather information without having to parse the logs. Ramiro Aparicio

Re: Using primary keys in expressions

2012-04-03 Thread Ramiro Aparicio
into your ObjEntity in Cayenne Modeler. If the source is really internal, you might want to consider matching against user names or objects or other attributes. mrg On Tue, Apr 3, 2012 at 11:18 AM, Ramiro Aparicio wrote: I am trying to do what I thought it should be an easy query SELECT *

Re: Using primary keys in expressions

2012-04-03 Thread Ramiro Aparicio
other attributes. mrg On Tue, Apr 3, 2012 at 11:18 AM, Ramiro Aparicio wrote: I am trying to do what I thought it should be an easy query SELECT * FROM Users WHERE idUser IN (2,5) The problem is that it seems that the primary key of tables is somewhat of a special column that is not allowed

Using primary keys in expressions

2012-04-03 Thread Ramiro Aparicio
I am trying to do what I thought it should be an easy query SELECT * FROM Users WHERE idUser IN (2,5) The problem is that it seems that the primary key of tables is somewhat of a special column that is not allowed to be used in expressions as I get Can't resolve path component: [User.idUser].

Help with SQLTemplate and SQLResult

2011-11-17 Thread Ramiro Aparicio
;t know what I am doing wrong. Maybe if someone can point me to some example code it can help, but I couldn't find anything :( Thanks in advance. Ramiro Aparicio