Canada is massively better - many routings don't require going through security, leaving only a cursory immigration check (at special transit desks).
Domestic connections do require security, connections to US generally require preclearance security. Connections from most other countries also go through security.
The odd thing is that they don't separate arrivals: so you'll mingle with worldwide arrivals, go through transfer immigration with everyone else, and finally you show your boarding pass and get routed either to the departure gates, or to security, based on your boarding pass.