-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Коротких Виктор / ИТМО DWS / Stage 5 #190
Conversation
vitekkor
commented
Apr 11, 2024
•
edited
Loading
edited
- Асинхронное взаимодействие
- Отчёт link
# Conflicts: # src/main/java/ru/vk/itmo/test/viktorkorotkikh/ConsistentHashingManager.java # src/main/java/ru/vk/itmo/test/viktorkorotkikh/LSMServerImpl.java # src/main/java/ru/vk/itmo/test/viktorkorotkikh/LSMServiceImpl.java # src/main/java/ru/vk/itmo/test/viktorkorotkikh/http/LSMConstantResponse.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 13005 lines exceeds the maximum allowed for the inline comments feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 23589 lines exceeds the maximum allowed for the inline comments feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 23589 lines exceeds the maximum allowed for the inline comments feature.
for (final String replicaUrl : replicas) { | ||
if (replicaUrl.equals(selfUrl)) { | ||
responses.add(processLocal(request, key, id, requestTimestamp)); | ||
clusterResponseMerger.addToMerge(i, processLocal(request, key, id, requestTimestamp)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
здесь мы делаем синхронный вызов к локальной реплике, что по условию не должно быть
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Согласен. Ошибся. Исправил, отчёт дополнил
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 46223 lines exceeds the maximum allowed for the inline comments feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 46233 lines exceeds the maximum allowed for the inline comments feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 46233 lines exceeds the maximum allowed for the inline comments feature.
private final int allowedUnsuccessfulResponses; | ||
private final Request originalRequest; | ||
private final HttpSession session; | ||
private final NodeResponse[] nodeResponses; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
здесь могут быть проблемы в многопоточной среде, чтение/запись в массив идет из разных потоков. В таком случае просто final ссылка не поможет. Нужны какие-то примитивы синхронизации.
Подойдет как какая-нибудь потокобезопасная коллекция, так и AtomicReferenceArray
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Да, действительно. Затмил глаза этот word tearing с гарантиями записи из разных потоков в разным индексам массива. Заменил на AtomicReferenceArray
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 46243 lines exceeds the maximum allowed for the inline comments feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 46247 lines exceeds the maximum allowed for the inline comments feature.
# Conflicts: # src/main/java/ru/vk/itmo/test/viktorkorotkikh/LSMServiceImpl.java # src/main/java/ru/vk/itmo/test/viktorkorotkikh/util/ClusterResponseMerger.java # src/main/java/ru/vk/itmo/test/viktorkorotkikh/util/LsmServerUtil.java
@atimofeyev Добрый день! Так вышло, что Вадим вмерджил мой 6 stage в main раньше, чем 5й, поэтому я замерджил upstream и разрешил конфликты. Также вижу, что аппрув от вас есть, но нет оценки. Подскажите, пожалуйста, нужно ли от меня что-то ещё? |
нет, больше ничего не надо, занесу скоро оценку в ведомость |