Sobes.tech

Why are Spring Boot starters needed if we can write everything in Spring?

146

How should the application determine which test shows that Kafka connections exist, and topics are available? How to implement Kafka Health Check?

146

What is the main problem of this implementation - Connection to Redis is hardcoded - There is a connection pool for Redis - Unverified call to `jedis.get` may return null - Using the `KEYS` command causes server load - No Redis events

146

What is the main cause of incorrect code behavior Objects' immutability is violated Interrupt status is not handled Performance degradation due to locking Lock object conflicts lead to deadlock situations Excessive resource synchronization Uninitialized object states import java.util.concurrent.*; class Competition { private final Object lock = new Object(); public void syncMethodA(Competition competitor) { synchronized (lock) { try { Thread.sleep(100); } catch (InterruptedException e) {} competitor.syncMethodB(this); } } public void syncMethodB(Competition competitor) { synchronized (lock) { try { Thread.sleep(100); } catch (InterruptedException e) {} competitor.syncMethodA(this); } } } public class FitnessApp { public static void main(String[] args) { Competition comp1 = new Competition(); Competition comp2 = new Competition(); Thread t1 = new Thread(() -> comp1.syncMethodA(comp2)); Thread t2 = new Thread(() -> comp2.syncMethodB(comp1)); t1.start(); t2.start(); } }

146

What is the main issue with this Dockerfile example FROM golang:1.16 WORKDIR /app COPY go.mod . COPY go.sum . RUN go mod download COPY . . RUN go build -o crashAnalysis . CMD ["./crashAnalysis"] EXPOSE 9090 - Missing ENV for configuration - Lack of multi-stage builds - Temporary files are never deleted - Suboptimal use of RUN - Port 8081 is not specified in the EXPOSE instruction

144

Ты говорил про идемпотентную отправку или Exactly-Once в Kafka. Чем из них пользовался?

143

What is the main problem of this implementation - No in-memory caching for optimization. - Different data storage types in one hash - Checking the switch before reading data does not yield results - Absence of standard serializers in `RedisTemplate` - Pipelining is not used for partial operations

142

What does the producer return if it sends an ID that was already sent within some time (with a 6-hour idempotency period)?

142

Why are there no statements there? Why does it not compile the statement based on the base?

142

How to check if a topic is alive and has the required number of partitions, and if there is at least a leader in the partition?

142

What overhead does Kafka have for idempotent sending? What does Kafka sacrifice in this case?

142

What is the main cause of incorrect code behavior when using an immutable map? Fields without 'read-only' can be modified HashMap does not preserve element order Excessive use of wrappers causes confusion The 'Immutable' map reflects changes in the original map Incorrect use of the object leads to errors

141

How are you generally with DevOps technologies — Kubernetes, CI/CD, and others?

138

Was the DLT consumer in the same service as the main one? Why listen to it again and log?

138

If we have an external API that allows a maximum of 10 concurrent connections, which class from the java.util.concurrent package would you use to limit the number of parallel calls?

135

When you perform a regular SELECT, how many queries does the driver send to Postgres? What are these queries and what will be there?

134

We need to intercept all requests in Kafka and send them to an audit or telemetry system. How would you do it?

133

What is the main problem with this implementation? - Sending messages without a key - Sending without checking message size - The producer sends a message to a topic to complete its initialization - Sending messages without checking cluster connection - Consumer groups are not configured properly.

132
/5