The first question is who should be able to open the connecting door, and from which side.
Fully separate units. Where the units are rented or occupied independently, the door is normally kept locked, with a lock that each side controls, or with the door secured permanently. Neither household should be able to walk into the other's space.
Family arrangements. In an in-law suite or where grown children live downstairs, the door may be used daily. It still helps to have a lock that each side can use for privacy.
Shared access. Sometimes one unit needs to reach a shared laundry, furnace room or storage area through the connecting door. The lock arrangement then has to allow that access without opening the rest of the other unit.