The ColdBox Platform was the first conventions based MVC framework for ColdFusion. It has evolved and become the de-facto standard for building scalable and modern ColdFusion applications. Come learn about hierarchical MVC and modularization to scale your legacy or new applications to a new modern era.
2. WHO AM I?
• Luis Majano - Computer Engineer
• El Salvador
• Houston,Texas
• Computer Engineer
• CEO of Ortus Solutions
• Creator of many boxes
www.ortussolutions.com
@ortussolutions
@lmajano
3. AGENDA
• What is the problem?
• Monolithic Applications
• HMVC
• Modular Architecture
• ColdBox Modules
17. 5. MICROSERVICES
AN APPROACH TO DEVELOPING A SINGLE
APPLICATION AS A SUITE OF SMALL SERVICES,
EACH RUNNING IN ITS OWN PROCESS AND
COMMUNICATING WITH LIGHTWEIGHT
MECHANISMS.
Martin Fowler
23. WHAT IS A MODULE?
"In structured design and data-driven design, a module is a
generic term used to describe a named and addressable
group of program statements”
by Craig Borysowich (ChiefTechnologyTactician)
“A software module is a deployable, manageable, natively
reusable, composable, stateless unit of software that
provides a concise interface to consumers.”
by Kirk Knoernschild
24. MODULAR ARCHITECTURE
• Break up a monolithic application
• Individual logical parts that work in unison
• Separation of concerns
• Reusability concerns
• Manageable dependencies
“As a system evolves, It’s complexity will increase unless work
is done to maintain or reduce it.”
Lehman’s 2nd Law of software evolution
31. MODULECONFIG.CFC
• Simple CFC
• Bootstraps your module
• Must exist in the root of your module folder
• Has public properties
• configure() for configuration
• 2 callback methods: onLoad(), onUnload()
• Tier-detection enabled
• It’s an interceptor too!
33. MODULECONFIG.CFC PROPERTIES
// Module Properties
this.title = "cbswagger";
this.author = "Jon Clausen <jon_clausen@silowebworks.com>";
this.webURL = "https://github.com/coldbox-modules/cbSwagger";
this.description = "Swagger API documentation from your routes";
this.version = "@build.version@+@build.number@";
// If true, looks for views in the parent first, if not found, then in the
module. Else vice-versa
this.viewParentLookup = true;
// If true, looks for layouts in the parent first, if not found, then in module.
Else vice-versa
this.layoutParentLookup = true;
// Module Entry Point
this.entryPoint = "cbswagger";
// Model Namespace
this.modelNamespace = "cbswagger";
// CF Mapping
this.cfmapping = "cbswagger";
// Auto-map models
this.autoMapModels = true;
// Module Dependencies That Must Be Loaded First, use internal names or aliases
this.dependencies = [ "swagger-sdk" ];