Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[*.yml]
indent_size = 2
31 changes: 31 additions & 0 deletions .github/workflows/spellcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Spellcheck

on:
push:
branches:
- master
pull_request:

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Install dependencies
run: |
python -m pip install --upgrade setuptools
python -m pip install -r Resources/doc/requirements.txt
- name: Run spell check
run: |
make -C Resources/doc/ spelling
if [[ -s "Resources/doc/_build/spelling/output.txt" ]]; then echo "\nSpelling errors found\n" && cat "Resources/doc/_build/spelling/output.txt"; fi
- name: Spellcheck
run: |
if [[ -s "Resources/doc/_build/spelling/output.txt" ]]; then cat "Resources/doc/_build/spelling/output.txt"; fi
if [[ -s "Resources/doc/_build/spelling/output.txt" ]]; then false; fi
13 changes: 13 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2

sphinx:
configuration: Resources/doc/conf.py

# additional formats
formats:
- pdf

python:
version: "3.7"
install:
- requirements: Resources/doc/requirements.txt
2 changes: 1 addition & 1 deletion Resources/doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@

# General information about the project.
project = 'FOSHttpCacheBundle'
copyright = '2014-2018, David de Boer, David Buchmann'
copyright = 'David de Boer, David Buchmann'

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
Expand Down
4 changes: 2 additions & 2 deletions Resources/doc/reference/annotations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ See :doc:`/features/invalidation` for more information.
``@InvalidateRoute``
--------------------

Like InvalidatePath annotations, you can use php attributes instead if you are using PHP 8
Like InvalidatePath annotations, you can use PHP attributes instead if you are using PHP 8
Invalidate a route with parameters::

use FOS\HttpCacheBundle\Configuration\InvalidateRoute;
Expand Down Expand Up @@ -99,7 +99,7 @@ HTTP header (``X-Cache-Tags``, by default).
Any non-safe request to the ``editAction`` that returns a successful response
will trigger invalidation of both the ``news`` and the ``news-123`` tags.

Like InvalidatePath annotations, you can use php attributes instead if you are using PHP 8
Like InvalidatePath annotations, you can use PHP attributes instead if you are using PHP 8

Set/invalidate a tag::

Expand Down
4 changes: 2 additions & 2 deletions Resources/doc/reference/configuration/proxy-client.rst
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ inconsistent caches.

**type**: ``string``

Json encoded servers array as string. The servers array has the same specs as ``http.servers``.
JSON encoded servers array as string. The servers array has the same specs as ``http.servers``.

Use this option only when using a variable amount of proxy servers that shall be defined via
environment variable. Otherwise use the regular ``http.servers`` option.

Usage:
* fos_http_cache.yaml: ``servers_from_jsonenv: '%env(json:VARNISH_SERVERS)%'``
* ``fos_http_cache.yaml``: ``servers_from_jsonenv: '%env(json:VARNISH_SERVERS)%'``
* environment definition: ``VARNISH_SERVERS='["123.123.123.1:6060","123.123.123.2"]'``


Expand Down
10 changes: 5 additions & 5 deletions Resources/doc/reference/configuration/tags.rst
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,11 @@ section of the tag configuration and ``@tag`` :ref:`annotations<tag>`.
By default, the generated response header will not be split into multiple headers.
This means that depending on the amount of tags generated in your application the
value of that header might become pretty long. This again might cause issues with
your webserver which usually come with a pre-defined maximum header value length and
will throw an exception if you exceed this. Using this configuration key you can
your web server, as it usually has a default maximum header length and will reject
the request if the header exceeds this value. Using this configuration key, you can
configure a maximum length **in bytes** which will split your value into multiple
headers. Note that you might update your proxy configuration because it needs
to be able to handle multiple headers instead of just one.
headers. Note that you might have to update your proxy configuration because it
needs to be able to handle multiple headers instead of just one.

.. code-block:: yaml

Expand All @@ -79,7 +79,7 @@ to be able to handle multiple headers instead of just one.

.. note::

4096 bytes is generally a good choice because it seems like most webservers have
4096 bytes is generally a good choice because it seems like most web servers have
a maximum value of 4 KB configured.

``strict``
Expand Down
3 changes: 2 additions & 1 deletion Resources/doc/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
sphinx==1.8.5
git+https://github.com/fabpot/sphinx-php.git
sphinx_rtd_theme
sphinx-rtd-theme
sphinxcontrib-spelling
sphinxcontrib-phpdomain
pyenchant
4 changes: 4 additions & 0 deletions Resources/doc/spelling_word_list.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,18 @@ cacheable
ETag
friendsofsymfony
github
hardcoded
hostname
invalidations
invalidator
javascript
JSON
login
logout
lookup
lookups
matcher
md
mistyped
multi
nginx
Expand All @@ -31,5 +34,6 @@ symfony
subdomains
templating
TTL
vmod
xkey
yaml
2 changes: 1 addition & 1 deletion tests/Functional/DependencyInjection/ServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ protected function bootDebugKernel()
{
static::ensureKernelShutdown();

/** @var \AppKernel $kernel */
static::$kernel = static::createKernel();
assert(static::$kernel instanceof \AppKernel);
static::$kernel->addCompilerPass(new ServicesPublicPass());
$fs = new Filesystem();
$fs->remove(static::$kernel->getCacheDir());
Expand Down