Does anyone have an idea why would only 1 worker b...
# replication-troubleshooting
d
Does anyone have an idea why would only 1 worker be busy vs. the others? Why would it need 6GB of ram when no sync is active (no job pods are up). Airbyte OSS / EKS / V.40.17
n
Hi, Dudu! What version of Airbyte are you on?
d
@Nataly Merezhuk (Airbyte) Airbyte OSS / EKS / V.40.17
u
That's the Helm chart version, it is not the same as the Airbyte instance version. Could you give me the Airbyte instance version?
d
@Nataly Merezhuk (Airbyte) How do I get that? That’s also the image version.
m
I may be VERY wrong here, but I don't think we can use more than one worker? I mean, airbyte certainly spawns N pods for the source and destinations, but the worker pod won't scale, I think
The same for the other resources, why you have more than one airbyte-server? environments?
d
@Marcelo Pio de Castro Thanks for responding! Why do you think it won’t scale? We got a lot of issues where Airbyte connections were all completely stuck. We tried to understand if adding more of each service will help here. The stats you see above do not make sense to me as we don’t have a lot of load on that instance. FYI @ns
m
Because it wasn't made to really scale that way from what I understand. What really scales is that airbyte will spawn connector pods (both source and destination) that do the heavy lifting. The worker is just responsible to spawn them and control the lifecycle. From my experience, Airbyte doesn't spawn more "airbyte-worker" nodes, and doesn't need them.
I would remove all the other replicas, because I think that could be messing up with the distribution of workers
d
@Marcelo Pio de Castro Appreciate the feedback!
@Marcelo Pio de Castro What I understood is that the data pipe flows between target and source pods via the worker pod. With multiple syncs running at the same time in some case, that could be an issue. not sure though.
✅ 1
m
What I think is happening in your case is that since you have multiple temporals, I think something is getting messed up and all jobs end up on same worker?
There is a MAX_SYNC_JOBS variable that should be configured and that is how a worker will check if it can still receive jobs
So if there is a job large enough, it could be that the worker is consuming a lot, but within the limit of the MAX_SYNC_JOBS
c
@Dudu Vaanunu You are correct. A worker listens to the source and passes the message to the destination. A single worker can be configured to orchestrate a certain number of jobs. If you set MAX_SYNC_JOBS to 10, then it can do the work of 5 connections at the same time. 5 Sources , and 5 destinations. Once a certain sync is scheduled on a worker, it is handled by it. What happened on your case i think its 1. You didnt set limits to the worker pods. 2. The additional worker pods were started after the sync jobs were already scheduled to the first pod. Given this, i'd recommend starting your jobs once you have the worker pods running and not after. Basically you have to horizontally scale your worker pods based on the number of jobs pending of execution, and not necesarilly memory or cpu.
To the point of Marcelo, try also using just one temporal, since this is the pod responsible for the scheduling.
👍 1
d
@Camilo Atencio Franco These remarks are extremely helpful! thanks! I’ll update 🙂
n
Thanks for all your input, @Camilo Atencio Franco!
🙏 1
n
@Camilo Atencio Franco @Nataly Merezhuk (Airbyte) Hey! I am working with @Dudu Vaanunu to manage Airbyte in our cluster. Thanks for the feedback! After reading your comments and the documentation, I still have a few questions: 1. I cannot find a variable named
MAX_SYNC_JOBS
. However I do see a variable named
MAX_SYNC_WORKERS
in the documentation, which is set to 5 by default. I am not quite sure I understand the effect of this variable in a Kubernetes environment, and its relation to the number of replicas of
airbyte-worker
deployment. Could you please elaborate? 2. Airbyte-worker pods are always running, they are started as soon as we deploy the chart by the
airbyte-worker
deployment, so I’m afraid it is not the case here… 3. We will try tweaking temporal replica count and update our results Thanks for all the help!!
c
Sorry the variable name is MAX_SYNC_WORKERS
m
1. MAX_SYNC_WORKERS will control how much concurrent syncs a given worker can run. So, since the default is 5, each replica can run at most 5 syncs concurrently. 2. The worker is always running, but it spawns a container orchestrator, a source and a destination, it is better documented here: https://docs.airbyte.com/understanding-airbyte/jobs#decoupling-worker-and-job-processes 3. Feel free to report any problems!
The container orchestrator was the origin of my confusion that the workers didn't need to scale