Пример #1
0
 def subscriber_api(self):
     """Helper for subscriber-related API calls."""
     if self._subscriber_api is None:
         if self._use_gax:
             if self._connection.in_emulator:
                 generated = make_gax_subscriber_api(
                     host=self._connection.host)
             else:
                 generated = make_gax_subscriber_api(
                     credentials=self._credentials)
             self._subscriber_api = GAXSubscriberAPI(generated, self)
         else:
             self._subscriber_api = JSONSubscriberAPI(self)
     return self._subscriber_api
Пример #2
0
 def subscriber_api(self):
     """Helper for subscriber-related API calls."""
     if self._subscriber_api is None:
         if self._use_grpc:
             if self._connection.in_emulator:
                 generated = make_gax_subscriber_api(
                     host=self._connection.host)
             else:
                 generated = make_gax_subscriber_api(
                     credentials=self._credentials)
             self._subscriber_api = GAXSubscriberAPI(generated, self)
         else:
             self._subscriber_api = JSONSubscriberAPI(self)
     return self._subscriber_api
Пример #3
0
 def subscriber_api(self):
     """Helper for subscriber-related API calls."""
     if self._subscriber_api is None:
         if self._use_gax:
             generated = make_gax_subscriber_api(self._connection)
             self._subscriber_api = GAXSubscriberAPI(generated, self)
         else:
             self._subscriber_api = JSONSubscriberAPI(self)
     return self._subscriber_api
Пример #4
0
 def subscriber_api(self):
     """Helper for subscriber-related API calls."""
     if self._subscriber_api is None:
         if self._use_gax:
             generated = make_gax_subscriber_api(self._connection)
             self._subscriber_api = GAXSubscriberAPI(generated, self)
         else:
             self._subscriber_api = JSONSubscriberAPI(self)
     return self._subscriber_api
    def _call_fut(self, *args, **kwargs):
        from google.cloud.pubsub._gax import make_gax_subscriber_api

        return make_gax_subscriber_api(*args, **kwargs)
 def _call_fut(self, connection):
     from google.cloud.pubsub._gax import make_gax_subscriber_api
     return make_gax_subscriber_api(connection)
Пример #7
0
    def _call_fut(self, connection):
        from google.cloud.pubsub._gax import make_gax_subscriber_api

        return make_gax_subscriber_api(connection)
Пример #8
0
 def _call_fut(self, *args, **kwargs):
     from google.cloud.pubsub._gax import make_gax_subscriber_api
     return make_gax_subscriber_api(*args, **kwargs)