Esempio n. 1
0
 def expand(self, pcoll):
     """
     Implements class: `apache_beam.transforms.ptransform.PTransform.expand`
     """
     print 'Starting Spotify API read'
     LOGGER.setLevel(logging.INFO)
     LOGGER.info('Starting Spotify API read')
     return pcoll | iobase.Read(self._source)
Esempio n. 2
0
 def expand(self, pcoll):
     return pcoll | iobase.Read(_CountingSource(count))
Esempio n. 3
0
 def expand(self, pcoll):
     return pcoll | iobase.Read(self._mongo_source)
 def expand(self, pcoll):
     """Implements :class:`~apache_beam.transforms.ptransform.PTransform.expand`"""
     logger.info('Starting MongoDB read from {}.{} with query {}'.format(
         self._db, self._coll, self._query))
     return pcoll | iobase.Read(self._source)
Esempio n. 5
0
 def expand(self, pcoll: PCollection) -> PCollection:
     return pcoll | iobase.Read(
         MySQLSource(self._query, self._host, self._database, self._user,
                     self._password, self._port, self._splitter))
 def expand(self, pvalue):
     return pvalue.pipeline | iobase.Read(self._source)