15:04:14 #startmeeting 15:04:14 Meeting started Mon Jun 20 15:04:14 2011 UTC. The chair is sebersole. Information about MeetBot at http://wiki.debian.org/MeetBot. 15:04:14 Useful Commands: #action #agreed #help #info #idea #link #topic. 15:04:18 even though it was a couple of hours I pulled 15:04:46 so this wed is Beta2 15:05:03 i've already set that up in jira 15:05:52 so we have bi-weekly releases now, right? 15:06:00 hardy_: yep 15:06:27 hardy_: how close do you think you are to building metamodel for the "general" case? 15:07:09 so no secondary tables 15:07:22 hopefully with associations 15:07:28 still a fair bit 15:07:45 i focused initially one as you called it some low hanging fruits 15:08:05 and now I am back and components 15:08:18 but I am also atm in Germany, since I am at Jazoon this week 15:08:19 ok 15:08:46 so components wont get done it sounds like? 15:08:52 i was wondering how the hbm side is progressing 15:09:02 there were not so many checkins recently 15:09:21 I've been focusing on getting stuff into the persisters 15:09:29 i dont think it has 15:09:37 i have been focusing on apis 15:09:46 since thats really the crux for Betas 15:09:56 ok 15:10:09 i had just happened to miss entity mode initially for Beta1 15:10:18 i was on the prod said and waiting for hardy :) 15:10:59 hardy_: so, components will or will not be done for wed? 15:11:42 also, are associations handled from annotations side? 15:11:43 no (unless I have an extremely good day torrow) 15:12:13 as much as in the hbm side 15:12:26 so basically none 15:12:43 many to one 15:12:54 yep 15:13:31 well luckily the last api i think we need to address is NamingStrategy 15:13:37 hardy_, the change you made all pushed to master or still some on your local? 15:14:06 everything worth pushing is pushed 15:14:14 but we really cannot move on NamingStrategy until the metamodel itself is more stable 15:14:58 oh, and entitymanager 15:15:04 on a side note, could someone please download a dist package from here and tell me whether you can unpack it? I had some problems and don't want to annouce the release until I know it works 15:15:19 for core? 15:15:33 which dist? 15:15:41 Validator 4.2.0.Final 15:15:45 url? 15:15:48 ahh - I forgot the link http://sourceforge.net/projects/hibernate/files/hibernate-validator/4.2.0.Final/ 15:16:08 * sebersole tries 15:16:40 btw, how did you add those notes? 15:17:19 you mean readme and changelog? 15:17:23 I just uploaded them 15:17:48 problem was that I tried first the web ui, but it failed due to my slow connection and then I re-uploaded via sftp 15:18:13 hardy_: so you just upload files with specific names? 15:18:24 yes 15:18:37 hardy_: the tgz opens for me 15:18:46 ok then 15:18:53 did not try zip 15:19:18 cool 15:19:55 i'll talk to you later about notes :) 15:19:59 i might have downloaded the dist bundle while the updated was not yet available on all servers 15:20:02 btw, for core, we have some downstream jobs in hudson which download core job's dist artifact and unpack it and using it as dependency for testing 15:20:20 nice 15:20:30 interesting 15:20:34 dist as in SF? 15:21:14 even just a job to download and unpack 15:21:14 yep, hibernate core hudson job just build a dist release like what you do in release 15:21:31 right, but not THE dist 15:21:40 not the files from sourceforge 15:21:52 right 15:22:08 and downstream job (tck jobs) use that dist for testing 15:22:17 i guess validator can use this approach too 15:22:18 sebersole: speaking of the dist on sourceforge, did you ever write a script for uploading the packages? 15:22:25 after i automate the uploading to sourceforge i'll add a task to dl it and unpack :) 15:22:33 hardy_: ^^ 15:22:36 :D 15:22:45 i think we talked once about further automating the build process 15:22:50 right 15:23:01 docs, sourceforge 15:23:21 exactly 15:23:23 maybe even announcing 15:23:24 smarlow, will as7 upgrade to validator 4.2.0.Final? 15:23:50 stliu: can you ask shelly, she was talking about that 15:24:13 jpav: you almost doen with entity mode? 15:24:21 sebersole: the actually uploads are quite simple, but you need to build in some error handling etc into the scripts 15:24:42 stliu: from my perspective as7 should switch to Validator 4.2.0.Final now 15:24:43 It's not entity mode I'm really dealing with, rather the integrators 15:24:55 And I'm still a ways off from completing these 15:25:00 integrators how? 15:25:09 Need to ask hardy_ some questions after the meeting 15:25:17 wrt classloading? 15:25:19 Getting them to work with the new metadata 15:25:36 jpav: ok 15:25:38 no, wrt how entitylisteners are dealt with by jandex 15:25:48 ok 15:26:03 so then you are not doing anything with the model and entity mode? 15:26:25 no, those questions I had before were just for my own understanding 15:26:31 didnt we talk about that 15:26:33 ah 15:26:34 ok 15:27:01 I was going to work on entity modes 15:27:05 That all started from some code in the integrator that was dealing with only one mode, so I was just curious as to why the other modes were excluded 15:27:10 gbadner: in the model? 15:27:17 but I'm just focusing on pojo for now 15:27:23 i already did the runtime changes 15:27:31 yeah, I saw that 15:27:58 I saw there were changes; haven't had a chance to see what changed though 15:28:04 did you change it in the model? 15:28:11 gbadner: not yet 15:28:17 not in the build time model 15:28:22 ok, are you doing that then? 15:28:26 in the persisters/tuplizers yes 15:28:32 i can 15:28:37 its a trivial change in the metamodel 15:28:49 basically just have one? 15:28:56 instead of all 3? 15:29:08 each "thing" needs to have a field to state what its mode is 15:29:15 so entity, component 15:29:22 not sure about collections 15:29:34 currently it just inherits its owners mode 15:29:45 i was more focused on the api changes 15:30:46 currently it leverages the pre-existing hasPojoRepresentation() method 15:31:01 what I mean is at https://gist.github.com/1023221 15:31:13 well, that's for Entity 15:31:28 dunno 15:31:55 maybe 15:32:17 maybe all it needs is `private EntityMode entityMode;` 15:32:44 and getEntityModeEntitySpecifics() 15:32:51 dunno 15:33:46 are you thinking the metamodel could have > 1 entity mode for a particular Entity? 15:34:11 > 1 in the metamodel, but only 1 in the SessionFactory? 15:34:25 well thats one option 15:34:37 i thought that's how it is 15:34:55 hardy_: today, no, its you have all 3 in both places 15:35:29 for sure we only want one in the sessionfactory 15:35:36 right 15:35:41 however, thats not why i said 'dunno' gbadner 15:36:08 I can add: 15:36:09 i said i do not know because not sure there is need for this distinction 15:36:24 especially with dom4j gone 15:36:26 public EntityMode getEntityMode() 15:36:41 well the contract you mentioned already had that 15:36:41 oh, ok; 15:36:54 EntityModeEntitySpecifics.getEntityMode 15:37:20 yeah, but if Entity has 2 types of EntityModeEntitySpecifics 15:37:21 its just that really MapEntitySpecifics adds no value 15:37:27 gbadner: well yes 15:37:33 but 15:37:43 again look at the actual "specifics" 15:37:52 not much there 15:38:00 oh, ok 15:38:29 so hasPojoRepresentation() may be enough 15:39:39 ok, I see you said something about that above; wasn't sure what you meant 15:39:41 well thats in the existing code for building persisters/tuplizers from o.h.mapping 15:40:00 i just leveraged an existing piece of logic 15:40:16 to minimize changes in code we are going to toss 15:40:20 I see that the code also allows for custom entity modes 15:40:40 but we never exposed that 15:40:45 and 15:40:51 EntityMode is an enum 15:40:54 so 15:41:09 yeah, I was wondering about that 15:41:12 anyway 15:41:28 oh, ok; so I'll remove the custom entity mode stuff 15:41:29 i do not know about EntityModeEntitySpecifics 15:41:39 gbadner: ? 15:41:45 custom entity modes? 15:41:47 or 15:41:51 custom tuplizers? 15:41:56 custom entity modes 15:42:04 from where? 15:42:15 the tuplizer mappings? 15:42:25 somewhere in there 15:42:28 have to look for it 15:42:41 you might want to rebase 15:42:45 those classes are gone 15:42:54 yeah I just pulled 15:43:02 but couldn't build 15:43:12 anyhow, yes, I'll rebase before I do anything more 15:43:22 i did a full clean/test before i pushed 15:43:37 I think my laptop needs a reboot 15:43:52 yes, linux does not save you from reboots i have found :) 15:43:54 gbadner: btw, I checked. I am up to date and everything builds 15:43:55 it was in hibernate and I don't think it came out of it very well 15:44:07 I'm also getting a weird failure from yum 15:45:32 I wanted to discuss classloading 15:45:36 ok 15:46:04 I'm finding it kind of a pain to only have the class name in Entity 15:46:07 thats a topic near and dear to maxandersen's heart too 15:46:23 gbadner: i totally agree 15:46:26 but 15:46:35 so I created a ClassHolder 15:46:41 we have to consider these reveng sort of cases 15:46:53 ClassHolder? 15:46:59 so long as it handles that class not being available 15:47:00 yeah 15:47:04 yes 15:47:38 yes, it can hold a "deferred" class 15:47:40 so what do you put into class holder? 15:47:43 or a "loaded" class 15:47:57 gbadner: code is better 15:47:58 I was going to create pull request after rebasing 15:48:07 you can just gist it too 15:48:41 ok, sec, I'll push to my fork 15:49:04 personally i have a hard enough time keeping code i have locally in my ram 15:49:12 let alone code you wrote :) 15:49:21 I'm not asking you to download it 15:49:34 i am talking about in my brain 15:51:34 https://github.com/gbadner/hibernate-core/commit/78c3549100567f53ecf5e7c76b56fbe88c61e60f 15:51:35 git [hibernate-core] 78c3549.. Gail Badner deferred class - no field 15:51:54 ugh 15:52:11 that's not a good diff 15:52:51 gbadner: just gist us the ClassHolder code 15:52:55 thats good enough 15:52:59 yes, doing that 15:53:02 k 15:54:32 https://gist.github.com/1035866 15:55:16 there are 2 factory methods to create a ClassHolder 15:57:05 ok, i thought ClassHolder was a class 15:57:17 maybe you can show us the impls and this factory 15:57:34 yes that was the interface 15:58:17 here's how metadataImpl uses them: https://gist.github.com/1035874 15:58:26 gbadner: is this not a little bit of an overkill 15:58:56 true, metadataImpl may not need to track ClassHolder objects 15:59:33 why is it so painful to just have the class name in Entity? 16:00:22 ClassHolderImpl: https://gist.github.com/1035881 16:00:31 I'm assuming this is to avoid loading the classloader service and using classForName every time you want to work with the class? 16:00:39 yes 16:01:05 could we maybe just have EntityClassName? 16:01:09 basically, the class won't be loaded unless ClassHolder.getLoadedClass() is called 16:01:31 I think this can be useful for other Classes that may not be available for reveng 16:01:35 like persisters 16:02:08 if we just need this for Entity in the domain model I would also call it EntityClassName 16:02:09 I also added a factory method for creating a ClassHolder when the Class has already been loaded 16:02:12 like in annotations 16:02:14 well we should not be calling the getLoadedClass() until we start building the runtime model (persisters) generally speaking 16:02:19 like in annotations? 16:02:43 don't you already load the entity classes? 16:02:50 when you're processing annotations? 16:03:02 sure, but I don't need a ClassHolder for that 16:03:19 no, I believe jandex does that using its own method for reading class data 16:03:27 I don't think the classloaders get involved 16:03:29 nope 16:03:34 yes they do 16:03:48 jandex gives me just the annotations defined in the entities 16:03:55 it's a annotation repository/index 16:03:58 are they temporary class loaders then? 16:04:10 i still need to load the classes to reflect on them to find the persistent fields 16:04:13 Yeah, I get that, but I thought jandex read the raw class data directly 16:04:23 jpa does not require each persistent field to be annotated 16:04:28 if you just use the loaded class when creating a ClassHolder then we don't have to call Class.forName() 16:04:38 if I have @Entity on a class 16:04:47 and maybe one @Id somewhere 16:04:50 reading annotations is inherently different 16:04:55 you have a class 16:05:07 I don't have to place any additonal annotations on other fields/properties 16:05:24 they are persistent per default unless they are marked @Transient 16:05:27 sebersole: exactly 16:05:46 using a ClassHolder, it makes the processing bindings the same, whether the classes have been loaded or not 16:05:47 hbm and reveng are not so 16:05:58 gbadner: i get the desire to use it 16:06:15 personally just think it might be a tad overly complex 16:06:22 +1 16:06:44 having it available makes things a lot tidier 16:06:59 the persister's just get the loaded class 16:07:32 I don't need any visitors to load the classes 16:07:58 it's not just entity names 16:08:04 also field class names 16:08:19 tuplizer names 16:08:35 https://gist.github.com/1035899 16:08:56 gbadner: this is the same net effect iiuc 16:09:01 but simplier 16:09:14 imho 16:09:52 I was allowing for the cases where the classes were already loaded 16:10:01 from where? 16:11:05 it's already available in ConfiguredClass 16:11:26 well i have no idea what ConfiguredClass is 16:11:39 so then 16:12:04 ConfiguredClass is a helper class used by annotation processing 16:12:13 ok, what about field class names, tuplizer class names 16:12:18 persister class names 16:12:32 https://gist.github.com/1035899 16:12:54 tuplizers are not subject to this lazy loading 16:13:09 this is what maxandersen and i were discussing on the email list 16:13:26 not sure what you mean by "field class names" 16:13:35 Entity does not have a ConfiguredClass 16:13:38 you mean the attribute types? 16:13:48 did i say this was part of entity? 16:14:02 persoanlly i'd make it a innner of MetaImpl 16:14:13 ymmv 16:14:23 so you're saying that annotations and hbm would have impls for EntityClassName 16:14:43 different impls for EntityClassName 16:14:48 nope 16:14:54 I see no problem making an internal class 16:15:02 I think he's saying that Entity would have a field for the EntityClassName, right? 16:15:11 jpav: right 16:15:16 or a ClassHolder 16:15:30 and Attribute could have a ClassHolder 16:15:31 ClassHolder is a bad name 16:15:47 ok, I'm open to suggestions 16:15:50 for names 16:15:55 really this is a more general issue 16:16:06 yes, that's why I gave it a general name 16:16:11 an "initialize once" filed 16:16:14 field 16:16:19 we do this all the time 16:16:32 maybe we just need to encapsulate that 16:17:02 tbh, I think I did that 16:17:10 https://gist.github.com/1035881 16:17:43 if there's no need for MetadatImpl to track them, then I can remove that 16:18:30 gbadner: you do it *specifically* 16:18:32 not generally 16:18:34 sec... 16:18:42 ? 16:20:55 https://gist.github.com/1035918 16:21:00 there is a generic solution 16:22:20 so the class name would go in the initializer? 16:22:51 then Initializer needs: 16:22:57 public String getName() 16:23:43 then we need a ClassLoadingInitializer 16:24:00 sec... 16:24:01 :) 16:24:10 for someone who hates to be rushed... 16:25:07 and also a LoadedClassInitializer 16:25:11 https://gist.github.com/1035899 16:25:37 gbadner: i still do not get this distinction you are trying to make 16:25:40 that's just for annotaitons 16:25:46 hbm doesn't have ConfiguredClass 16:25:52 so then dont do it 16:26:04 and simply use the classloader 16:26:05 hbm is the one that doesn't have a loaded class 16:26:11 so then dont do it 16:26:14 and simply use the classloader 16:26:26 or make simple things complex 16:26:50 thats what this distinction seems like to me 16:27:05 but if everyone else thinks its better... 16:27:38 i like sebersole generic approach 16:27:51 there are 2 cases 16:27:52 maybe just InitializeOnce insteadof InitializeOnceField 16:27:57 or DeferredInitalizer 16:27:57 one where it's already initialized 16:28:11 hardy_: yeah deferred is good 16:28:22 gbadner but you don't have to 16:28:27 gbadner: like i said, i think thats not an important distinction 16:28:36 even right now you are calling ConfiguredClass.getClass.getName 16:28:43 I'm not 16:28:53 ? 16:29:08 maybe not in your local code, but in the latest on master it does, right? 16:29:14 ? 16:29:22 where is this? 16:29:37 what I am saying is that you don't need a special case for annotations 16:29:54 the class is already loaded, isn't it? 16:30:12 gbadner: so you propse saving exactly one classloader lookup 16:30:37 for imo addtional complexity 16:31:10 i think the same way 16:31:14 gbadner: and yes, you are right 16:31:20 you will need something for attributes 16:31:34 since they could be components/entities as well 16:32:05 fine, I'll get rid of the factory method and constructor for the loaded Class 16:32:20 It sounds to me like you guys are talking past each other a bit. Maybe we should defer this conv. until we clarify some things after the meeting. 16:32:41 well i think the meeting is pretty much done 16:32:49 unless someone has something else 16:32:50 ? 16:33:01 type resolution 16:33:21 this does not need to be part of the meeting either 16:33:26 #endmeeting