Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The writing is slow #2

Open
ascarhon-atahujaev opened this issue Sep 9, 2019 · 2 comments
Open

The writing is slow #2

ascarhon-atahujaev opened this issue Sep 9, 2019 · 2 comments

Comments

@ascarhon-atahujaev
Copy link

Can you please tell why the library for writing from BigqueryToSpanner is very slow? About 20 records per second. Should I generate template with additional options to improve performance of library/

@orfeon
Copy link
Member

orfeon commented Sep 10, 2019

20 cases per second is certainly slow.
In my case, I insert 1 million records in about 10 minutes (total Dataflow job).
Do you know where the bottleneck is in the Dataflow step?
As a cause of slowness, the write processing on the Spanner side may be a bottleneck.
Whether Spanner is a bottleneck can be confirmed by the CPU usage rate of the Spanner console.
If the rate is higher than 80% you need to increase the number of instances of Spanner.

@ascarhon-atahujaev
Copy link
Author

Solved!
The problem was with incorrect data i was trying to write into spanner (in my case it was a duplicate combined primary key). Now, with correct primary keys, it is loading into spanner about 3 milliions per 8 minutes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants