summaryrefslogtreecommitdiff
path: root/lib/banzai/renderer.rb
Commit message (Collapse)AuthorAgeFilesLines
* Enable more frozen string in lib/**/*.rbgfyoung2018-10-061-0/+2
| | | | | | | | | | | | | Enables frozen for the following: * lib/*.rb * lib/banzai/**/*.rb * lib/bitbucket/**/*.rb * lib/constraints/**/*.rb * lib/container_registry/**/*.rb * lib/declarative_policy/**/*.rb Partially addresses #47424.
* Adds Rubocop rule for line break after guard clauseJacopo2017-11-161-0/+2
| | | | Adds a rubocop rule (with autocorrect) to ensure line break after guard clauses.
* Resolve "DashboardController#activity.json is slow due to SQL"Francisco Javier López2017-11-061-7/+4
|
* Create idea of read-only databasetc-geo-read-only-ideaToon Claes2017-10-061-6/+1
| | | | | | | | | | | | In GitLab EE, a GitLab instance can be read-only (e.g. when it's a Geo secondary node). But in GitLab CE it also might be useful to have the "read-only" idea around. So port it back to GitLab CE. Also having the principle of read-only in GitLab CE would hopefully lead to less errors introduced, doing write operations when there aren't allowed for read-only calls. Closes gitlab-org/gitlab-ce#37534.
* Adds cacheless render to Banzai object render34509-improves-markdown-rendering-performance-for-commits-listTiago Botelho2017-09-061-0/+4
|
* Whitelist or fix additional `Gitlab/PublicSend` cop violationsrs-more-public-send-whitelistsRobert Speicher2017-08-141-2/+2
| | | | | An upcoming update to rubocop-gitlab-security added additional violations.
* Don't bother going through an entire Banzai pipeline for empty textrs-minor-banzai-perfRobert Speicher2017-08-031-0/+2
| | | | | | | | | | This bails out of `cacheless_render` immediately unless the provided text is present, since there's no point. This is a slight improvement in our test performance. Across the creation of 1,000 `Namespace` records, which caches the `description` field and which is blank by default in its factory, this saves about four seconds, which... sure. Why not.
* Start versioning cached markdown fieldsNick Thomas2017-04-211-14/+7
|
* Remove a use of module_functionNick Thomas2017-04-211-12/+10
|
* make mentions working when project not specifiedJarka Kadlecova2017-01-181-2/+2
|
* Split out markdown cache storage into a separate methodNick Thomas2016-11-041-1/+5
|
* Use module_function in Banzai::Rendererfix-banzai-renderer-instrumentationYorick Peterse2016-10-141-3/+1
| | | | | | | Using `extend self` prevents GitLab Performance Monitoring from being able to track class methods. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/23347
* Add markdown cache columns to the database, but don't use them yetNick Thomas2016-10-071-0/+28
| | | | | | | | | | | | This commit adds a number of _html columns and, with the exception of Note, starts updating them whenever the content of their partner fields changes. Note has a collision with the note_html attr_accessor; that will be fixed later A background worker for clearing these cache columns is also introduced - use `rake cache:clear` to set it off. You can clear the database or Redis caches separately by running `rake cache:clear:db` or `rake cache:clear:redis`, respectively.
* Make banzai module that handles markdown singletonGrzegorz Bizon2016-07-191-7/+9
|
* ObjectRenderer doesn't crash when no objects to cache with ↵Paco Guzman2016-07-131-4/+10
| | | | Rails.cache.read_multi
* Object renderer read_multi rendered entries from Cacheread-multi-rendered-objectsPaco Guzman2016-07-121-1/+55
|
* Move pre_process into render_resultremove-banzai-pre-processYorick Peterse2016-06-211-6/+2
| | | | | | | | | | | The method Banzai::Renderer.pre_process would always be called, regardless of whether the Markdown to render was already cached or not. In cache the document _was_ cached the output of the pre-processing pipeline was ignored resulting in it doing nothing but wasting CPU cycles. This commit moves Banzai::Renderer.pre_process into Banzai::Renderer.render_result so that it's _only_ used when needed.
* Instrument Banzai codeYorick Peterse2016-04-111-8/+12
|
* Add a PreProcessPipelineRobert Speicher2016-03-021-0/+6
|
* Revert "Temporarily disable Markdown caching"Douwe Maan2016-01-061-3/+1
| | | | This reverts commit d337d5e7137d9b3fd0f9b8890a3ba9296323acc7.
* Revert "Add DEBUG_BANZAI_CACHE env var to debug Banzai cache issue."Douwe Maan2016-01-061-14/+7
| | | | This reverts commit 4b027bc93a7875c3937f6b90ac1049b4a4d72da5.
* Add DEBUG_BANZAI_CACHE env var to debug Banzai cache issue.debug-banzai-cacheDouwe Maan2016-01-041-7/+14
|
* Temporarily disable Markdown cachingDouwe Maan2015-12-161-1/+3
|
* Move Markdown/reference logic from Gitlab::Markdown to BanzaiDouwe Maan2015-12-151-0/+76