Measuring network resilience through connection patterns