The guidance for database connections is simple and well understood. Open a connection as late as possible and close it as soon as possible. this is of course OK because of connection pooling.
what's the story for Entity Framework contexts? Does the same pattern apply?