Monday , March 10 2025

Reactive Architecture: Domain Driven Design Cognitive class Exam Answers:-

Course Name :- Reactive Architecture: Domain Driven Design

Chapter Name:- Domain Driven Design

Question 1 : True or False: Many of the guidelines and rules in Domain Driven Design are compatible with those in Reactive Architecture.

·         True

·         False

Question 2: What are some key goals of Domain Driven Design?

·         Provide isolation for software designers to create models of domain processes without the bias or experience of business domain experts.

·         Take a large domain or system and break it down into smaller pieces or subsections.

·         Make domain model design the sole responsibility of domain experts.

·         Create communication channels between domain experts and software developers.

·         None of above.

Question 3 : True or False: Often a single all-inclusive model of a very large domain can contain much, and at times overwhelming, complexity. Breaking those large domains into smaller pieces can result in making the complexity more manageable and understandable.

·         True

·         False

Question 4 :If we break down a large domain into smaller pieces we need to:

·         Clearly determine the boundaries of the smaller pieces and how each piece does or doesn’t interact with the other pieces in the larger domain.

·         Design a model that puts the pieces back to get into a single understandable domain. This results in changes to the business or organization processes.

·         Do nothing more. Simply breaking the domain into pieces is enough.

 

What is a Domain 

Question 1: In the world of software architecture and development a domain can be discribed as:

  • The portion of a URL that identifies the name of a website.
  • a repository where code is packaged and stored.
  • referring to the core group of developers in a given Agile team.
  • referring to a business or idea that we are trying to model.

Question 2: Typical domain experts in an insurance company are:

  • QA Tester
  • Claims Adjuster
  • Claims Clerk
  • Server Sys Admin
  • Sales Agent
  • Java Engineer

Question 3: True or False: A domain model is part of the software application.

  • True
  • False

Question 4 : True or False: Domain experts should be able to easily understand the domain model.

  • True
  • False

Question 5 : The name of the form of communication that domain experts and software developers can understand is:

  • Domain Terminolgy
  • Universal Language
  • Ubiqutous Language
  • Common Vernacular

Question 6 : True or False: Domain Experts provide language that is used in the software, and software developers provide language that is used in the domain. Both provide input in equal proportions.

  • True
  • False

Question 7 : True or False: If developers find a process or abstraction in a domain that doesn’t appear to have a name, the developers should talk to the domain experts about whether it already exists or co-create a new term to discribe it.

  • True
  • False

Case Study :Reactive BBQ Domain

Question 1 : Which of the following people represent Domain Experts for the Reactive BBQ?

  • Software Developers building the new system
  • The person washing the dishes.
  • The CEO
  • Software Developers maintaining the old system
  • The Corporate Head Chef
  • The Operations team responsible for deploying the software in production.
  • The Chefs and Cooks in the restaurants
  • The Serving Staff (Servers)

Note: Make sure you select all of the correct options—there may be more than one!

Question 2: While building the new system, we need to define a term that indicates when an order has been completed by a server, and is being sent to the kitchen to be cooked. The best people to ask about the right term are:

  • The Dictionary
  • The Servers
  • The Software Developers
  • The CEO

Question 3: Which of the following are terms you would find in the Reactive BBQ Ubiquitous Language?

  • Table, Row, Column
  • Host, Server, Cook
  • Reservation, Order, Delivery
  • Account, Transaction, Deposit
  • Inventory, Work Schedule, Wage

Chapter Name :- Decomposing the Domain

Question 1: Sub domains are created by:

·         Dividing our code into equal manageable subdomain chunks, usually based on a division of total application lines of code.

·         Grouping related business ideas, actions and rules into separate subdomains.

·         Grouping all interface code, all persistence code and all business logic code into three code subdomains.

·         Grouping isolated data (for example, all Customer data) that will go into separate persistence stores.

Question 2 : True or False: It is impossible for a concept (such as Order or Customer) to exist in multiple sub domains.

·         True

·         False

Question 3: True or False: If we do find a concept (such as Order or Customer) that appears to exist in multiple subdomains, we are defining the concept at too low a level and thus need to define the concept at a higher level of abstraction.

·         True

·         False

Question 4 : True or False: Each subdomain has its own ubiqutious language.

·         True

·         False

Question 5 : True or False: Terms in the ubiquitous language are never shared between subdomains.

·         True

·         False

Question 6 : The bounded context is:

·         A technique to constrain the business activities so they resemble well defined method calls.

·         The ubiqutious language and model of a subdomain.

·         The ubiqutious languages and models of all subdomains.

·         A namespace within our application that is tightly restricted in scope.

Question 7 : True or False: When initially defining microservices, it’s often a good idea to start with your bounded contexts: one bounded context = one microservice.

·         True

·         False

Question8:  True or False: One bounded context always equals one, and only one, microservice.

·         True

·         False

Question9:  True or False: From one bounded context to another the meaning of a word or concept, for example Customer, may dramatically change.

True

False

Question 10 : What are some guidelines we can use to determine a bounded context?

·         Business strategic goals always identify bounded contexts.

·         Consider human interactions and communication that seem to form a subculture within a broader organization.

·         Bounded contexts are often found in business marketing matierials, particularly online ads.

·         Look for changes in the ubiqutous language.

·         Job classifications within organizational subgroupings might suggest various bounded contexts.

·         A clear grouping of business processes and workflows could point to a bounded context.

·         None of the above.

Note: Make sure you select all of the correct options—there may be more than one!

 

Question 11: Event First Domain Driven Design identifies bounded contexts by looking for activities or events that occur in the domain. What are some examples of activities or events?

·         The delivery app logs all deliveries.

·         Customer makes a reservation.

·         Server places an order.

·         Database commits a order payment.

·         None of the above.

Note: Make sure you select all of the correct options—there may be more than one!

 

 Case StudyDomain Activities

 

Question1 : Based on this interview, Which of the following represent activities performed by the Server?

·         Server cooks food for customer

·         Server helps guests understand the menu

·         Server adds item to order

·         Server collects payment

·         Server takes food to customer

·         Server takes reservation for customer

Note: Make sure you select all of the correct options—there may be more than one!

 

Question2  : Based on this interview, Which of the following represent activities performed by the Driver?

·         Driver sets status flag on order to “delivered”.

·         Driver receives delivery notification

·         Driver picks up food for delivery

·         Driver collects payment

Note: Make sure you select all of the correct options—there may be more than one

 

Maintaining Purity 

Question 1: True or False: Concepts in one bounded context should always mean the same thing in another bounded context. Thus, there is no need to translate concepts between bounded contexts.

·         True

·         False

Question 2 :If we always treated a concept, for example Customer, exactly the same across many different bounded contexts, we may introduce:

·         redundancy into our system.

·         parralellism into our system.

·         coupling between contexts in our system.

·         sameness into our system.

Question 3 : We can prevent one bounded context from leaking into another by using a:

·         Anti-Corruption Layer.

·         Rule that says one context never communicates with another.

·         Access Control List.

·         Context Leak Prevention Layer

·         None of above.

Question 4 : Why is it a good idea to use an abstract interface for an Anti-Corruption Layer?

·         Because interfaces are common across all major programming languages and as such are a common way to implement patterns.

·         The abstract interface is the Anti-Corruption equivalent of a Enterprise Road-Check pattern. The Enterpise Road-Check pattern dictates that you can’t go to another location without going through the check.

·         Because an Anti-Corruption Layer is a way of interacting between bounded conexts.

·         The abstract interface can be a pure domain representation, while concrete classes extending the interface can be specific infrastructure implementations. This keeps the core job of the Anti-Corruption layer (stating what it does or provides) without locking into the specific system details needed to do it.

Question 5: True or False: We avoid using Anti-Corruption Layers when our bounded contexts interact with legacy systems. Our bounded contexts should mirror the legacy system interface.

·         True

·         False

Question 6 : True or False: Its sometimes neccessary to have Anti-Corruption layers on both sides of the interaction between bounded contexts or a bounded context and legacy system.

·         True

·         False

 

Case Study :- Bounded Contexts 

Question 1: Which of the following is NOT a candidate for an object in the activities we defined for the host?

·         Host

·         Customer

·         Reservation

Question 2: After analyzing the Server interview we have come up with a set of activities. For example:

·         Server

·         Server takes an Order

·         Server delivers an Order

·         Server collects Payment for an Order

·         Server Objects

Question 3 : Which of the following is NOT a candidate for an object in the activities we defined for the host?

·         Delivery

·         Payment

·         Order

Question 4 : After analyzing the Online Customer interview we have come up with a set of activities. For example:

·         Online Customer

·         Online Customer adds Menu items to an Order

·         Online Customer makes Payment for an Order

·         Online Customer Makes Reservation

·         Online Customer Objects

Question 5 : For the following activities, what is a possible object in the sentence:

 

·         Online Customer adds Menu items to an Order

·         Online Customer makes Payment for an Order

·         Online Customer Makes Reservation

Question 6 : After analyzing interviews from a number of different domain experts we have come up with the following activities:

·         Host

·         Host checks current Reservations

·         Host creates Reservation for a Customer

·         Host seats Customer with Reservation

·         Server

·         Server takes an Order

·         Server delivers an Order

·         Server collects Payment for an Order

·         Bartender

·         Bartender takes a Drink Order

·         Bartender prepares a Drink Order

·         Bartender delivers a Drink Order

·         Bartender collects Payment for a Drink Order

·         Cook/Chef

·         Cook prepares an Order

·         Cook notifies Server an Order is complete.

·         Chef inspects Orders

·         Delivery Driver

·         Driver picks an Order up at the restaurant

·         Driver delivers an Order to Customer

·         Driver collects Payment for an Order

·         Online Customer

·         Online Customer adds Menu items to an Order

·         Online Customer makes Payment for an Order

·         Online Customer Makes ReservationWhile it’s not comprehensive, the list of objects in our activities make good candidates for Bounded Contexts.

 

Question 7 : Based on the objects defined in the activities above, which of the following are possible candidates for Bounded Contexts?

·         Delivery

·         Reservations

·         Payments

·         Notification

·         Orders

·         Website

·         Menu

·         Restaurant

Chapter Name :-Domain Building blocks

Domain Activities

Question 1 : The following are types of activities in Domain Driven Design:

·         Statements

·         Events

·         Queries

·         Suppositions

·         Reports

·         Commands

·         Directives

Note: Make sure you select all of the correct options—there may be more than one!

 

Question 2: Which type of activity is a request to perform an action?

·         Ask

·         Statement

·         Directive

·         Command

Question3 : True or False: A command represents an established fact in your system.

·         True

·         False

Question 4 : True or False: Commands can never be rejected.

·         True

·         False

Question 5 : If accepted and executed, commands cause:

·         the retrieval of domain data.

·         side effects in every case.

·         a change to the state of the domain.

·         None of above.

Question 6 : Which type of activity represents an action that happened in the past?

·         Incident

·         Suposition

·         Statement

·         Event

Question 7 : True or False: An event represents an established fact in your system.

·         True

·         False

Question 8 : True or False: An event can be rejected or completely wiped from a system.

·         True

·         False

Question 9 : True or False: An event can be broadcasted to many destinations within a system.

·         True

·         False

Question 10 : What are some characteristics of events in Domain Driven Design?

·         Have one or more attendees.

·         Are always line items in logs.

·         Often result of command.

·         Represent business process failures.

·         Record changes to domain state.

Question 11 : What are some examples of events?

·         Cook meal

·         Order inventory

·         Record customer order

·         Drink served

·         Generate sales report

·         List all customer orders

Question 12 : Which type of activity represents a request for information about the domain?

·         Finder

·         They can be ignored, never providing an response.

·         They never result in changes to the domain state.

·         Represent the method of asking another part of the system to do something.

·         Are usually delivered to specific destiniations with the system.

Question 15 : What are some examples of queries?

·         Create Order

·         Get all reservations

·         Get customer order

·         Generate sales report

·         Payment processed

·         Find all drinks served to customer

Question 16 : Commands, Events and Queries are what in Reactive Systems?

·         UI Components

·         Log Entries

·         Messages

·         Methods

Question 17: True or False: A bounded context API is comprised of Commands, Events and Queries.

·         True

·         False

 

 

 

 

 

 Course Name :- Reactive Architecture: Domain Driven Design

Chapter Name:- Domain Driven Design

Question 1 : True or False: Many of the guidelines and rules in Domain Driven Design are compatible with those in Reactive Architecture.

·         True

·         False

Question 2: What are some key goals of Domain Driven Design?

·         Provide isolation for software designers to create models of domain processes without the bias or experience of business domain experts.

·         Take a large domain or system and break it down into smaller pieces or subsections.

·         Make domain model design the sole responsibility of domain experts.

·         Create communication channels between domain experts and software developers.

·         None of above.

Question 3 : True or False: Often a single all-inclusive model of a very large domain can contain much, and at times overwhelming, complexity. Breaking those large domains into smaller pieces can result in making the complexity more manageable and understandable.

·         True

·         False

Question 4 :If we break down a large domain into smaller pieces we need to:

·         Clearly determine the boundaries of the smaller pieces and how each piece does or doesn’t interact with the other pieces in the larger domain.

·         Design a model that puts the pieces back to get into a single understandable domain. This results in changes to the business or organization processes.

·         Do nothing more. Simply breaking the domain into pieces is enough.

 What is a Domain 

Question 1: In the world of software architecture and development a domain can be discribed as:

  • The portion of a URL that identifies the name of a website.
  • a repository where code is packaged and stored.
  • referring to the core group of developers in a given Agile team.
  • referring to a business or idea that we are trying to model.

Question 2: Typical domain experts in an insurance company are:

  • QA Tester
  • Claims Adjuster
  • Claims Clerk
  • Server Sys Admin
  • Sales Agent
  • Java Engineer

Question 3: True or False: A domain model is part of the software application.

  • True
  • False

Question 4 : True or False: Domain experts should be able to easily understand the domain model.

  • True
  • False

Question 5 : The name of the form of communication that domain experts and software developers can understand is:

  • Domain Terminolgy
  • Universal Language
  • Ubiqutous Language
  • Common Vernacular

Question 6 : True or False: Domain Experts provide language that is used in the software, and software developers provide language that is used in the domain. Both provide input in equal proportions.

  • True
  • False

Question 7 : True or False: If developers find a process or abstraction in a domain that doesn’t appear to have a name, the developers should talk to the domain experts about whether it already exists or co-create a new term to discribe it.

  • True
  • False

Case Study :Reactive BBQ Domain

Question 1 : Which of the following people represent Domain Experts for the Reactive BBQ?

  • Software Developers building the new system
  • The person washing the dishes.
  • The CEO
  • Software Developers maintaining the old system
  • The Corporate Head Chef
  • The Operations team responsible for deploying the software in production.
  • The Chefs and Cooks in the restaurants
  • The Serving Staff (Servers)

Note: Make sure you select all of the correct options—there may be more than one!

Question 2: While building the new system, we need to define a term that indicates when an order has been completed by a server, and is being sent to the kitchen to be cooked. The best people to ask about the right term are:

  • The Dictionary
  • The Servers
  • The Software Developers
  • The CEO

Question 3: Which of the following are terms you would find in the Reactive BBQ Ubiquitous Language?

  • Table, Row, Column
  • Host, Server, Cook
  • Reservation, Order, Delivery
  • Account, Transaction, Deposit
  • Inventory, Work Schedule, Wage

Chapter Name :- Decomposing the Domain

Question 1: Sub domains are created by:

·         Dividing our code into equal manageable subdomain chunks, usually based on a division of total application lines of code.

·         Grouping related business ideas, actions and rules into separate subdomains.

·         Grouping all interface code, all persistence code and all business logic code into three code subdomains.

·         Grouping isolated data (for example, all Customer data) that will go into separate persistence stores.

Question 2 : True or False: It is impossible for a concept (such as Order or Customer) to exist in multiple sub domains.

·         True

·         False

Question 3: True or False: If we do find a concept (such as Order or Customer) that appears to exist in multiple subdomains, we are defining the concept at too low a level and thus need to define the concept at a higher level of abstraction.

·         True

·         False

Question 4 : True or False: Each subdomain has its own ubiqutious language.

·         True

·         False

Question 5 : True or False: Terms in the ubiquitous language are never shared between subdomains.

·         True

·         False

Question 6 : The bounded context is:

·         A technique to constrain the business activities so they resemble well defined method calls.

·         The ubiqutious language and model of a subdomain.

·         The ubiqutious languages and models of all subdomains.

·         A namespace within our application that is tightly restricted in scope.

Question 7 : True or False: When initially defining microservices, it’s often a good idea to start with your bounded contexts: one bounded context = one microservice.

·         True

·         False

Question8:  True or False: One bounded context always equals one, and only one, microservice.

·         True

·         False

Question9:  True or False: From one bounded context to another the meaning of a word or concept, for example Customer, may dramatically change.

True

False

Question 10 : What are some guidelines we can use to determine a bounded context?

·         Business strategic goals always identify bounded contexts.

·         Consider human interactions and communication that seem to form a subculture within a broader organization.

·         Bounded contexts are often found in business marketing matierials, particularly online ads.

·         Look for changes in the ubiqutous language.

·         Job classifications within organizational subgroupings might suggest various bounded contexts.

·         A clear grouping of business processes and workflows could point to a bounded context.

·         None of the above.

Note: Make sure you select all of the correct options—there may be more than one!

 

Question 11: Event First Domain Driven Design identifies bounded contexts by looking for activities or events that occur in the domain. What are some examples of activities or events?

·         The delivery app logs all deliveries.

·         Customer makes a reservation.

·         Server places an order.

·         Database commits a order payment.

·         None of the above.

Note: Make sure you select all of the correct options—there may be more than one!

 

 Case StudyDomain Activities

 

Question1 : Based on this interview, Which of the following represent activities performed by the Server?

·         Server cooks food for customer

·         Server helps guests understand the menu

·         Server adds item to order

·         Server collects payment

·         Server takes food to customer

·         Server takes reservation for customer

Note: Make sure you select all of the correct options—there may be more than one!

 

Question2  : Based on this interview, Which of the following represent activities performed by the Driver?

·         Driver sets status flag on order to “delivered”.

·         Driver receives delivery notification

·         Driver picks up food for delivery

·         Driver collects payment

Note: Make sure you select all of the correct options—there may be more than one

 

Maintaining Purity 

Question 1: True or False: Concepts in one bounded context should always mean the same thing in another bounded context. Thus, there is no need to translate concepts between bounded contexts.

·         True

·         False

Question 2 :If we always treated a concept, for example Customer, exactly the same across many different bounded contexts, we may introduce:

·         redundancy into our system.

·         parralellism into our system.

·         coupling between contexts in our system.

·         sameness into our system.

Question 3 : We can prevent one bounded context from leaking into another by using a:

·         Anti-Corruption Layer.

·         Rule that says one context never communicates with another.

·         Access Control List.

·         Context Leak Prevention Layer

·         None of above.

Question 4 : Why is it a good idea to use an abstract interface for an Anti-Corruption Layer?

·         Because interfaces are common across all major programming languages and as such are a common way to implement patterns.

·         The abstract interface is the Anti-Corruption equivalent of a Enterprise Road-Check pattern. The Enterpise Road-Check pattern dictates that you can’t go to another location without going through the check.

·         Because an Anti-Corruption Layer is a way of interacting between bounded conexts.

·         The abstract interface can be a pure domain representation, while concrete classes extending the interface can be specific infrastructure implementations. This keeps the core job of the Anti-Corruption layer (stating what it does or provides) without locking into the specific system details needed to do it.

Question 5: True or False: We avoid using Anti-Corruption Layers when our bounded contexts interact with legacy systems. Our bounded contexts should mirror the legacy system interface.

·         True

·         False

Question 6 : True or False: Its sometimes neccessary to have Anti-Corruption layers on both sides of the interaction between bounded contexts or a bounded context and legacy system.

·         True

·         False

 

Case Study :- Bounded Contexts 

Question 1: Which of the following is NOT a candidate for an object in the activities we defined for the host?

·         Host

·         Customer

·         Reservation

Question 2: After analyzing the Server interview we have come up with a set of activities. For example:

·         Server

·         Server takes an Order

·         Server delivers an Order

·         Server collects Payment for an Order

·         Server Objects

Question 3 : Which of the following is NOT a candidate for an object in the activities we defined for the host?

·         Delivery

·         Payment

·         Order

Question 4 : After analyzing the Online Customer interview we have come up with a set of activities. For example:

·         Online Customer

·         Online Customer adds Menu items to an Order

·         Online Customer makes Payment for an Order

·         Online Customer Makes Reservation

·         Online Customer Objects

Question 5 : For the following activities, what is a possible object in the sentence:

 

·         Online Customer adds Menu items to an Order

·         Online Customer makes Payment for an Order

·         Online Customer Makes Reservation

Question 6 : After analyzing interviews from a number of different domain experts we have come up with the following activities:

·         Host

·         Host checks current Reservations

·         Host creates Reservation for a Customer

·         Host seats Customer with Reservation

·         Server

·         Server takes an Order

·         Server delivers an Order

·         Server collects Payment for an Order

·         Bartender

·         Bartender takes a Drink Order

·         Bartender prepares a Drink Order

·         Bartender delivers a Drink Order

·         Bartender collects Payment for a Drink Order

·         Cook/Chef

·         Cook prepares an Order

·         Cook notifies Server an Order is complete.

·         Chef inspects Orders

·         Delivery Driver

·         Driver picks an Order up at the restaurant

·         Driver delivers an Order to Customer

·         Driver collects Payment for an Order

·         Online Customer

·         Online Customer adds Menu items to an Order

·         Online Customer makes Payment for an Order

·         Online Customer Makes ReservationWhile it’s not comprehensive, the list of objects in our activities make good candidates for Bounded Contexts.

 Question 7 : Based on the objects defined in the activities above, which of the following are possible candidates for Bounded Contexts?

·         Delivery

·         Reservations

·         Payments

·         Notification

·         Orders

·         Website

·         Menu

·         Restaurant

Chapter Name :-Domain Building blocks

Domain Activities

Question 1 : The following are types of activities in Domain Driven Design:

·         Statements

·         Events

·         Queries

·         Suppositions

·         Reports

·         Commands

·         Directives

Note: Make sure you select all of the correct options—there may be more than one!

 

Question 2: Which type of activity is a request to perform an action?

·         Ask

·         Statement

·         Directive

·         Command

Question3 : True or False: A command represents an established fact in your system.

·         True

·         False

Question 4 : True or False: Commands can never be rejected.

·         True

·         False

Question 5 : If accepted and executed, commands cause:

·         the retrieval of domain data.

·         side effects in every case.

·         a change to the state of the domain.

·         None of above.

Question 6 : Which type of activity represents an action that happened in the past?

·         Incident

·         Suposition

·         Statement

·         Event

Question 7 : True or False: An event represents an established fact in your system.

·         True

·         False

Question 8 : True or False: An event can be rejected or completely wiped from a system.

·         True

·         False

Question 9 : True or False: An event can be broadcasted to many destinations within a system.

·         True

·         False

Question 10 : What are some characteristics of events in Domain Driven Design?

·         Have one or more attendees.

·         Are always line items in logs.

·         Often result of command.

·         Represent business process failures.

·         Record changes to domain state.

Question 11 : What are some examples of events?

·         Cook meal

·         Order inventory

·         Record customer order

·         Drink served

·         Generate sales report

·         List all customer orders

Question 12 : Which type of activity represents a request for information about the domain?

·         Finder

·         Command

·         Report

·         Query

Question 13 : True or False: A query can be rejected, returning no response at all.

·         True

·         False

Question 14 : What are some characteristics of queries in Domain Driven Design?

·         They always result in changes to the domain state.

·         They can be ignored, never providing an response.

·         They never result in changes to the domain state.

·         Represent the method of asking another part of the system to do something.

·         Are usually delivered to specific destiniations with the system.

Question 15 : What are some examples of queries?

·         Create Order

·         Get all reservations

·         Get customer order

·         Generate sales report

·         Payment processed

·         Find all drinks served to customer

Question 16 : Commands, Events and Queries are what in Reactive Systems?

·         UI Components

·         Log Entries

·         Messages

·         Methods

Question 17: True or False: A bounded context API is comprised of Commands, Events and Queries.

·         True

·         False

 

 

 

 

 

 

About Machine Learning

Check Also

Python for Data Science Cognitive Class Exam Answers:-

Course Name:- Python for Data Science Module 1. Python Basics Question 1. What is the …

Leave a Reply

Your email address will not be published. Required fields are marked *