Open
Conversation
spajic
approved these changes
May 16, 2024
| @@ -1 +1 @@ | |||
| 2.6.3 | |||
| 3.2.4 | |||
| <% end %> | ||
| </ul> | ||
| <%= render "delimiter" %> | ||
| ==================================================== |
Collaborator
There was a problem hiding this comment.
Just for your information, есть в рендеринге коллекций возможность задать разделитель параметром: https://guides.rubyonrails.org/layouts_and_rendering.html#spacer-templates
И в целом с использованием render collection производительность не такая ужасная как было тут с рендерингом циклом
| * Вторым шагом было добавлние загрузки связанных объектов Services с помощью `includes` для Trip и Bus. Время загрузки уменьшилось до 548ms | ||
| - Логи показали много обращений к шаблон для рендера | ||
| * Создание общего шаблона для рендера без вложенных шаблонов уменьшило время загрузки страницы `автобусы/Самара/Москва` до 178ms | ||
| - Добавление индексов согласно рекомендациям PG Hero сократило время загрузки до 156ms |
Collaborator
There was a problem hiding this comment.
именно на скорость рендера страницы особо не влияет тут, так как это не главная точка роста, но если бы мы заходили с точки зрения снижения нагрузки на БД, то такой индекс бы супер помог
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR содержит оптимизированную версию Rails приложения, в которой:
rake reload_json[fixtures/large.json]должнен выполняться в пределах минуты;автобусы/Самара/Москвадолжна укалывать в 200 мс;