<p>I know that deployment uses replicaset underneath it, has revision control, creates another replicaset during rolling upgrade/downgrade.</p>
<p>I want to know what is the scenario in which only replicaset can be used and deployment can't be used.</p>

<p>ReplicaSet's purpose is to maintain a stable set of replica Pods running at any given time and it checks how many pods need to maintain bases on which it creates or deletes the pods. ReplicaSet then fulfills its purpose by creating and deleting Pods as needed to reach the desired number. ReplicaSets can be used independently. With ReplicaSet you define the number of replicas you want to run for a particular service. You would have those many replicas running.</p>
<p>Whereas Deployment is the advancement of replica sets. When you use Deployments you don't have to worry about managing the ReplicaSets that they create. Deployments own and manage their ReplicaSets. As such, it is recommended to use Deployments when you want ReplicaSets. As a replica looks only on creating and deleting the pods. Deployment is recommended for application services and
With deployment you should be able to do rolling upgrades or rollbacks. You can update images from v1 to v2.</p>
<p>Refer to this <a href="https://stackoverflow.com/questions/69448131/kubernetes-whats-the-difference-between-deployment-and-replica-set">SO1</a> , <a href="https://stackoverflow.com/questions/55437390/k8s-why-we-need-replicaset-when-we-have-deployments">SO2</a>  and official documentation of <a href="https://kubernetes.io/docs/concepts/workloads/controllers/replicaset/" rel="nofollow noreferrer">Replicasets</a> and  <a href="https://kubernetes.io/docs/concepts/workloads/controllers/deployment/" rel="nofollow noreferrer">Deployment</a>.</p>
