- Hands-On Microservices with Kubernetes
- Gigi Sayfan
- 200字
- 2021-06-24 13:46:45
The pkg subdirectory
The pkg subdirectory is where all the packages live. It includes the implementation of the microservices, the client libraries, the abstract object model, other support packages, and unit tests. The bulk of the code is in the form of Go packages that are simple to develop and test before they are bundled into actual microservices:
$ tree pkg
pkg
├── link_manager
│ ├── abstract_link_store.go
│ ├── db_link_store.go
│ ├── db_link_store_test.go
│ ├── in_memory_link_store.go
│ ├── link_manager.go
│ └── link_manager_suite_test.go
├── link_manager_client
│ └── client.go
├── object_model
│ ├── README.md
│ ├── interfaces.go
│ └── types.go
├── social_graph_client
│ ├── client.go
│ └── endpoints.go
├── social_graph_manager
│ ├── db_scoial_graph_store.go
│ ├── db_social_graph_manager_test.go
│ ├── in_memory_social_graph_manager_test.go
│ ├── in_memory_social_graph_store.go
│ ├── social_graph_manager.go
│ └── social_graph_manager_suite_test.go
└── user_manager
├── db_user_manager_test.go
├── db_user_store.go
├── in_memory_user_manager.go
├── in_memory_user_manager_test.go
├── in_memory_user_store.go
└── user_manager_suite_test.go