Skip to content

Commit

Permalink
debug pt.3: DoInitialSnapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
heavycrystal committed Dec 10, 2024
1 parent b8481f9 commit 6debc5d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions flow/e2e/clickhouse/peer_flow_ch_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -677,14 +677,14 @@ func (s ClickHouseSuite) Test_Types_CH() {
}

_, err := s.Conn().Exec(context.Background(), fmt.Sprintf(`
CREATE TABLE IF NOT EXISTS %s(id serial PRIMARY KEY,c1 BIGINT,c2 BIT,c3 VARBIT,c4 BOOLEAN,
CREATE TABLE IF NOT EXISTS %[1]s(id serial PRIMARY KEY,c1 BIGINT,c2 BIT,c3 VARBIT,c4 BOOLEAN,
c6 BYTEA,c7 CHARACTER,c8 varchar,c9 CIDR,c11 DATE,c12 FLOAT,c13 DOUBLE PRECISION,
c14 INET,c15 INTEGER,c16 INTERVAL,c17 JSON,c18 JSONB,c21 MACADDR,c22 MONEY,
c23 NUMERIC,c24 OID,c28 REAL,c29 SMALLINT,c30 SMALLSERIAL,c31 SERIAL,c32 TEXT,
c33 TIMESTAMP,c34 TIMESTAMPTZ,c35 TIME,c36 TIMETZ,c37 TSQUERY,c38 TSVECTOR,
c39 TXID_SNAPSHOT,c40 UUID,c42 INT[], c43 FLOAT[], c44 TEXT[], c45 mood, c46 HSTORE,
c47 DATE[], c48 TIMESTAMPTZ[], c49 TIMESTAMP[], c50 BOOLEAN[], c51 SMALLINT[], c52 NUMERIC);
INSERT INTO %s SELECT 2,2,b'1',b'101',
INSERT INTO %[1]s SELECT 2,2,b'1',b'101',
true,random_bytea(32),'s','test','1.1.10.2'::cidr,
CURRENT_DATE,1.23,1.234,'10.0.0.0/32'::inet,1,
'5 years 2 months 29 days 1 minute 2 seconds 200 milliseconds 20000 microseconds'::interval,
Expand All @@ -701,7 +701,7 @@ func (s ClickHouseSuite) Test_Types_CH() {
'{"2020-01-01 01:01:01+00", "2020-01-02 01:01:01+00"}'::timestamptz[],
'{"2020-01-01 01:01:01", "2020-01-02 01:01:01"}'::timestamp[],
'{true, false}'::boolean[],
'{1, 2}'::smallint[];`, srcFullName, srcFullName))
'{1, 2}'::smallint[];`, srcFullName))
require.NoError(s.t, err)

connectionGen := e2e.FlowConnectionGenerationConfig{
Expand All @@ -710,6 +710,7 @@ func (s ClickHouseSuite) Test_Types_CH() {
Destination: s.Peer().Name,
}
flowConnConfig := connectionGen.GenerateFlowConnectionConfigs(s.t)
flowConnConfig.DoInitialSnapshot = true

tc := e2e.NewTemporalClient(s.t)
env := e2e.ExecutePeerflow(tc, peerflow.CDCFlowWorkflow, flowConnConfig, nil)
Expand Down

0 comments on commit 6debc5d

Please sign in to comment.