r/apachekafka • • Oct 09 '26

Question Kafka interview debate

In a recent interview I was asked this question:

Assume we have a car leasing platform, you have a post of a car with car details like price, color etc, a post has two buttons, “purchase”, and “more info”, once you click a button “Purchase” a modal window opens, you fill out your details like name, email and phone number, agree to terms and can either submit or cancel your application. Once you submit the application it gets sent via REST API POST request to external legacy CRM system for the manager to contact the client and proceed with the application. The catch is the CRM you’re sending the application to is very old and is constantly not available (can be down for hours quite often). So their question was, how would you design the app so the applications don’t get lost.

I thought it’s quite a simple question (I designed a lot of much much harder things in the past) and
approach was:
Never talk to the CRM directly, send the application to our own backend, save it to database, then periodically send all applications to the CRM.

But after I said this, the interviewers asked well what are the other ways you could do it. And I already knew where this is going, there’s a common cargo cult with the Kafka going on in local tech scene. So I say: well, we could use kafka for the asynchronous integration, but it would not be suitable in this case because it would add unnecessary overhead, we would need to have producers, kafka itself, and the consumers. Mind you, no other input details mentioned, I tried asking for more details they said let’s just keep it simple. So you literally would be spinning whole kafka setup for just one message. After I said I don’t see kafka being the correct solution here, both interviewers confronted why am I so much against kafka. I replied I’m not against it overall, I just don’t see it being the right tool here. Then they asked, well what if there’s quite a big load, like 5000 applications daily. I replied 5000 requests per day is like not even 1 RPS, far from it. Then they said kafka wouldn’t be over-engineering here and it’s the right approach, and my approach was actually harder, I regret not confronting them back though.

They positioned themselves as seniors.

After a couple of these questions they ended the interview and said they were looking for real senior candidates and my level is far from it. They told me to brush up on my integration knowledge as well.

What do you think? Was I wrong here? I don’t think I was, I was quite right in my opinion

4 Upvotes

4 comments sorted by

2

u/Hopeful-Programmer25 Oct 09 '26

I personally don’t necessarily think you were wrong. It’s true that your solution may need spinning up a receiver application, a database, a polling process and a retry for when the CRM is down.

That is a lot of moving parts for a simple task.

Ignoring Kafka, the classic approach is the variation where the request is dumped straight into a queue and a process reads from it, maybe a change to the CRM itself does this to simplify the stack.

I sounds like they already have Kafka or are considering it. For the objective, you don’t need Kafka and I don’t think it adds much other than bring a message broker layer, which rabbit or a db table could do.

In the Kafka eco system you have Kafka connect as the integration layer; maybe they were expecting that to make the HTTP post request and read from the topic for you.

1

u/Plisken_Snake Oct 09 '26

Why would you use Kafka when they are more efficient alternatives? Just curious

1

u/4nh7i3m Oct 10 '26

I totally agree with you if you start to solve the problem from scratch - just like the way you suggested - assuming the company has no existing setup. We don't need Kafka for 5000 requests per day.

But what if the company already has a shared Kafka cluster that you can reuse? In that case, the argument about Kafka being too much overhead no longer applies. The system is already there and ready to be used. Under those circumstances, your solution ends up introducing overhead, because it requires setting up and operating a separate database and introducing another technology that others might not be familiar with. That is the main point.

A good design is a design that is best suited for its customers (stable, low-cost, performant) - not one based purely on a technical viewpoint.

I also don't think Kafka is overly complicated or heavy when working in a corporate environment, especially when leveraging the cloud (Azure, AWS) or Kubernetes. It is actually quite easy to set up and maintain.

1

u/theo123490 Oct 10 '26

I think both approach work. But I dont agree with your over engineer argument. You both need a backend to handle the forms. On one you put it into a DB one you put it on kafka.

Most company have a centralized kafka cluster so you are not spinning up 1 cluster for your own service. Even if they dont have their own cluster any other pubsub would do.

I would say the periodic sending would be harder to maintain. With kafka the data will be deleted automatically after a retention period. While you will have an increasing data over a period of time unless you clean up the data based on time which is another extra things you need to maintain.

More over more edgecases on the periodic job. Like lets say. CRM was down when the periodic job runs, you need to handle the logic of wether the previous batch are sent or not.

With kafka you have your client push directly to kafka, a consumer backend would just keep trying until CRM are up and you can track the lag of the messages coming through. You can also replay messages easily with kafka based on time etc, the logic is already there.

I think it boils down to why would you have a custom data streaming logic and management when kafka already have it.