Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

[11:45:42 CDT(-0500)] <anastasiac> Hey, Bosmon, are you there?

[12:03:54 CDT(-0500)] <Bosmon> hi anastasiac

[12:04:30 CDT(-0500)] <anastasiac> Hi, Bosmon. I'm wondering if you have a few minutes to chat about model transformation

[12:04:43 CDT(-0500)] <Bosmon> sure

[12:04:51 CDT(-0500)] <anastasiac> I'm trying to update the UIO model relay in a way that would be useful for the video player

[12:06:08 CDT(-0500)] <anastasiac> hm

[12:06:43 CDT(-0500)] <anastasiac> I have a question about what can be put in to the rules for a transformation

[12:07:04 CDT(-0500)] <anastasiac> I can specify any function, not just one of the pre-packaged transformations

[12:07:19 CDT(-0500)] <anastasiac> and the rule object is passed as an argument to that transformation function, is that right?

[12:07:26 CDT(-0500)] <Bosmon> anastasiac - a function without a recognised grade will be interpreted as a "standardTransformFunction"

[12:07:45 CDT(-0500)] <anastasiac> the functions must be free functions, right?

[12:08:00 CDT(-0500)] <Bosmon> anastasiac - no, a bare function will simply receive the input object from the current transformation

[12:08:25 CDT(-0500)] <anastasiac> can the transformation be something other than a free function? e.g. a method on a component?

[12:08:37 CDT(-0500)] <Bosmon> anastasiac - there is currently no integration between Model Transformations and IoC, correct

[12:08:48 CDT(-0500)] <Bosmon> So there is no ability to specify anything other than a free function as a transform function

[12:09:39 CDT(-0500)] <anastasiac> so if my transformation needs information from a component, I need to choose a transformation grade that results in the rule object being passed to the function?

[12:10:08 CDT(-0500)] <anastasiac> ok, here's the use case:

[12:10:27 CDT(-0500)] <anastasiac> UIEnhancer stores language preferences as a language code, e.g. "en"

[12:10:42 CDT(-0500)] <anastasiac> the video player stores the language preference as an index into the array of tracks

[12:11:04 CDT(-0500)] <anastasiac> so the transformation function needs to search through the array of tracks for (the first) one that has the specified language code

[12:11:24 CDT(-0500)] <anastasiac> so the question is: how to get the array of tracks to the transformation function?

[12:11:54 CDT(-0500)] <anastasiac> does that make any sense, Bosmon? sorry, I'm feeling rather inarticulate today

[12:13:50 CDT(-0500)] <Bosmon> anastasiac - that's fine - yes, the list of languages needs to form part of the transformation rule

[12:14:59 CDT(-0500)] <anastasiac> I'm not really clear on the differences between the grades. a "standardTransformFunction" only receives the input object, right?

[12:15:38 CDT(-0500)] <anastasiac> that's "standardInputTransformFunction" ?

[12:15:38 CDT(-0500)] <Bosmon> anastasiac - I notice that we already have a piece of framework for this in the form of the function "fluid.videoPlayer.transformLanguageChange"

[12:17:43 CDT(-0500)] <anastasiac> yes, I'm reworking the video player to use the UIO model relay instead of its own private model relay.

[12:18:13 CDT(-0500)] <Bosmon> anastasiac - yes - do you have an idea how to achieve that?

[12:18:45 CDT(-0500)] <anastasiac> yes, I've got it working, except for the language transformation

[12:19:14 CDT(-0500)] <Bosmon> anastasiac - the language transformation is the only non-trivial part....

[12:19:55 CDT(-0500)] <anastasiac> I'm trying to modify the UIO modelRelay to support this

[12:20:15 CDT(-0500)] <anastasiac> I've set the mergePolicy on the rules to noExpand to be able to handle the function name

[12:20:42 CDT(-0500)] <anastasiac> but that means any IoC reference the video player or its options or model would be expanded

[12:21:02 CDT(-0500)] <colinclark> Reading between the lines, I'm hearing Bosmon saying that it's a pretty tough problem, this one

[12:21:13 CDT(-0500)] <Bosmon> anastasiac - in fact, the "modelRelay" system inside the VideoPlayer was our current best attempt at this problem

[12:21:35 CDT(-0500)] <Bosmon> So if there were any modifications to be done, it would be to transfer that implementation to UIO, rather than the other way round

[12:21:59 CDT(-0500)] <anastasiac> ok, so modify the UIO modelRelay to work the way the VP-private one did

[12:22:02 CDT(-0500)] <Bosmon> But I don't believe we have enough framework infrastructure or planning to be able to tackle this problem properly yet

[12:22:12 CDT(-0500)] <Bosmon> Which is why we currently left the VideoPlayer relay where it was

[12:22:25 CDT(-0500)] <Bosmon> If it had been "framework-ready", we would have put it in the framework already

[12:22:35 CDT(-0500)] <anastasiac> well, the VP relay was there before UIO had its own relay, I belie e

[12:22:43 CDT(-0500)] <Bosmon> anastasiac - that's correct

[12:22:53 CDT(-0500)] <anastasiac> I was hoping that the relay created for UIO might be sufficient

[12:23:04 CDT(-0500)] <Bosmon> Neither the VP relay nor the UIO relay are good enough to become a standard part of the framework

[12:23:12 CDT(-0500)] <Bosmon> Which is why they are currently separate, private implementations

[12:23:30 CDT(-0500)] <Bosmon> But of the two of these, the VP one is more capable and has had more thought applied to it

[12:23:33 CDT(-0500)] <anastasiac> do you think it might be worth updating the UIO relay to offer what the VP relay currently does?

[12:23:50 CDT(-0500)] <Bosmon> anastasiac - not without a big conversation, no

[12:24:16 CDT(-0500)] <anastasiac> ok, we'll leave it where it is, then

[12:24:21 CDT(-0500)] <Bosmon> We would need to get all the Model Transformation team involved, including you, colin, Kasper, etc.

[12:24:31 CDT(-0500)] <Bosmon> Since this is one of the next big upgrades for Model Transformations

[12:24:38 CDT(-0500)] <Bosmon> I'd prefer to have time for kasper to get his branch in first

[12:24:45 CDT(-0500)] <Bosmon> Since this will fundamentally affect a few aspects of MT

[12:24:47 CDT(-0500)] <anastasiac> right, he's been making mods

[12:25:03 CDT(-0500)] <Bosmon> And he has another big change coming up, which will change the meaning of MT in a fairly fundamental way

[12:25:27 CDT(-0500)] <Bosmon> Unfortunately he has been distracted with the pilots for a while, but once they are over, hopefully we can get his stuff up to speed

[12:25:39 CDT(-0500)] <colinclark> kasper, I think, is going a little nuts with the pilots

[12:25:52 CDT(-0500)] <colinclark> and fascinatingly, some of their difficulty revolves around weaknesses in model transformation

[12:25:58 CDT(-0500)] <colinclark> he was telling me today that he was keen to get back to it