@snippet
def sink_bigquery(client, to_delete):
 dataset = _sink_bigquery_setup(client)
 to_delete.append(dataset)
 SINK_NAME = ('robots-bigquery-%d' % (_millis(),))
 FILTER = 'textPayload:robot'
 DESTINATION = ('bigquery.googleapis.com%s' % (dataset.path,))
 sink = client.sink(SINK_NAME, filter_=FILTER, destination=DESTINATION)
 assert (not sink.exists())
 sink.create()
 assert sink.exists()
 to_delete.insert(0, sink)

@ snippet def sink_bigquery ( client , to_delete ) : dataset = _sink_bigquery_setup ( client ) to_delete . append ( dataset ) SINK_NAME = ( 'robots-bigquery-%d' % ( _millis ( ) , ) ) FILTER = 'textPayload:robot' DESTINATION = ( 'bigquery.googleapis.com%s' % ( dataset . path , ) ) sink = client . sink ( SINK_NAME , filter_ = FILTER , destination = DESTINATION ) assert ( not sink . exists ( ) ) sink . create ( ) assert sink . exists ( ) to_delete . insert ( 0 , sink )
sink log entries to bigquery .