Thanks Brian.. your response is in line with my general understanding
of the o2m vs m2o relationships, and I was by no means blaming
Transfer for anything. I think I hijacked the thread and took it off
topic, but your post reminds me of a good blog I read and must have
forgotten about o2m vs m2o... maybe it was from you or maybe it was
Brian Rinaldi, IDK.. either way, I clearly remember reading a similar
relationship guidance for transfer models.
But what motivated me to deviate from that and possibly even missuse
the o2m, as you have pointed out, was this particular case:
Lets say I am a processing job shop, I receive multiple lots of
different types of object made of different types of materials
manufactured by different companies and sent to me from different
customers every day, of every week, of each month, of every year. I
process these parts, and then I ship them back, and collect payment..
these "parts" are complex and so is my "process".. I have many
customers.. some of my customers have 10,000 different parts, with
different revisions, and they will request a quote or send these parts
in each revision for me to "process"....
so I said to myself.. these are tightly related relationships.... this
isn't a user has an account type.. in a "known" system where things
can be defined as m2o or in some other way.....
and i thought:
Self, A customer has many parts
, then I thought...
Self, this part belongs to this customer.
but then I found out that a customer generated by transfer doesn't
know diddly about the parts which it could have when it's defined as
m2o ..
then I said "Self, WTF am I to do?"
Is this a cust->part = o2m or a part->cust = m2o?
To find out if I have in fact taken the wrong approach with my TIBO
work-around is exactly why I'm here.. I don't know enough about this
to go-it-alone... so all of your input matters, and I appreciate it!
so, lets get back to my case and say, "a customer has many parts"....
but lets say I never really 'ask' transfer to give me *all of those
parts only 1 of them when requested via lookups done with querys
generated via TQL... in this TIBO I inject a cloned empty transfer
object of that concrete type.. This gives me a new, technically
decorated "TransferObject" which I can work efficiently with in my UI,
Controller, Service, Gateway, Transfer.. it is a "vitural" transfer
object which I re-populate via a cached query generated via TQL, or
sql, or a file or directory query.. and then I override some of base
transfer properties to "simulate" a real transfer object.... so far
this is working prety nicly as a o2m with 10k+ objects using 1 cfc,
not 10,000+... FYI my current dev box is running cf 8.0.1 | jvm
1.6.12 @ 1.3gb heap 256perm | transfer 1.1 | cs 1.2 | cb 2.6.3 | majik
0.7 | jquery 1.3.2 on IIS 7 / WIN7x64 - Intel QuadCore @ 2.6ghz w/8gb
ram.
although I understand that I can't assume that it won't happen, I am
NOT actually ask transfer to generate 10,000 cfcs in that relationship
for me while still getting the o2m transfer functionality,
performance, and ancillary support functions I need when and where I
need them..
I don't know if the above context helps you see my motivation in a
different light.. but it's also worth noting that In general, as a
rule of thumb, transfer is very good at doing it's job... maybe I just
have problems understanding some of my percieved special
relationships.. the only thing I could say is that maybe o2o or bi-m2m
support would could helpe creative developers come up with other ways
of dealing with my issue.
I think with the o2m+TIBO, I have attempted to beat the system by
having all of the transfer functionality that i need, when and where I
need it.. even if i'm designing around my own created issues with the
miss-use of a relationship.. I learning something.
Thanks & have a good weekend all!
-adam