久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    <bdo id='U6vEO'></bdo><ul id='U6vEO'></ul>
<i id='U6vEO'><tr id='U6vEO'><dt id='U6vEO'><q id='U6vEO'><span id='U6vEO'><b id='U6vEO'><form id='U6vEO'><ins id='U6vEO'></ins><ul id='U6vEO'></ul><sub id='U6vEO'></sub></form><legend id='U6vEO'></legend><bdo id='U6vEO'><pre id='U6vEO'><center id='U6vEO'></center></pre></bdo></b><th id='U6vEO'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='U6vEO'><tfoot id='U6vEO'></tfoot><dl id='U6vEO'><fieldset id='U6vEO'></fieldset></dl></div>
  • <tfoot id='U6vEO'></tfoot>
  • <legend id='U6vEO'><style id='U6vEO'><dir id='U6vEO'><q id='U6vEO'></q></dir></style></legend>

        <small id='U6vEO'></small><noframes id='U6vEO'>

        如何使用 Debezium 從 MS SQL 將 250 個表攝取到 Kafk

        How to ingest 250 tables into Kafka from MS SQL with Debezium(如何使用 Debezium 從 MS SQL 將 250 個表攝取到 Kafka)
          <tbody id='yaX7p'></tbody>
        <i id='yaX7p'><tr id='yaX7p'><dt id='yaX7p'><q id='yaX7p'><span id='yaX7p'><b id='yaX7p'><form id='yaX7p'><ins id='yaX7p'></ins><ul id='yaX7p'></ul><sub id='yaX7p'></sub></form><legend id='yaX7p'></legend><bdo id='yaX7p'><pre id='yaX7p'><center id='yaX7p'></center></pre></bdo></b><th id='yaX7p'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='yaX7p'><tfoot id='yaX7p'></tfoot><dl id='yaX7p'><fieldset id='yaX7p'></fieldset></dl></div>

            • <small id='yaX7p'></small><noframes id='yaX7p'>

            • <legend id='yaX7p'><style id='yaX7p'><dir id='yaX7p'><q id='yaX7p'></q></dir></style></legend>
              <tfoot id='yaX7p'></tfoot>

              • <bdo id='yaX7p'></bdo><ul id='yaX7p'></ul>
                1. 本文介紹了如何使用 Debezium 從 MS SQL 將 250 個表攝取到 Kafka的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我嘗試在 PostgreSQL 之間構建 Kafka 連接管道作為源到 SQL Server 作為目標.我使用了 3 個 Kafka broker,需要消費 252 個主題(一個主題與一張 PostgreSQL 表相同).運行一個多小時后,252張表中只能拉出218張.我發(fā)現的錯誤是 SQL Server 中存在死鎖機制,可以將事務保存到 SQL Server 并嘗試重試,Debezium 復制槽也已存在.

                  Hi i have try to build Kafka connect pipeline between PostgreSQL as source to SQL Server as the destination. I used 3 Kafka brokers, and need to consume 252 topics (one topics same as one PostgreSQL table). After run for more than an hour, it only can pull 218 out of 252 tables. The error that i found is there's deadlock mechanism in SQL Server which can hold transaction to SQL Server and try to retry it, also Debezium replication slot has been there.

                  我在接收器上使用最多 3 個工人的分布式連接器,但也許這似乎還不夠.還可以嘗試使用更高的 offset.time_out.ms 到 60000 和更高的偏移分區(qū) (100).恐怕這不是我想要的生產水平.任何人都可以就此案提出建議嗎?是否有任何計算可以確定我需要的最佳工人數量?

                  I use distributed connectors with 3 max worker on sink, but maybe it seems not enough. Also try with higher offset.time_out.ms to 60000 and higher offset partition (100). I'm afraid that this is not an production level that i want. Anyone can give suggestion about this case? Is there any calculation to decide best number of workers that i need?

                  更新

                  這里出現了一些錯誤.我看到一些連接器被殺死了.有人告訴我 死鎖發(fā)生在 SQL SERVER 中 :

                  here some error i get. I see some connectors are killed. One tell me that deadlock happen in SQL SERVER :

                  [2020-03-26 15:06:28,494] ERROR WorkerSinkTask{id=sql_server_sink_XXA-0} RetriableException from SinkTask: (org.apache.kafka.connect.runtime.WorkerSinkTask:552)
                  org.apache.kafka.connect.errors.RetriableException: java.sql.SQLException: com.microsoft.sqlserver.jdbc.SQLServerException: Transaction (Process ID 62) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
                  
                      at io.confluent.connect.jdbc.sink.JdbcSinkTask.put(JdbcSinkTask.java:93)
                      at org.apache.kafka.connect.runtime.WorkerSinkTask.deliverMessages(WorkerSinkTask.java:539)
                      at org.apache.kafka.connect.runtime.WorkerSinkTask.poll(WorkerSinkTask.java:322)
                      at org.apache.kafka.connect.runtime.WorkerSinkTask.iteration(WorkerSinkTask.java:224)
                      at org.apache.kafka.connect.runtime.WorkerSinkTask.execute(WorkerSinkTask.java:192)
                      at org.apache.kafka.connect.runtime.WorkerTask.doRun(WorkerTask.java:177)
                      at org.apache.kafka.connect.runtime.WorkerTask.run(WorkerTask.java:227)
                      at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
                      at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
                      at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
                      at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
                      at java.base/java.lang.Thread.run(Thread.java:834)
                  Caused by: java.sql.SQLException: com.microsoft.sqlserver.jdbc.SQLServerException: Transaction (Process ID 62) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
                  

                  2020 年 4 月 14 日更新

                  我仍然有這個問題,我忘了告訴我如何部署連接器.現在我使用 2 個工人,一個用于源,一個用于接收器.我在 csv 中列出我的所有表和 pk 并循環(huán)遍歷行以創(chuàng)建連接器而無需睡眠或等待每分鐘.我還為每個主題使用單個主題分區(qū)和 3 個副本.但是我仍然有sql server連接死鎖

                  I still have problem with this, i forgot to tell about how i deploy the connectors. Now i use 2 workers, one for source and one for sink. I list all of my tables and pk in an csv and loop through rows to create the connectors without sleep or wait for every minutes. I also use single topics partition and 3 replica for each topics. But i still have sql server connection deadlock

                  推薦答案

                  問題可能是同時訪問多個任務的同一個 SQL 表,并導致同步問題,如您提到的死鎖.
                  由于您已經擁有大量主題,并且您的連接器可以并行訪問它們,我建議您將每個主題的分區(qū)數減少到 1(減少分區(qū)數在Kafka,因此您應該刪除并使用新的分區(qū)數重新創(chuàng)建每個主題).
                  這樣,每個主題只有一個分區(qū);每個分區(qū)只能在單個線程(/task/consumer)中訪問,因此沒有機會對同一個表進行并行 SQL 事務.

                  The problem may be accessing the same SQL table with multiple tasks in the same time and causing synchronization problems like deadlocks as you mentioned.
                  Since you already have a large number of topics, and your connector can access them in parallel, I would suggest you to reduce the number partitions for every topic to just 1 (reduce number of partitions is not supported in Kafka so you should delete and recreate every topic with the new number of partitions).
                  This way, every topic have only one partition; every partition can be accessed only in a single thread(/task/consumer) so there is no chance for parallel SQL transactions to the same table.

                  或者,更好的方法是創(chuàng)建一個包含 3 個分區(qū)的主題(與您擁有的任務/消費者數量相同),并讓 生產者使用 SQL 表名作為消息鍵.
                  Kafka 保證具有相同鍵的消息總是轉到同一個分區(qū),因此具有相同表的所有消息將駐留在單個分區(qū)上(單線程消耗).

                  Alternatively, a better approach is to create a single topic with 3 partitions (same as the number of tasks/consumers you have) and make the producer use the SQL table name as the message key.
                  Kafka guarantees messages with the same key to always go to the same partition, so all the messages with the same table will reside on a single partition (single thread consuming).

                  如果你覺得有用,我可以附上更多關于如何創(chuàng)建 Kafka Producer 和發(fā)送密鑰消息的信息.

                  If you find it useful, I can attach more information about how to create Kafka Producer and send keyed messages.

                  這篇關于如何使用 Debezium 從 MS SQL 將 250 個表攝取到 Kafka的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯(lián)網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯(lián)系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  How to use windowing functions efficiently to decide next N number of rows based on N number of previous values(如何有效地使用窗口函數根據 N 個先前值來決定接下來的 N 個行)
                  reuse the result of a select expression in the quot;GROUP BYquot; clause?(在“GROUP BY中重用選擇表達式的結果;條款?)
                  Does ignore option of Pyspark DataFrameWriter jdbc function ignore entire transaction or just offending rows?(Pyspark DataFrameWriter jdbc 函數的 ignore 選項是忽略整個事務還是只是有問題的行?) - IT屋-程序員軟件開發(fā)技
                  How to integrate Apache Spark with MySQL for reading database tables as a spark dataframe?(如何將 Apache Spark 與 MySQL 集成以將數據庫表作為 Spark 數據幀讀取?)
                  In Apache Spark 2.0.0, is it possible to fetch a query from an external database (rather than grab the whole table)?(在 Apache Spark 2.0.0 中,是否可以從外部數據庫獲取查詢(而不是獲取整個表)?) - IT屋-程序員軟件開
                  Break down a table to pivot in columns (SQL,PYSPARK)(分解表以按列進行透視(SQL、PYSPARK))
                    <bdo id='EoQyB'></bdo><ul id='EoQyB'></ul>

                    <i id='EoQyB'><tr id='EoQyB'><dt id='EoQyB'><q id='EoQyB'><span id='EoQyB'><b id='EoQyB'><form id='EoQyB'><ins id='EoQyB'></ins><ul id='EoQyB'></ul><sub id='EoQyB'></sub></form><legend id='EoQyB'></legend><bdo id='EoQyB'><pre id='EoQyB'><center id='EoQyB'></center></pre></bdo></b><th id='EoQyB'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='EoQyB'><tfoot id='EoQyB'></tfoot><dl id='EoQyB'><fieldset id='EoQyB'></fieldset></dl></div>
                      <tbody id='EoQyB'></tbody>

                    <small id='EoQyB'></small><noframes id='EoQyB'>

                      • <legend id='EoQyB'><style id='EoQyB'><dir id='EoQyB'><q id='EoQyB'></q></dir></style></legend>

                          <tfoot id='EoQyB'></tfoot>

                            主站蜘蛛池模板: 99日韩 | 中文字幕在线一区 | 欧美性久久 | 美女视频黄的 | 国产高清一区二区三区 | 日本淫视频 | 少妇精品亚洲一区二区成人 | 国产精品久久久久久吹潮 | 亚洲三区在线 | 欧美日批 | 91电影在线播放 | 日本不卡高清视频 | av在线一区二区三区 | 久久精品男人的天堂 | 精品久久久久国产 | 中文字幕亚洲视频 | 综合精品 | 一区二区三区在线免费观看 | 草久久 | 紧缚调教一区二区三区视频 | 日韩精品免费 | 99热热精品 | 91天堂| 国产高清视频 | 欧美jizzhd精品欧美巨大免费 | 中文字幕黄色大片 | 亚洲精品免费视频 | 国产精品免费播放 | 成年人网站在线观看视频 | 黄色一级大片在线免费看产 | 国产精品美女在线观看 | 成人在线欧美 | 国产亚洲一区二区三区在线观看 | 欧美a级成人淫片免费看 | 国产成人99久久亚洲综合精品 | 久久国产一区 | 午夜小电影 | 国产三级在线观看播放 | 免费影视在线观看 | 四虎成人免费视频 | 欧美在线小视频 |