MCPcopy Create free account
hub / github.com/mongodb/mongo-python-driver / get

Method get

pymongo/synchronous/pool.py:667–671  ·  view source on GitHub ↗

Get the generation for the given service_id.

(self, service_id: Optional[ObjectId])

Source from the content-addressed store, hash-verified

665 self._generation = 0
666
667 def get(self, service_id: Optional[ObjectId]) -> int:
668 """Get the generation for the given service_id."""
669 if service_id is None:
670 return self._generation
671 return self._generations[service_id]
672
673 def get_overall(self) -> int:
674 """Get the Pool's overall generation."""

Callers 2

staleMethod · 0.95
_helloMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected