Each microservice can either be stateless or stateful. A system that uses microservices typically has a stateless web and/or mobile application that uses stateless and/or stateful services.
Stateless microservices do not maintain any state within the services across calls. They take in a request, process it, and send a response back without persisting any state information. A stateful microservice persists state in some form in order for it to function.
Rather than store this state internally, a microservice should store state information externally, in some type of data store. Examples of a data store to persist state include a relational database management system (RDBMS), a NoSQL database, or some ...