Sobes.tech

Tell about your experience implementing and working with Agile methodologies in projects.

Junior — Middle
206

What potential difficulties and limitations may arise when using Kafka in systems?

Middle — Middle+
205

Can you list the main characteristics and features of the Spring framework?

Junior — Middle
205

What makes immutable objects safe to use in a multithreaded environment?

Junior — Middle
205

What are the key components and stages involved in the Scrum process?

Junior — Middle
203

Объясните понятие согласованности данных в системах хранения информации.

Junior — Middle
202

Can a geographic query be included in the parameters of an HTTP GET request?

Junior — Middle
202

What are the main message delivery guarantees provided by Kafka according to its theoretical model?

Middle — Middle+
202

What is the complexity level increase when adding every 1000 elements to an ArrayList?

Junior — Middle
202

In what cases and under what conditions can data loss occur in Kafka?

201

Can already closed data streams (Streams) in Java be reused?

Junior — Middle
201

What problems can arise if you modify a collection while iterating over it?

Junior — Middle
201

Implement a transfer of funds between two accounts. Note that this is a production solution Input parameters: @param fromAccountId the unique identifier of the user transferring funds @param toAccountId the unique identifier of the user receiving funds @param amount the transfer amount. A positive number public void transferMoney(Long fromAccountId, Long toAccountId, BigDecimal amount) { if (amount.compareTo(BigDecimal.ZERO) <= 0) { throw new RuntimeException("Amount must be > 0"); } if (fromAccountId.equals(toAccountId)) { throw new RuntimeException("Account can't be the same"); } Long firstId = Math.min(fromAccountId, toAccountId); Long secondId = Math.max(fromAccountId, toAccountId); Account first = accountRepository.findByIdForUpdate(firstId) .orElseThrow(() -> new RuntimeException("Account not found")); Account second = accountRepository.findByIdForUpdate(secondId) .orElseThrow(() -> new RuntimeException("Account not found")); Account from = fromAccountId.equals(firstId) ? first : second; Account to = fromAccountId.equals(firstId) ? second : first; if (from.getBalance().compareTo(amount) < 0) { throw new RuntimeException("Balance is Less 0"); } from.setBalance(from.getBalance().subtract(amount)); to.setBalance(from.getBalance().add(amount)); accountRepository.save(to); accountRepository.save(from); }

200

What motivates you to consider changing your current project?

Junior — Middle
199

Can you explain how the HashMap data structure works and how it provides fast access to elements?

Junior — Middle
198

Can you explain what Gson is and how it works with fields during serialization and deserialization?

Junior — Middle
197
/11