HNHacker News
TopNewBestAskShowJobs

tang8330

102 karma · joined April 13, 2016

co-founder of Artie (YC S23)
submissionscomments
tang8330··on Show HN: Artie – Real-time data replication to your warehouse, now self-serve
Great question - there's no Debezium under the hood. Artie has its own Reader and Transfer layers, built from scratch.

TOAST columns: Artie has automatic detection built in. If a TOAST column hasn't changed, its value won't appear in the WAL. Artie detects this and skips the update for that column in the destination. This works without needing to set REPLICA IDENTITY FULL on your tables.

Schema drift: Artie never requires a schema registry. For relational sources like Postgres, Artie reads the source schema directly and syncs new columns immediately. For DDL changes, Artie uses lazy schema evaluation. On the next DML event for the table, it compares source vs. destination schema and applies any outstanding changes before writing the row.

Let me know if you have any other questions!

tang8330··on Deep Dive into Postgres Write-Ahead Logs
Thanks for the flag. We'll get that fixed!
tang8330··on Preventing replication slot overflow on Postgres DB (AWS RDS)
Artie OSS: https://github.com/artie-labs/transfer Artie Cloud: https://www.artie.so/
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
On a single unbounded (CPU + mem) Debezium running on a VM extracting Postgres, I was able to clock in about 7-10m/hr. You could increase the # of tasks, but then it'll hinder your DB perf. Also, this is on your primary DB.

We found it far more efficient and less risky to do CDC streaming and snapshotting w/o read lock in parallel to two different topics. Once snapshot is done and drained, we then move to drain the CDC topic.

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Hi! Yes, our next 2 connectors are going to be S3 and DynamoDB.

GitHub Issue: https://github.com/artie-labs/transfer/issues/157

If you'd like to be another design partner for us on this, do reach out. I'm at robin@artie.so.

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Definitely. For staging temporary tables to merge for our Redshfit destination, we're uploading it to S3.

We will be creating a S3 destination with TSV, Avro, Parquet format support verily soon.

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
For Postgres, we have our own custom snapshotter that is capable of doing parallel snapshots against your read replica and not incur WAL growth. More details here: https://news.ycombinator.com/item?id=36855338

For MySQL and MongoDB, we rely on Debezium to perform the initial snapshots.

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Thank you so much for the support!
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Thanks for the comment!

Your comment regarding DDL is interesting.

Today, this is what happens:

1/ Column doesn't exist in the destination, we'll create it based on our typing inference from the data type (important: not the data value).

2/ Certain tools will handle automatic column data type conversion if a change like this was detected at the source. We do not do this. We will simply hard fail and cause head-of-line blocking reasons being: this is anti-pattern and should be rare, in which case - it's okay to cause an err and require manual intervention for this breaking change.

3/ If the column has been dropped from the source, you as the end user can decide whether this column should be also dropped in the destination, or not. The default is not to drop it.

^ We hear more customers explicitly don't want columns to be dropped because it could cause downstream errors, such as other views / tables not compiling due to referencing a non-existent column.

We haven't heard much from folks that don't even want columns to be added. If there is a need, we can definitely add that as a config option to provide maximum configurability.

> Finally, the biggest issue with CDC always ends up being the seed loads, recoveries and the incremental snapshot strategies.

Yep totally. On the recovery bit, this is exactly why we are leveraging Kafka. If there are any particular issues, we simply don't commit the offset and cause head-of-line blocking.

On the incremental snapshot and recoveries bit, we primarily leverage Debezium's DDD-3 high watermark strategy [1] for MySQL and MongoDB. Postgres has a different issue in that replication slots can grow really fast, esp on AWS! [2]. We ended up writing our own custom snapshotter for Postgres that is Debezium compatible to onboard customers that have a massive dataset and cannot afford to have a read lock on their WAL.

[1] https://github.com/debezium/debezium-design-documents/blob/m... [2] https://www.morling.dev/blog/insatiable-postgres-replication...

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Hm, perhaps I wasn't being clear, apologies for that.

What I am proposing above is ways to provide a view to teams that do not want real-time data while keeping your underlying dataset in real-time.

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Thanks for your feedback!

> Something McKinley doesn't address is that it's quite advantageous if the values in your data warehouse don't change intra-day because this lets business users reach consensus. Whereas if Bob runs a report and gets $X, and Alice runs the same report 5 minutes later and gets $Y, that creates confusion (much more than you would expect). I recall a particular system I built that refreshed every 6 hours (limited by upstream), that eventually Marketing asked me to dial back to every 24 hours because they couldn't stand things changing in the middle of the day.

If they want to see a consistent view of the report, you could bound this.

1/ SELECT * FROM FOO WHERE DATE_TRUNC('day', updated_at) < DATE_TRUNC('day', DATEADD(day, -1, CURRENT_DATE()));

If your dataset doesn't contain kv, you can turn on include `artie_updated_at` which will provide an additional column with the updated_at field to support incremental ingestion.

2/ If you had stateful data, you could also explore creating a Snowflake task and leveraging the time travel f(x) to create a "snapshot" if your workload depended on it.

3/ Also, if you _did_ want this to be more lagged, you can actually increase the flushIntervalSeconds [1] to 6h, 24h, whichever time interval you fancy. You as the customer should have maximum flexibility when it comes to when to flush to DWH.

4/ You can also choose to refresh the analytical report on Looker / Mode to be daily. [2]

> Now of course I see you're targeting more real-time use cases like fraud detection. That's great! But why you would run a fraud detection process out of your data warehouse, which likely doesn't even have a production-grade uptime SLA? Run it out of your production database, that's what it's for!

You can certainly do this in production db (that was our original hypothesis as well!), however, after talking to more companies...it has become more obvious to us that folks that are running fraud algos actually want to join this across various data sets. Further, by using a DWH - it provides a nice visualization layer on top.

Of course, you could go with something even more bespoke by utilizing real-time DBs such as Materialize / Rockset / RisingWave. Just comes with trade offs such as increase in architectural complexity.

There are also plenty of additional use cases this can unlock given that DWH is a platform, any post-DWH application can benefit from less lag, such as reverse ETLs.

[1] https://docs.artie.so/running-transfer/options

[2] https://mode.com/help/articles/report-scheduling-and-sharing...

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
For now, we're super focused on databases as sources. We really want to do this well before we move on to other data sources such as APIs.
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Thank you!!
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Definitely. Do you expect the resulting data to also be in binary / bytes format in your DWH?

I ask because there's a workaround by setting `binary.handling.mode` to a STRING type [1].

Transfer will then automatically pick this up and write this as a B64 string to the DWH.

[1] https://debezium.io/documentation/reference/stable/connector...

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
That's fascinating! Thanks for providing more color, support for geometric shapes coming! https://github.com/artie-labs/transfer/issues/155
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Eventual consistency FTW!
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Main value props are low latency OLTP data in your DWH and lower DWH ingestion costs.
tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Great question! Say this happened:

* CREATE TABLE user_test (id int primary key, name text);

* INSERT INTO user_test (id, name) VALUES (1, 'foo');

* UPDATE user_test set id = 2 where id = 1;

When the UPDATE call is invoked, there will be 2 events emitted to Kafka. 1/ A DELETE event for id = 1

2/ A CREATE event for id = 2

Here's the detailed events that get emitted: https://gist.github.com/Tang8330/7a9450f95fbae486a4393abdd49...

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
For us, what we are striving to do differently is:

1/ DFS vs BFS. We are planning on rolling out connectors slowly vs. building tens / hundreds / thousands of connectors to try to attract a broader set of audiences. Those that have tried to replicate data between OLTP and OLAP know how painful it is and we really want to solve this pain point before we move on to new sources. In addition, we're planning on providing more value than just replicating data from source to destination. We're planning on integrating our telemetry library [1] with Datadog such that customers can: * Centralize all metrics. See Artie metrics without coming to our dashboard, instead it's integrated with your existing tools. * Help provide cookie cutter monitors for anomaly detection * We also want to provide better table quality checks

2/ We do not want to change user behavior. We are using pretty standard tools to solve this problem such as Kafka, Pub/Sub and Red Hat Debezium. If you are already using one of these tools, we can just integrate vs. standing up a whole suite of services just for the data pipeline. * If you have CDC events being emitted for event-driven architecture already, we'll skip deploying Debezium and just deploy our consumer * If you have Kafka enabled and want to also consume CDC events, we'll just deploy Debezium to publish to your Kafka vs. ours.

3/ Ease of use. This goes without saying, but plenty of tools out there have broken links in their documentation, extremely confusing UI, etc. We really look up to Fivetran in this regard and we try to make the onboarding process for new connectors as simple as possible.

Do you think there are anything missing with the other CDC or data replication tools out in the market? Let me know and happy to see how we can help!

[1] https://docs.artie.so/telemetry/overview

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
> Hey, brief feedback, but "5,000,000,000+" rows processed might be a red flag for some. Many individual customers might do this per day, so to say that's all the company has done so far might put them off.

Appreciate the feedback! Totally agree and it's something we are working towards :). We learned a ton from going from nothing -> billions, certain functions, backfill strategies, etc just doesn't work at that scale. I'm sure we'll have another equally exciting learning curve when scaling from B/month -> B/day!

> You've said that initial imports are free, but anecdotally, initial imports ended up being a somewhat regular occurrence as we found issues required a re-import, table rewrites, breaking schema changes, and so on. Do you pay full cost for subsequent full-imports?

Thanks for pointing this out. We plan to make all backfills free of charge.

> Lastly, pricing. I feel like you really need a dollar figure on this even just to start the discussion. "Call us for pricing" is fine for enterprise plans, but in a ~100 person startup I would have just passed immediately on to others that provide pricing details. I'm not going to spend time trialling something without knowing if the pricing is in the right ballpark as it's a waste of my time if it isn't. My perception is that this would be substantially more expensive than batch replication competitors such as Stitch, but I don't know.

Makes sense. A lot of folks think that streaming is more expensive than batched, what we've found with our initial customers is the opposite. Streaming is able to distribute the load to DWH and as a result, customers on Snowflake can use a much smaller vDWH when working with Artie. On the "call us for pricing" front, we are planning to provide a calculator / graph to estimate costs before talking to a human in the future. However, we are learning that a lot of companies have bespoke 1yr/ 2yr contracts with their data provider and are trying to figure out our own pricing and packaging at the moment.

tang8330··on Launch HN: Artie (YC S23) – Real time data replication to data warehouses
Not at the moment, but no reason(s) why we shouldn't. Debezium already supports this [1] and it'd be a minor refactor on our end to support. If that's something you'd want, LMK!

[1] https://debezium.io/documentation/reference/stable/connector...

tang8330··on Artie Transfer: Fast data replication between your database and data warehouse
Hey HN,

We're thrilled to release our public version of Artie Transfer!

Artie Transfer leverages change data capture (CDC) in order to provide the sub-minute latency between transactional DBs and DWHs. Not only is this approach faster than the traditional ETL process, but this is also significantly cheaper if you use a cloud DWH.

Our blog here describes this process in further detail: https://www.artie.so/blog/introducing-artie-transfer

We'd love to hear any feedback on what you all think!

Best, - Robin and Jacqueline