Estou tentando configurar o Golden Gate para sincronizar os dados com o BigQuery. Quando eu começo a empurrar a carga inicial, meu extrator exportou todos os dados e até mesmo das estatísticas de replicação eu consigo ver que os registros são recebidos, mas não são enviados para o Bigquery.
Extrator
GGSCI (bhuvi-oracle) 12> info extract load1
EXTRACT LOAD1 Last Started 2020-05-07 16:52 Status STOPPED
Checkpoint Lag Not Available
Log Read Checkpoint Table HR.TEST
2020-05-07 16:52:41 Record 32768
Task SOURCEISTABLE
Estatísticas de replicação
GGSCI (bhuvi-1) 1> stats bq
Sending STATS request to REPLICAT BQ ...
gg.handlerlist=bigquery
Start of Statistics at 2020-05-07 16:53:33.
Replicating from HR.TEST to bhuvi_orcl.test:
*** Total statistics since 2020-05-07 16:52:42 ***
Total inserts 32768.00
Total updates 0.00
Total deletes 0.00
Total discards 0.00
Total operations 32768.00
Arquivo de log no BigData Golen Gate:
2020-05-07T16:59:04.895+0000 INFO OGG-00987 Oracle GoldenGate Command Interpreter: GGSCI command (root): start bq.
2020-05-07T16:59:04.904+0000 INFO OGG-00963 Oracle GoldenGate Manager, mgr.prm: Command received from GGSCI on host [10.18.0.61]:42130 (START REPLICAT BQ ).
2020-05-07T16:59:04.905+0000 INFO OGG-00975 Oracle GoldenGate Manager, mgr.prm: REPLICAT BQ starting.
2020-05-07T16:59:04.964+0000 INFO OGG-00995 Oracle GoldenGate Delivery, bq.prm: REPLICAT BQ starting.
2020-05-07T16:59:04.967+0000 INFO OGG-03059 Oracle GoldenGate Delivery, bq.prm: Operating system character set identified as UTF-8.
2020-05-07T16:59:04.967+0000 INFO OGG-02695 Oracle GoldenGate Delivery, bq.prm: ANSI SQL parameter syntax is used for parameter parsing.
2020-05-07T16:59:05.173+0000 INFO OGG-15052 Oracle GoldenGate Delivery, bq.prm: Using Java class path: .:ggjava/ggjava.jar:ggjava/resources/lib/optional/log4j-api-2.9.1.jar:ggjava/resources/lib/optional/log4j-core-2.9.1.jar:ggjava/resources/lib/optional/log4j-slf4j-impl-2.9.1.jar.
2020-05-07T16:59:10.243+0000 INFO OGG-01815 Oracle GoldenGate Delivery, bq.prm: Virtual Memory Facilities for: COM
anon alloc: mmap(MAP_ANON) anon free: munmap
file alloc: mmap(MAP_SHARED) file free: munmap
target directories:
/opt/ogg/dirtmp.
2020-05-07T16:59:10.243+0000 INFO OGG-00996 Oracle GoldenGate Delivery, bq.prm: REPLICAT BQ started.
2020-05-07T16:59:10.251+0000 INFO OGG-02243 Oracle GoldenGate Delivery, bq.prm: Opened trail file /opt/ogg/dirdat/oo000000 at 2020-05-07 16:59:10.249063.
2020-05-07T16:59:10.251+0000 INFO OGG-03506 Oracle GoldenGate Delivery, bq.prm: The source database character set, as determined from the trail file, is UTF-8.
2020-05-07T16:59:10.253+0000 INFO OGG-06505 Oracle GoldenGate Delivery, bq.prm: MAP resolved (entry HR.TEST): MAP "HR"."TEST", TARGET bhuvi_orcl.test.
2020-05-07T16:59:10.253+0000 INFO OGG-02756 Oracle GoldenGate Delivery, bq.prm: The definition for table HR.TEST is obtained from the trail file.
2020-05-07T16:59:10.253+0000 INFO OGG-06511 Oracle GoldenGate Delivery, bq.prm: Using following columns in default map by name: ID.
2020-05-07T16:59:10.253+0000 INFO OGG-06510 Oracle GoldenGate Delivery, bq.prm: Using the following key columns for target table bhuvi_orcl.test: ID.
Eu descobri o que há de errado nisso, na verdade nada de errado. A falha aqui é o mapeamento.
Eu mapeei meus nomes de tabela no arquivo prm como abaixo.
MAP HR.TEST, TARGET bqtest.TEST
Eu estava pensando no conjunto de dados bqtest, posso ver a tabela de teste, mas não é verdade. Goldengate irá converter seu mapeamento como
bqtest_test
. Este é o nome real da tabela. Então você pode ver que esta tabela foi criada automaticamente.