I was watching a video
[1] where Cope talk with Uncle Bob Martin about TDD. It's quite old and Cope's views might have changed but some things caught my attention. And I would like to clarify them through the perspective of DCI (which I believe was nascent at the time). So here are the quotes:
"[...] if you try to do things incrementally [...] driven by your interaction with the customer, without domain knowledge upfront, you run risk of doing it completely wrong"
So, as I write the context that implements a use case, I'm gonna also take into consideration the needs of other stakeholders (that I know are interested because of my domain knowledge). Those stakeholders will eventually have use cases written where their needs are central. But, knowing that the time will come, it's ok to prepare for it. Would it then be right to say that not all roles in a context are directly derived from the use case it represents? Am I completely wrong about my assumption of a 1:1 mapping between Context and Use Case?
"If you do a real banking system, savings account is not even an object [...] what a savings account is, is a process [...]"
And I believe today Cope would refer to it as a context instead of a process. What I understand he meant with "is not even an object" is that it's not one of those dumb data objects defined by a class in trygve. That got me thinking about the domains I've worked with and how a lot of central concepts are miss represented as objects. I've worked a lot with ecommerce. From the point of view of fulfillment, order is not an object, it's a process touched by payment, invoicing, picking, packing, shipping, etc. In a particular shop even the shopping cart was designed as a long running process. I worked with education, and a exam wasn't just a bunch of answeres. We would log all the times a student changed the answer other behaviours and with that info educators could improve lessons.
So thinking how I would organize a DCI project, I'm seeing this recursive structure. At the top there are the contexts implementing the end-user facing use cases. Those contexts are going to have some objects to interface with the user, but it seems to me that most of the core roles are going to be played by other contexts (that I know are contexts because of domain knowledge) and at the bottom I'm going to have contexts with roles played by objects, probably interacting with databases or messaging systems.
Is this accurate or just a coincindence that most core concepts can be seen as processes and not objects. Is it relevant?
Sorry if I read too much from old quotes. I don't want to waste anyone's time with ramblings. I'm new to DCI and most of this mail is probably nonsense. The tipical response is RTFM, so I bought and started reading Cope's book today. I promise more productive interactions in the future.
Cheers.
Alex Gravem