-
Notifications
You must be signed in to change notification settings - Fork 364
Notes on V3 Architecture
Due to the complexity of heavily metaprogrammed systems, the CAPI team decided to follow a set of simple repeatable patterns in V3 that once understood, can be used to create and extend the system easily.
The following objects are a result of inspiration from principles such Single Responsibility Principle and Loose Coupling.
The message object is responsible for all user supplied parameter validations, and turning them into a data object that can be used by subsequent object within the request cycle to perform desired actions.
The fetcher object’s responsibility is to get the record(s) from the database. It also handles filtering based on the query parameters supplied by the user.
In requests where an action needs to be performed, such as a creation, deletion, or updating of a resource, an action object is used. Because Cloud Controller has a lot of hierarchies in its associations, having a separate action object focuses all of related operations to happen in a single object.
The presenter object handles the final representation that results in the response for the user’s request. It implements a to_hash
method that when supplied to the render method in ActionController, results in rendering JSON.
-
Pipelines
-
Contributing
- Tips and Tricks
- Cloud Controller API v3 Style Guide
- Playbooks
- Development configuration
- Testing
-
Architectural Details
-
CC Resources
- Apps
- Audit Events
- Deployments
- Labels
- Services
- Sidecars
-
Dependencies
-
Troubleshooting
- Ruby Console Script to Find Fields that Cannot Be Decrypted
- Logging database queries in unit tests
- Inspecting blobstore cc resources and cc packages(webdav)
- How to Use USR1 Trap for Diagnostics
- How to Perf: Finding and Fixing Bottlenecks
- How to get access to mysql database
- How To Get a Ruby Heap Dumps & GC Stats from CC
- How to curl v4 internal endpoints with mtls
- How to access Bosh Director console and restore an outdated Cloud Config
- Analyzing Cloud Controller's NGINX logs using the toplogs script
-
k8s
-
Archive