Yes, this works by default.
I am assuming you have two independent services or processes needed to consume the message from the same topic and process it.
You just have to subscribe to the same topic and should do the job.
References:
https://learn.conduktor.io/kafka/complete-kafka-consumer-with-java/
https://developer.confluent.io/get-started/java/#build-consumer