We have a bail program in Canada that actually works with respect to detention. Interestingly, it's one that other countries actually seek to emulate.
The mandatory detention of large-scale arrivals has been modelled, I presume, on the Australian example. Australia has found that not only is it bad from a human rights perspective, but it doesn't have the desired objective of deterring future boat arrivals. So it's a failed policy. Australia has actually moved away from it.
As I said, the Canadian practice of facilitating various conditions of release seems to be the one that other countries are seeking to follow.