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

How to make a full initial copy #2

Open
ricardolimaui opened this issue Jan 11, 2021 · 1 comment
Open

How to make a full initial copy #2

ricardolimaui opened this issue Jan 11, 2021 · 1 comment

Comments

@ricardolimaui
Copy link

Hello, thank you for the work.

There is any way to make an inicial copy?

I'am getting this error
Pushing data to elasticsearch with id 8273781237127321783
(node:3222) UnhandledPromiseRejectionWarning: ResponseError: illegal_argument_exception

Any idea of this? I changed the name of the collection to be compatible to mine.
It is initialising correctly because I have "connected successfully!!".

It is really necessary to configure the tokens ?

Thank you

@montumodi
Copy link
Owner

Is there any way to make an initial copy?
[AM]: There are many ways to deal with this

  • Simplest and hacky way is to make a change to each document like an empty string etc which can trigger a change and will sync to elastic search.
  • Take out the logic which inserts in to elastic search into a separate component and build something which reads records one by one and execute that piece of code. This is the recommended way.

(node:3222) UnhandledPromiseRejectionWarning: ResponseError: illegal_argument_exception
[AM]: Worth putting the code in try catch and see what is the exact error you are seeing.

It is really necessary to configure the tokens ?
[AM]: It is not necessary. It is only required when you change stream stops for some reason and you need a way to resume it. This is again recommended way. Mongo 4+ onwards you can resume as per dates as well so no need to maintain resume tokens.

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