Chapter 8: APIs and Microservice Management
In this chapter, you will learn about APIs and microservice management. So far, we have deployed ML applications that are served as APIs. Now we will look into how to develop, organize, manage, and serve APIs. You will learn the principles of API and microservice design for ML inference so that you can design your own custom ML solutions.
In this chapter, we will learn by doing as we build a microservice using FastAPI and Docker and serve it as an API. For this, we will go through the fundamentals of designing an API and microservice for an ML model trained previously (in Chapter 4, Machine Learning Pipelines). Lastly, we will reflect on some key principles, challenges, and tips to design a robust and scalable microservice and API for test and production environments. The following topics will be covered in this chapter:
- Introduction to APIs and microservices
- The need for microservices for ML
- Old is gold – REST...