Flows between ocean and marginal sea basins are often connected by narrow channels and shallow sills. In this study, we address the effect of lateral and vertical geometric constrictions on mixing and hydraulic control. We conduct a set of numerical experiments of the lock-exchange problem in the presence of lateral and vertical contractions. Large eddy simulations (LES) are carried out using the high-order non-hydrostatic spectral element model Nek5000. A spanwise-averaged 2D non-hydrostatic model, denoted SAM, is also employed. Comparison between 2D and 3D models are conducted on the basis of the shape of the density interface and the time evolution of the background potential energy that quantifies the cumulative effects of the stratified mixing in the system.