Created
April 12, 2011 16:23
-
-
Save sebersole/915835 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[04/12/11 10:32] <sebersole> hardy: anyway, back to that Metadata discussion | |
[04/12/11 10:32] <sebersole> this is what we need to decide | |
[04/12/11 10:32] <ge0ffrey> sorry for interrupting :) tnx for the info | |
[04/12/11 10:32] <stliu> ge0ffrey, good, let me know if you need me do something | |
[04/12/11 10:32] <hardy> one sec. let me just leave the JBoss talk | |
[04/12/11 10:32] <sebersole> there could be *something* above Metadata | |
[04/12/11 10:32] <hardy> then you get my undevided attention | |
[04/12/11 10:32] <sebersole> hardy: ah, np | |
[04/12/11 10:33] <ge0ffrey> oh yea, one more thing: Can I release 2.3.5 of the maven-jdocbook-plugin? | |
[04/12/11 10:33] <sebersole> ge0ffrey: you maintain it now, do what you wish ;) | |
[04/12/11 10:34] <hardy> sebersole: now :-) | |
[04/12/11 10:34] <ge0ffrey> k :) I 'll do the job they the aliens eat me or someone better comes along | |
[04/12/11 10:34] <sebersole> hardy: wow that was a long call | |
[04/12/11 10:34] <hardy> I remember now as well that I was wondering how this in the end bootstraps | |
[04/12/11 10:34] <hardy> 1 1/2 hours | |
[04/12/11 10:34] <stliu> 90' call | |
[04/12/11 10:34] <sebersole> too bad i missed it :D | |
[04/12/11 10:34] <sebersole> shucks | |
[04/12/11 10:35] <hardy> some parts were interesting, others ... | |
[04/12/11 10:35] <hardy> when you talk about users and Metadata you are talking about how the users adds annotated classes or xml files to it, right? | |
[04/12/11 10:36] <sebersole> hardy: so either (1) Metadata is the exposed API (2) Metadata gets split up into api/spi/internal (3) we have another construct with whcih user interacts | |
[04/12/11 10:36] <sebersole> hardy: yes | |
[04/12/11 10:36] <stliu> smarlow_call, i thought u're going to demo jpa, isn't it? | |
[04/12/11 10:37] <hardy> from that perspective MetaData is exposinfg really to much | |
[04/12/11 10:37] <sebersole> hardy: sure | |
[04/12/11 10:37] <sebersole> hence (2) | |
[04/12/11 10:37] <hardy> right | |
[04/12/11 10:37] <hardy> how does MetadataSourceQueue fit in here? | |
[04/12/11 10:38] <sebersole> well i think thats no longer needed | |
[04/12/11 10:38] <smarlow_call> stliu: first I heard about that :) | |
[04/12/11 10:38] <hardy> this is just a container we use to store the different configuration sources | |
[04/12/11 10:38] <sebersole> right | |
[04/12/11 10:38] <sebersole> its based on the old code | |
[04/12/11 10:38] <sebersole> so its where we keep stuff after its been added | |
[04/12/11 10:38] <sebersole> until we process it | |
[04/12/11 10:38] <sebersole> i still want to keep that general flow | |
[04/12/11 10:38] <hardy> so we are looking for an API which allows the user to add classes, packages, xml files which then get added to MetadataSourceQueue | |
[04/12/11 10:38] <sebersole> so you have 2 phases | |
[04/12/11 10:39] <hardy> :-) | |
[04/12/11 10:39] <sebersole> hardy: well like i said i think MetadataSourceQueue may no longer be needed | |
[04/12/11 10:40] <sebersole> i mean the other option is to yeah expose it to the users | |
[04/12/11 10:40] <sebersole> as the first "phase" (adding sources) | |
[04/12/11 10:40] <sebersole> the second phase being the processing of all those sources in prep for building a session factory | |
[04/12/11 10:41] <sebersole> so the "api" part here is really the addXXX stuff from Configuration | |
[04/12/11 10:41] <hardy> right | |
[04/12/11 10:42] <sebersole> though in my opinion we want to do a better job of distinguishing xml type up front | |
[04/12/11 10:43] <hardy> what do you mean w/ that? | |
[04/12/11 10:43] <sebersole> right now we essentially have to read the XML source once to see what type it is so we know what validation to apply | |
[04/12/11 10:43] <sebersole> it would be better if the user told us what type it is | |
[04/12/11 10:43] <sebersole> addResource(...) for example | |
[04/12/11 10:43] <hardy> so you want different addXml... methods | |
[04/12/11 10:43] <ge0ffrey> sebersole: looks like I don't have commit rights on the jdocbook plugin. My username is ge0ffrey (with a zero) and the svn url is https://svn.jboss.org/repos/maven/plugins/jdocbook/maven-jdocbook-plugin/trunk | |
[04/12/11 10:43] <hardy> or an addXml(filename, type) | |
[04/12/11 10:43] <sebersole> hardy: yeah, or | |
[04/12/11 10:44] <sebersole> addXml is inherently hbm.xml | |
[04/12/11 10:44] <sebersole> and we add: | |
[04/12/11 10:44] <sebersole> addOrmXml | |
[04/12/11 10:44] <sebersole> addOrmXml( source, version ) | |
[04/12/11 10:44] <hardy> I think having this distinction is a good idea | |
[04/12/11 10:45] <hardy> the only drawback is that we put more work onto the user | |
[04/12/11 10:45] <sebersole> not sure how that plays with persistence.xml | |
[04/12/11 10:45] <sebersole> yes and no | |
[04/12/11 10:45] <sebersole> i mean surely they know what types their files are | |
[04/12/11 10:46] <sebersole> hardy: actually this is really much less of an issue now iiuc because hbm.xml will be xsd | |
[04/12/11 10:46] <sebersole> we could really (1) read the xml and peek at the namespace, etc | |
[04/12/11 10:47] <sebersole> (2) apply validation directly based on that | |
[04/12/11 10:48] <hardy> so is this now an argument pro having a single addXml method? | |
[04/12/11 10:48] <-- emmanuel has left this server (Ping timeout: 248 seconds). | |
[04/12/11 10:49] <sebersole> hardy: well i am not sure how that plays with stuff like default values | |
[04/12/11 10:50] <-- smarlow_call has left this server (Ping timeout: 246 seconds). | |
[04/12/11 10:50] <hardy> which default values? | |
[04/12/11 10:52] <-- maxandersen has left this server (Quit: Leaving.). | |
[04/12/11 10:52] <sebersole> hardy: the ones from the DTD | |
[04/12/11 10:55] <hardy> not sure. you lost me on this one. going back to MetaData. I think it should not be exposed to the user. Instead we should expose an interface (maybe MetadataSource) with just the different addXYZ methods. Including splitting between addXml and addOrmXml | |
[04/12/11 10:57] <sebersole> hardy: yes, it should be "scaled down" whatever it is, but... | |
[04/12/11 10:57] <sebersole> it cannot be just an interface | |
[04/12/11 10:57] <sebersole> this goes back to the discussion yesterday | |
[04/12/11 10:58] <sebersole> the decision (short term) was for the user to instantiate this thing | |
[04/12/11 10:58] <hardy> right, so it is a class which the user can instantiate and populate | |
[04/12/11 10:59] <hardy> so that would be really alternative (3) | |
[04/12/11 10:59] <hardy> referring to | |
[04/12/11 10:59] <hardy> so either (1) Metadata is the exposed API (2) Metadata gets split up into api/spi/internal (3) we have another construct with whcih user interacts | |
[04/12/11 11:00] <hardy> do you see a benefit in (2)? | |
[04/12/11 11:00] <sebersole> hardy: longer term perhaps when if this becomes a service | |
[04/12/11 11:00] <sebersole> the api is the service contract | |
[04/12/11 11:01] <sebersole> the spi is the stuff the delegates know about | |
[04/12/11 11:01] <sebersole> and the impl is the impl :) | |
[04/12/11 11:02] <hardy> works for me as well. the most important is -1 to (1) | |
[04/12/11 11:08] <sebersole> hardy: ok, i'l start working on that | |
[04/12/11 11:08] <hardy> ok | |
[04/12/11 11:08] <sebersole> do you think it makes sense to keep around MetadataSourceQueue? | |
[04/12/11 11:09] <sebersole> or just subsume that stuff into Metadata? | |
[04/12/11 11:09] <sebersole> some of that is strictly HBM too | |
[04/12/11 11:10] <hardy> I think it becomes obsolete | |
[04/12/11 11:10] <sebersole> extendsqueue too possibly | |
[04/12/11 11:10] <hardy> or in case of option (3) i saw MetadataSourceQueue becoming the MetadataSource I was talking about | |
[04/12/11 11:11] <hardy> right, ExtendsQueue as well | |
[04/12/11 11:12] <hardy> but it is hbm specific anyways | |
[04/12/11 11:12] <hardy> what I want to say w/ that is that I don't really know how important this class is for hbm mapping ;-) | |
[04/12/11 11:13] <hardy> btw, do we just keep pushing changes to master? | |
[04/12/11 11:19] --> gbadner has joined this channel ([email protected]). | |
[04/12/11 11:19] <sebersole> hardy: yes | |
[04/12/11 11:19] <sebersole> thats the general idea | |
[04/12/11 11:19] <hardy> ok | |
[04/12/11 11:19] <sebersole> do little pieces of work, integrate | |
[04/12/11 11:20] <sebersole> hardy: here is my concern with (3) | |
[04/12/11 11:20] <gbadner> sebersole, pong | |
[04/12/11 11:20] <sebersole> gbadner: sec | |
[04/12/11 11:20] <sebersole> although this discussion with hardy involves you too | |
[04/12/11 11:21] <sebersole> and the questions i asked last night | |
[04/12/11 11:21] <sebersole> hardy: here is my concern with (3) | |
[04/12/11 11:21] <gbadner> k, can you post your conv on pastebin? | |
[04/12/11 11:21] <sebersole> so we define a "MetadataSource" | |
[04/12/11 11:21] <sebersole> and users use that | |
[04/12/11 11:21] <sebersole> how do we get from that to Metadata ? | |
[04/12/11 11:22] <sebersole> MetadataSource will need access to services too btw | |
[04/12/11 11:22] <sebersole> ClassLoaderService | |
[04/12/11 11:22] <sebersole> to properly resolve resource lookups |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment