Commit Graph

351 Commits

Author SHA1 Message Date
Ricky Su
66798ba904 [FrameworkBundle] Add HHVM support for built-in web server 2014-03-03 17:49:59 +01:00
florianv
597a3107bc Added a translation:debug command 2014-03-03 17:12:20 +01:00
Fabien Potencier
ca4736b4a1 [Console] fixed missing abstract keyword 2014-02-24 17:03:53 +01:00
Tiago Ribeiro
01858d3ad1 Fixed typo in method name 2014-02-23 16:22:13 +00:00
Grégoire Pineau
19a368e068 [FramworkBundle] Added config:debug command 2014-02-13 15:16:29 +01:00
Grégoire Pineau
689e9bf001 [FrameworkBundle] Pretty Ppint json ouput of yaml:lint command 2014-01-20 10:15:51 +01:00
Jakub Zalas
6258cfaa03 [Routing][FrameworkBundle] Deprecated the apache dumper 2014-01-13 21:29:22 +01:00
Fabien Potencier
f2261da450 [FrameworkBundle] simplified code 2014-01-07 15:07:32 +01:00
ConneXNL
a1f64114ab [FrameworkBundle] added feedback in cache:clear 2014-01-07 15:01:26 +01:00
Grégoire Pineau
9c06b27283 [FrameworkBundle] Added yaml:lint command 2014-01-06 17:41:52 +01:00
Fabien Potencier
e0402bae65 Merge branch '2.3' into 2.4
* 2.3:
  removed unneeded use statements
  Prepend Child Bundle paths before the parent
  [Routing] add unit tests for Symfony\Component\Routing\RequestContext class

Conflicts:
	src/Symfony/Component/Form/Extension/Csrf/CsrfExtension.php
	src/Symfony/Component/HttpKernel/DataCollector/TimeDataCollector.php
	src/Symfony/Component/Validator/ConstraintValidatorFactory.php
2014-01-01 09:14:50 +01:00
Fabien Potencier
7f9a366529 removed unneeded use statements 2014-01-01 08:52:14 +01:00
Fabien Potencier
d87d8daa36 Merge branch '2.3' into 2.4
* 2.3:
  fixed a typo
  fixed CS for lambdas
  [Yaml] fixed some license headers
  Fixes message value for objects
  Check for hour, minute & second validity
  fixed various typos
  [Filesystem] Fixed mirror for symlinks
  [Validator] Removed duplicated test for IBAN in data provider

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/Command/ContainerDebugCommand.php
	src/Symfony/Component/Console/Application.php
	src/Symfony/Component/Debug/Tests/ErrorHandlerTest.php
	src/Symfony/Component/Filesystem/Tests/FilesystemTest.php
	src/Symfony/Component/HttpKernel/Tests/DependencyInjection/ContainerAwareHttpKernelTest.php
2013-12-28 09:12:03 +01:00
Fabien Potencier
35b407f016 fixed CS for lambdas 2013-12-28 08:46:05 +01:00
Fabien Potencier
2f15ac7507 fixed various typos 2013-12-27 16:08:19 +01:00
Fabien Potencier
3062681110 fixed CS 2013-12-12 17:08:59 +01:00
Fabien Potencier
1a33e1b18b Merge branch '2.3' into 2.4
* 2.3:
  [Debug] fixed unit tests
  Avoid notice from being *eaten* by fatal error.
  Teardown used wrong property
  Modified guessDefaultEscapingStrategy to not escape txt templates
  Fix DateType for 32bits computers.
  Fixed the registration of validation.xml file when the form is disabled
  Fixes #9633, Removed dependency to Symfony\Bundle\FrameworkBundle\Tests\TestCase
  [Validator] Replaced inexistent interface.
  When getting the session's id, check if the session is not closed
  Adjusting CacheClear Warmup method to namespaced kernels

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/Command/CacheClearCommand.php
2013-11-28 11:27:26 +01:00
Rafael Dohms
00d79d559d Adjusting CacheClear Warmup method to namespaced kernels
Backported the patch in #9525 to the 2.3 branch.
2013-11-25 11:32:15 +01:00
Rafael Dohms
9e7788ea80 Cache Warmup Breaks Namespaced Kernel
My kernel has been moved and namespaced to `Cfs\Bundle\MultiSiteBundle\Kernel\CfsKernel`. This worked fine until a change was made to how the kernel temp stuff is handled in the warmup phase.

When the app generates its own cache (i.e you run cache without warmup and access the site) everything is generated ok and the .meta files generate the proper reference to the FQN of the Kernel.

However if the warmup is used, it uses `Cfs\Bundle\MultiSiteBundle\Kernel\CfsKerne_` as the temporary Kernel, and when it does "fix references to the Kernel in .meta files" it generates 2 errors.

1. It does not use a string safe tempKernel name, so it never finds the reference to the kernel
2. If you fix that, then it replaces the FQN of the tempKernel with `CfsKernel`, the non-namespaced name of the proper Kernel (it also leaves the character count wrong in the serialization `C:43:<class>` where 43 is the char count for the FQN above)

The two changes above fix this, by escaping the string and replacing it with a FQN Kernel Class name.

What are your thoughts on this?
2013-11-18 11:39:25 +01:00
Wouter J
2b0b355544 Fixed XML dump 2013-10-18 11:29:21 +02:00
Fabien Potencier
7b2fd0bdce Merge branch '2.3'
* 2.3:
  bumped Symfony version to 2.3.7
  updated VERSION for 2.3.6
  updated CHANGELOG for 2.3.6
  bumped Symfony version to 2.2.10
  updated VERSION for 2.2.9
  update CONTRIBUTORS for 2.2.9
  updated CHANGELOG for 2.2.9
  [Security] limited the password length passed to encoders
  [HttpKernel] Fixed a test (compiler pass class name has been changed).
  assets:install command should mirror .dotfiles (.htaccess)
  PoFileDumper - PO headers
  removed whitespaces

Conflicts:
	src/Symfony/Component/HttpKernel/Kernel.php
	src/Symfony/Component/Security/Core/Encoder/BCryptPasswordEncoder.php
	src/Symfony/Component/Security/Core/Encoder/BasePasswordEncoder.php
	src/Symfony/Component/Security/Core/Encoder/MessageDigestPasswordEncoder.php
	src/Symfony/Component/Security/Core/Encoder/Pbkdf2PasswordEncoder.php
	src/Symfony/Component/Security/Core/Encoder/PlaintextPasswordEncoder.php
	src/Symfony/Component/Security/Core/Tests/Encoder/MessageDigestPasswordEncoderTest.php
	src/Symfony/Component/Security/Core/Tests/Encoder/Pbkdf2PasswordEncoderTest.php
	src/Symfony/Component/Security/Core/Tests/Encoder/PlaintextPasswordEncoderTest.php
2013-10-10 16:19:44 +02:00
Fabien Potencier
e7df974ab8 Merge branch '2.2' into 2.3
* 2.2:
  bumped Symfony version to 2.2.10
  updated VERSION for 2.2.9
  update CONTRIBUTORS for 2.2.9
  updated CHANGELOG for 2.2.9
  [Security] limited the password length passed to encoders
  assets:install command should mirror .dotfiles (.htaccess)
  PoFileDumper - PO headers
  removed whitespaces

Conflicts:
	src/Symfony/Component/HttpKernel/Kernel.php
	src/Symfony/Component/Security/Core/Encoder/BCryptPasswordEncoder.php
2013-10-10 15:12:30 +02:00
Andrew Moore
6f48f8e231 assets:install command should mirror .dotfiles (.htaccess) 2013-10-09 23:05:14 +02:00
Fabien Potencier
ad7ac02ee4 Merge branch '2.3'
* 2.3:
  [Process] Fix #9182 : random failure on pipes tests
  Fixed propel guessed relations
  [FramworkBundle][HttpKernel] Check event listener services are not abstract
  fixed CS
  Check for lock existence before unlinking
  remove MinCount and MaxCount contraints. It has been replaced by Count constraints.
  [FrameworkBundle] fixed path replacement on Windows

Conflicts:
	src/Symfony/Bridge/Propel1/Tests/Form/PropelTypeGuesserTest.php
2013-10-09 22:52:22 +02:00
Fabien Potencier
77a961d040 Merge branch '2.2' into 2.3
* 2.2:
  [Process] Fix #9182 : random failure on pipes tests
  Fixed propel guessed relations
  [FramworkBundle][HttpKernel] Check event listener services are not abstract
  fixed CS
  Check for lock existence before unlinking
  [FrameworkBundle] fixed path replacement on Windows

Conflicts:
	src/Symfony/Component/Process/Process.php
2013-10-09 22:51:36 +02:00
Fabien Potencier
1d210f86a6 [FrameworkBundle] changed the router:debug to use the shortcut notation for the controller 2013-10-02 16:42:09 +02:00
Fabien Potencier
d997dfa556 [FrameworkBundle] fixed container:debug and router:debug commands 2013-10-02 16:42:09 +02:00
Fabien Potencier
04d767db56 fixed CS 2013-10-01 19:34:40 +02:00
Fabien Potencier
e47677edd5 minor #8487 [FrameworkBundle] The config:dump-reference command shows the list of bundles with the table helper (saro0h)
This PR was merged into the master branch.

Discussion
----------

[FrameworkBundle] The config:dump-reference command shows the list of bundles with the table helper

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no

Commits
-------

31c6c62 [FrameworkBundle] The config:dump-reference command shows the list of bundles with the table helper
2013-10-01 19:32:30 +02:00
Jean-François Simon
22f9bc887e [FrameworkBundle] adds routing/container descriptors 2013-10-01 16:13:13 +02:00
Fabien Potencier
526d2858f2 [FrameworkBundle] fixed path replacement on Windows
In the cache, blackslashes in paths can be both represented by a single
or a double backslash.
2013-10-01 11:24:08 +02:00
Fabien Potencier
4705e6f7cc fixed previous merge (refs #8635) 2013-09-18 14:22:34 +02:00
Fabien Potencier
7005cf5e71 merged branch WouterJ/dump_xml (PR #8635)
This PR was squashed before being merged into the master branch (closes #8635).

Discussion
----------

[Config] Create XML Reference Dumper

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | no
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Only Yaml was supported. This PR adds support for XML. This makes it easier to test XML schema's (see symfony-cmf/MenuBundle#114 ), helps us at the docs with our configuration reference and helps others using XML with symfony.

## Todo

 - [x] Prototyped arrays don't work properly
 - [x] Add comments (see Yaml dumper)
 - [x] Add namespaces support

## Side effects

I've moved the reference dumpers to their own namespace and renamed the original reference dumper to `YamlReferenceDumper`. The old one is kept for BC, but deprecated.

/cc @dantleech

Commits
-------

05e9ca7 [Config] Create XML Reference Dumper
2013-09-18 13:36:39 +02:00
WouterJ
05e9ca7509 [Config] Create XML Reference Dumper 2013-09-18 13:36:38 +02:00
Fabien Potencier
b0b109b422 merged branch peterrehm/router-command (PR #8657)
This PR was squashed before being merged into the master branch (closes #8657).

Discussion
----------

Added option to show controllers optionally in the router:debug command

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Added option to show controllers in the router debug command as a convenience function.

    app/console router:debug --show-controllers

Commits
-------

6fd32f3 Added option to show controllers optionally in the router:debug command
2013-09-09 14:59:52 +02:00
Peter Rehm
6fd32f3da4 Added option to show controllers optionally in the router:debug command 2013-09-09 14:59:51 +02:00
Fabien Potencier
91e5b10d05 Merge branch '2.2' into 2.3
* 2.2:
  Added sleep() workaround for windows php rename bug
  [HttpKernel] removed unused variable

Conflicts:
	src/Symfony/Component/HttpKernel/Kernel.php
2013-08-15 19:08:02 +02:00
Christian Morgan
dbd08551f8 Added sleep() workaround for windows php rename bug 2013-08-15 15:44:11 +02:00
Sarah Khalil
31c6c627f2 [FrameworkBundle] The config:dump-reference command shows the list of bundles with the table helper 2013-07-13 23:39:16 +02:00
Fabien Potencier
4c0bfd3313 fixed CS 2013-07-01 14:24:43 +02:00
Tobias Schultze
024bd9e814 [FrameworkBundle] removed deprecated method from cache:clear command 2013-05-24 16:28:17 +02:00
Vitaliy Zakharov
70c0424f69 fix double variable assignment in ContainerDebugCommand 2013-05-19 21:12:17 +02:00
Alex Pods
9cca065d85 [FrameworkBundle] Place initialization of $bundlesDir out of foreach loop
Code enhancement. $bundlesDir variable doesnt't need any bundle information for initialization. So it must be placed out of the loop to not process unnecessary operations.
2013-05-01 10:39:32 +04:00
Jordi Boggiano
54c1377a33 [Console] Handle new verbosity levels 2013-04-25 12:42:34 +02:00
Pascal Borreli
6ef7f10628 Fixed typos 2013-04-21 11:14:35 +00:00
Fabien Potencier
719c278f32 merged branch egeloen/f-container-params-debug (PR #6550)
This PR was merged into the master branch.

Discussion
----------

[FrameworkBundle] Allow to debug container parameters

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Fixes the following tickets: ~
Todo: -
License of the code: MIT
Documentation PR: ~

Hey!

This PR adds a new command which allows to debug container parameters. IMO, being able to list all available parameters is very useful. We can now know which parameters we can inject into our services.

Regards

Commits
-------

ceb401d Add parameters debug to the container:debug command
64388c1 [FrameworkBundle] Allow to debug container parameters
2013-04-20 15:10:52 +02:00
Fabien Potencier
3cb87a3f95 merged branch dantleech/enforce_sprintf_for_exceptions (PR #7620)
This PR was squashed before being merged into the master branch (closes #7620).

Discussion
----------

Enforce sprintf for exceptions

| Q             | A
| ------------- | ---
| Bug fix?      |no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | [yes|no]
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/2483

Changed format of exceptions which concatenate strings as follows

````
throw new \Exception('The '.$something.' needs the '.$foobar.' parameter');
````

to

````
throw new \Exception(sprintf('The %s needs the %s parameter', $something, $foobar));
````

This follows discussion on mailing list: https://groups.google.com/forum/?fromgroups#!topic/symfony-devs/tecj3UOAueM

Unit test results are pending...

Commits
-------

e655120 Enforce sprintf for exceptions
2013-04-11 08:50:46 +02:00
dantleech
e655120f05 Enforce sprintf for exceptions 2013-04-11 08:50:46 +02:00
Fabien Potencier
17e065facb merged branch canni/prod_server (PR #7507)
This PR was squashed before being merged into the master branch (closes #7507).

Discussion
----------

[FrameworkBundle] Enable possibility to run PHP bultin server in production env

See the referenced ticket for discussion;

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #7430
| License       | MIT

Commits
-------

12fce13 [FrameworkBundle] Enable possibility to run PHP bultin server in production env
2013-04-09 16:38:45 +02:00
Dariusz Górecki
12fce13dbb [FrameworkBundle] Enable possibility to run PHP bultin server in production env 2013-04-09 16:38:45 +02:00
Lukas Kahwe Smith
d36f4aed80 dump the list of available bundles (and extension alaises) if no name is provided 2013-04-07 18:28:21 +02:00
Dariusz Górecki
7c47e34928 [CS Fix] Consistent coding-style of concatenation operator usage 2013-04-02 10:39:57 +01:00
Eric GELOEN
ceb401d1d6 Add parameters debug to the container:debug command 2013-03-30 16:35:41 +01:00
Eric GELOEN
64388c14e6 [FrameworkBundle] Allow to debug container parameters 2013-03-28 14:55:36 +01:00
inmarelibero
c46e3e1748 added route debug information when path matches url
included required class
2013-03-23 14:49:10 +01:00
Fabien Potencier
d699a929e0 Merge branch '2.2'
* 2.2: (70 commits)
  change wrapped exception message to be more usefull
  updated VERSION for 2.0.23
  update CONTRIBUTORS for 2.0.23
  updated CHANGELOG for 2.0.23
  [Form] fixed failing test
  [DomCrawler] added support for query string with slash
  Fixed invalid file path for hiddeninput.exe on Windows.
  fix xsd definition for strict-requirements
  [WebProfilerBundle] Fixed the toolbar styles to apply them in IE8
  [ClassLoader] fixed heredocs handling
  fixed handling of heredocs
  Add a public modifier to an interface method
  removing xdebug extension
  [HttpRequest] fixes Request::getLanguages() bug
  [HttpCache] added a test (cached content should be kept after purging)
  [DoctrineBridge] Fixed non-utf-8 recognition
  [Security] fixed HttpUtils class tests
  replaced new occurences of 'Request::create()' with '::create()'
  changed sub-requests creation to '::create()'
  fixed merge issue
  ...

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/Command/TranslationUpdateCommand.php
	src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar.html.twig
	src/Symfony/Component/DomCrawler/Link.php
	src/Symfony/Component/Translation/Translator.php
2013-03-20 15:03:03 +01:00
Jean-François Simon
57aa3d51a7 [FrameworkBundle] adds --clean option translation:update command
[FrameworkBundle] moved operation classes to component

[FrameworkBundle] fixed catalogue operation classes

[Translation] renamed catalogue operation classes

[Translation] renamed operation classes
2013-03-18 14:53:00 +01:00
Fabien Potencier
0d7593c636 Merge branch '2.1' into 2.2
* 2.1:
  sub-requests are now created with the same class as their parent
  [FrameworkBundle] removed BC break
  [FrameworkBundle] changed temp kernel name in cache:clear
  [DoctrineBridge] Avoids blob values to be logged by doctrine
  [Security] use current request attributes to generate redirect url?
  [Validator] fix showing wrong max file size for upload errors
  [TwigBridge] removed double var initialization (refs #7344)
  [2.1][TwigBridge] Fixes Issue #7342 in TwigBridge
  [FrameworkBundle] fixed cahe:clear command's warmup
  [TwigBridge] now enter/leave scope on Twig_Node_Module
  [TwigBridge] fixed fixed scope & trans_default_domain node visitor
  [TwigBridge] fixed non probant tests & added new one
  [BrowserKit] added ability to ignored malformed set-cookie header
  [Translation] removed wriong 'use'
  [Translation] added xliff loader/dumper with resname support
  [TwigBridge] fixes

Conflicts:
	src/Symfony/Bundle/FrameworkBundle/HttpKernel.php
	src/Symfony/Component/Security/Http/HttpUtils.php
	src/Symfony/Component/Translation/Loader/XliffFileLoader.php
	src/Symfony/Component/Translation/Tests/Loader/XliffFileLoaderTest.php
2013-03-15 11:14:31 +01:00
Jean-François Simon
f2ef6bc66b [FrameworkBundle] removed BC break 2013-03-14 12:23:30 +01:00
Jean-François Simon
cc3a40ed78 [FrameworkBundle] changed temp kernel name in cache:clear 2013-03-14 11:46:34 +01:00
Jean-François Simon
7d87ecd346 [FrameworkBundle] fixed cahe:clear command's warmup 2013-03-13 12:02:56 +01:00
Fabien Potencier
7c66dffa6b Merge branch '2.1' into 2.2
* 2.1:
  [FrameworkBundle] Fix code status in dockblock
  Fixed test to use Reflection
  [Finder] fixed a potential issue on Solaris where INF value is wrong (refs #7269)
  Update RouteCompiler.php
  [FrameworkBundle] avoids cache:clear to break if new/old folders already exist
  [HttpKernel] Fixed possible profiler token collision (closes #7272, closes #7171)
  [ClassLoader] tweaked test
  [ClassLoader] made DebugClassLoader idempotent
  [DomCrawler] Fix relative path handling in links

Conflicts:
	src/Symfony/Component/DomCrawler/Link.php
	src/Symfony/Component/Finder/Iterator/DepthRangeFilterIterator.php
	src/Symfony/Component/Routing/RouteCompiler.php
2013-03-11 18:18:44 +01:00
Tobias Schultze
15bf0337ed [FrameworkBundle] fix router debug command
- use dedicated Route:getMethods, getSchemes
- pattern -> path
- show missing scheme requirement
- show missing host regex
- refactoring
2013-03-08 13:29:09 +01:00
Tobias Schultze
d16d193d1e [FramworkBundle] removed unused property of trans update command 2013-03-07 14:40:19 +01:00
Tobias Schultze
5361f83be8 [FramworkBundle] fix phpdoc of commands 2013-03-07 14:36:36 +01:00
Fabien Potencier
82f6389ac3 merged branch jfsimon/issue-6502 (PR #7260)
This PR was squashed before being merged into the 2.1 branch (closes #7260).

Commits
-------

1d3da29 [FrameworkBundle] avoids cache:clear to break if new/old folders already exist

Discussion
----------

[FrameworkBundle] avoids cache:clear to break if new/old folders already exist

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #6502

---------------------------------------------------------------------------

by mahmouds at 2013-03-04T19:07:20Z

👍
2013-03-06 20:12:21 +01:00
Jean-François Simon
1d3da29779 [FrameworkBundle] avoids cache:clear to break if new/old folders already exist 2013-03-06 20:12:21 +01:00
Fabien Potencier
2850fca233 Merge branch '2.1' into 2.2
* 2.1:
  [FrameworkBundle] Fixes invalid serialized objects in cache
  remove dead code in yaml component
  fixed typo
  RedisProfilerStorage wrong db-number/index-number selected
  [DependencyInjection] added a test for the previous merge (refs #7261)
  Unset loading[$id] in ContainerBuilder on exception
  [Console] fixed StringInput binding
  [Console] added string input test
  Revert "merged branch jfsimon/issue-6749 (PR #7220)"
  fixed CS

Conflicts:
	src/Symfony/Component/Console/Tests/Input/StringInputTest.php
	src/Symfony/Component/HttpKernel/Profiler/RedisProfilerStorage.php
2013-03-06 18:38:49 +01:00
Jean-François Simon
d1f5d25483 [FrameworkBundle] Fixes invalid serialized objects in cache 2013-03-06 18:29:15 +01:00
Gábor Egyed
18b139d41c [FrameworkBundle] tweaked reference dumper command (see #7093) 2013-02-17 13:49:11 +01:00
Fabien Potencier
2d2b9bc1d0 [FrameworkBundle] removed extra whitespaces 2013-02-04 13:45:57 +01:00
inmarelibero
95f0202fac [FrameworkBundle] fixed wrong indentation on route debug output 2013-02-02 15:13:57 +01:00
Emanuele Gaspari
507ceac726 fixed wrong indentation 2013-02-01 23:03:50 +01:00
Fabien Potencier
94f6116f42 renamed hostname to host in the routing system (closes #6775)
As explained in #6775, this has been done for the following reasons:

1. It's also Request::getHost()
2. The term hostname has been obsoleted in
http://tools.ietf.org/html/rfc3986#appendix-D.2 and uses the host only
3. hostname in the RFC was defined as the registered domain name, but we
probably also want to match IP-Adresses with the pattern which is the
host = IP-literal / IPv4address / reg-name for.
2013-01-21 17:57:32 +01:00
Fabien Potencier
463b464c10 replaced usage of Route::getPattern() by Route::getPath() 2013-01-16 23:04:10 +01:00
Fabien Potencier
89f9b24575 merged branch fabpot/routing-options (PR #6738)
This PR was merged into the master branch.

Commits
-------

9fc7def added the UPGRADE file for Symfony 3.0
e84cad2 [Routing] updated CHANGELOG
65eca8a [Routing] added new schemes and methods options to the annotation loader
5082994 [Routing] renamed pattern to path
b357caf [Routing] renamed hostname pattern to just hostname
e803f46 made schemes and methods available in XmlFileLoader
d374e70 made schemes and methods available in YamlFileLoader
2834e7e added scheme and method setter in RouteCollection
10183de make scheme and method requirements first-class citizen in Route

Discussion
----------

Routing options

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #5989, #5990, #6049
| License       | MIT

In #5989, it has unanimously been decided to renamed `hostname_pattern` to `hostname` and `pattern` to `path`. That makes a lot of sense and I would like to do the renaming now as `hostname_pattern` is new in Symfony 2.2, so I'd like to avoid breaking BC just after the release. As we are modifying the route options, I've also included changes introduced by @Tobion in #6049 which were discussed in #5990.

As everything is BC, I think it's wise to include that in 2.2. What do you think?

---------------------------------------------------------------------------

by Tobion at 2013-01-14T18:25:53Z

I agree it should be done in 2.2. Thanks for working on it.

---------------------------------------------------------------------------

by vicb at 2013-01-14T23:11:12Z

@fabpot "Everything is BC" until it breaks BC in 3.0, that's why I'd like to see [deprecations in PR summary](https://github.com/symfony/symfony-docs/pull/2116) what do you think ?

---------------------------------------------------------------------------

by vicb at 2013-01-14T23:16:40Z

it would also be great to update the CHANGELOG with deprecations (it could also help people answering your question)

---------------------------------------------------------------------------

by fabpot at 2013-01-15T07:07:03Z

@vicb: I've just updated the CHANGELOG and created the UPGRADE file for 3.0.

---------------------------------------------------------------------------

by vicb at 2013-01-15T07:15:32Z

@fabpot thanks.
2013-01-15 17:25:04 +01:00
Fabien Potencier
b357cafd00 [Routing] renamed hostname pattern to just hostname 2013-01-14 17:14:02 +01:00
Florin Patan
c2acc6c2cb Fixed most of the docblocks/unused namespaces 2012-12-19 08:09:49 +01:00
Fabien Potencier
fdb11be242 fixed CS 2012-12-11 11:49:22 +01:00
Mario A. Alvarez Garcia
cf630690be Fixed copy/paste mistake 2012-12-06 08:14:56 -05:00
Mario A. Alvarez Garcia
d902e9d839 [FrameworkBundle] Added hostnamePattern to the router:debug command 2012-12-06 06:57:32 -05:00
Tobias Schultze
26e56842dc some type fixes 2012-11-12 11:54:32 +01:00
Arnaud Le Blanc
6cd34570d7 fixed CS 2012-11-12 11:35:46 +01:00
Arnaud Le Blanc
462999d2d2 [Routing] display hostname pattern in router:debug output 2012-11-12 11:14:24 +01:00
Fabien Potencier
275cf8cf00 removed unused use statements 2012-11-04 09:30:21 +01:00
Bilal Amarni
3553276af2 [ConfigDumpReference] avoid notice for variable nodes 2012-10-19 15:53:01 +03:00
Fabien Potencier
88ea842c5e Merge branch '2.1'
* 2.1: (28 commits)
  Delete use of CreationExeption
  [Form] Fixed error message in PropertyPath to not advice to use a non-existing feature
  [Form] Fixed creation of multiple money fields with different currencies
  [Form] Fixed setting the "data" option to an object in "choice" and "entity" type
  Fixed Serbian plural translations.
  Fixed IPv6 Check in RequestMatcher
  Fix typo
  change what I think is a typo
  [Console] Fix error when mode is not in PATH
  [WebProfilerBundle] fixed macro usage (to be forward compatible with Twig 2.x)
  Change monolog require-dev to use the branch alias instead of dev-master
  [FrameworkBundle] partially reverted previous merge
  [2.1] Added missing error return codes in commands
  Made the router lazy when setting the context
  [WebProfilerBundle] fixed typos
  Fix incorrect variable in FileProfilerStorage
  UnitTest fix
  UnitTest fix
  added a unit test
  fixed #5384
  ...
2012-10-18 23:16:19 +02:00
Bart van den Burg
34b60f7558 [FrameworkBundle] more verbose output about service tags in container:debug command and display all tag attributes as columns in normal container:debug output 2012-10-16 11:01:37 +02:00
Richard Miller
2a9805eec1 [FrameworkBundle] Adding a option to debug services by tag 2012-10-16 10:40:21 +02:00
Fabien Potencier
dc519847fe [FrameworkBundle] partially reverted previous merge 2012-10-14 11:21:53 +02:00
Martin Hasoň
6b66bc3226 [2.1] Added missing error return codes in commands 2012-10-14 11:21:26 +02:00
Johannes M. Schmitt
6bafe5a635 moved some code to the component 2012-09-20 14:56:47 +02:00
Shin
472dfdc46a oops, the command with name, too 2012-08-24 23:41:40 +09:00
Shin
b1a9587ea7 fixed bug related to the change PR #5326 2012-08-24 23:33:39 +09:00
lsmith77
cdfbe72be4 handle inheritance in config:dump-reference when a bundle name is passed to the command 2012-07-31 15:20:04 +02:00
Yaroslav Kiliba
f402a1643c [FrameworkBundle] AssetsInstallCommand. Made 'web' as a default folder. 2012-07-27 18:49:52 +03:00
Fabien Potencier
73d3efb7a9 [FrameworkBundle] added a note about the classes cache 2012-07-05 08:00:39 +02:00
Fabien Potencier
1a37b78078 reverted #4542 2012-07-05 07:56:16 +02:00
Fabien Potencier
7ac10fefa0 merged branch jalliot/load-class-cache (PR #4542)
Commits
-------

f09789b [FrameworkBundle] Generate the class cache when warming up the cache

Discussion
----------

[FrameworkBundle] Generate the class cache when warming up the cache

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: [![Build Status](https://secure.travis-ci.org/jalliot/symfony.png?branch=load-class-cache)](http://travis-ci.org/jalliot/symfony)
Fixes the following tickets: -
Todo: -

With this PR, the commands `cache:clear` (if `--no-warmup` hasn't been specified) and `cache:warmup` generate the class cache. Now the first page load after clearing the cache does not take over one second anymore :)
Of course, if someone does not want to use the class cache for whatever reason, he can always remove the `$kernel->loadClassCache()` in his front controller and the cache will just be ignored...

On a side note, can someone explain why [SensioDistributionBundle does not warmup the cache in the Composer post-install script](https://github.com/sensio/SensioDistributionBundle/blob/master/Composer/ScriptHandler.php#L48)?

---------------------------------------------------------------------------

by travisbot at 2012-06-10T05:18:30Z

This pull request [passes](http://travis-ci.org/symfony/symfony/builds/1579114) (merged baecbaee into 6266b72d).

---------------------------------------------------------------------------

by travisbot at 2012-06-10T05:24:48Z

This pull request [passes](http://travis-ci.org/symfony/symfony/builds/1579154) (merged f09789b1 into 6266b72d).

---------------------------------------------------------------------------

by jalliot at 2012-06-28T23:18:54Z

@fabpot ping
2012-07-01 23:19:22 +02:00
Xavier Lacot
e44e21c2e9 Reverted to Symfony 2.0's signature, which made it simple to display only a subset of the routes of the application.
This is particularly useful for FOSJsRoutingBundle's fos:js-routing:debug command, which allows to filter the list of javascript-exposed routes.
2012-06-28 18:29:35 +02:00
everzet
d4a09881f1 [FrameworkBundle] added configuration interface check
Added check for ConfigurationInterface to config ref dumping
command. To ensure that configuration implements needed
`getConfigTreeBuilder()` command
2012-06-26 10:46:00 +02:00
Eduardo Gulias
4bfb6fddf7 [FrameworkBundle][Command] ContainerDebugCommand - Changed visibility to allow re use in childs 2012-06-26 09:01:12 +02:00
Jordan Alliot
f09789b192 [FrameworkBundle] Generate the class cache when warming up the cache 2012-06-09 22:38:58 +02:00
Fabien Potencier
58b924533a removed unused use statements 2012-05-19 09:24:13 +02:00
Fabien Potencier
d48d88a05a merged 2.0 2012-05-19 09:24:03 +02:00
Fabien Potencier
cf11cc067f removed unused use statements 2012-05-19 09:22:59 +02:00
Fabien Potencier
3bdf52a16a fixed CS 2012-05-18 19:42:42 +02:00
Sebastiaan Stok
498b81409f [FrameworkBundle] minor fix in TranslationUpdateCommand <info> was not properly closed. 2012-05-13 16:37:31 +03:00
Stéphane PY
bc63fb26be Fix some cs 2012-05-04 00:17:06 +02:00
lsmith77
98a00526ad improved readability 2012-04-17 10:08:22 +02:00
lsmith77
b06537e351 refactored code to use get() when outputting a single route
this is useful for a CMS, where in most cases there will be too many routes to make it feasible to load all of them. here a router implementation will be used that will return an empty collection for ->all(). with this refactoring the given routes will not be listed via router:debug, but would still be shown when using router:debug [name]
2012-04-17 10:08:13 +02:00
Hugo Hamon
809933f55b [FrameworkBundle] fixed translation:update command description. 2012-04-11 08:57:57 +02:00
Fabien Potencier
e1362c6697 [FrameworkBundle] made log output optional depending on the verbose flag 2012-03-23 14:17:57 +01:00
Fabien Potencier
30cd43c68a fixed CS 2012-03-23 14:14:07 +01:00
Fabien Potencier
9d77078d3d merged branch michal-pipa/server (PR #3465)
Commits
-------

df11e62 [FrameworkBundle] Used $output->write() instead of echo
c3bf479 [FrameworkBundle] Used Process component
cfa2dff [FrameworkBundle] Changed server:run command description
e7d38c1 [FrameworkBundle] Changed PHP version detection (see: #3529)
4a3f6d5 [FrameworkBundle] Removed global variable from router script
519d431 [FrameworkBundle] Fixed built-in server router script
d9a0a17 [FrameworkBundle] Added server:run command

Discussion
----------

[FrameworkBundle] Added server:run command (PHP 5.4 built-in web server)

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: [![Build Status](https://secure.travis-ci.org/michal-pipa/symfony.png?branch=server)](http://travis-ci.org/michal-pipa/symfony)
Fixes the following tickets: -
Todo: -

PHP 5.4 comes with [built-in web server](http://www.php.net/manual/en/features.commandline.webserver.php). I've created command which allows to easily run Symfony2 application using this new feature.

    Usage:
     server:run [-d|--docroot="..."] [-r|--router="..."] [address]

    Arguments:
     address        Address:port (default: 'localhost:8000')

    Options:
     --docroot (-d) Document root (default: 'web/')
     --router (-r)  Path to custom router script

    Help:
     The server:run runs Symfony2 application using PHP built-in web server:

       app/console server:run

     To change default bind address and port use the address argument:

       app/console server:run 127.0.0.1:8080

     To change default docroot directory use the --docroot option:

       app/console server:run --docroot=htdocs/

     If you have custom docroot directory layout, you can specify your own
     router script using --router option:

       app/console server:run --router=app/config/router.php

     See also: http://www.php.net/manual/en/features.commandline.webserver.php

It requires PHP 5.4, otherwise this command will be disabled.

I think that this is very convenient (especially for new users). All you have to do is download Symfony, install vendors and run this command. You don't have to configure "real" web server, in fact any other server is not required. You don't have cache and logs permission problem, because server runs with your local user permissions.

---------------------------------------------------------------------------

by blogsh at 2012-03-06T17:38:10Z

Great feature! I was about to write something like this when I saw that you have already started implementing this :)

Some issues:
1. Missing newlines at the end of the files
2. If I try this server command with the default Symfony Standard Edition Acme demo the links on the main page do not work. The demo link links to "//demo" and the configurator link to "//_configurator". If I go to `localhost:8000/demo` directly the page is rendered as usual and all sub links are generated correctly. I could solve the problem by adding one line:

    $_SERVER['SCRIPT_FILENAME'] = 'ANYTHING';
    require 'app_dev.php';

I'm not sure where this problem comes from. Do you experience the same behaviour? Otherwise I'll do some more investigations to find the source of the problem.

3 . I think it would be a nice feature if you would generate a router.php based on the setting of the --env flag if no custom router file has been specified. This way it would be easy to switch between dev and prod.

---------------------------------------------------------------------------

by michal-pipa at 2012-03-06T19:00:24Z

@blogsh

> Missing newlines at the end of the files

I've checked and I can see newlines at the end of files. Are you sure about this?

> If I try this server command with the default Symfony Standard Edition Acme demo the links on the main page do not work. The demo link links to "//demo" and the configurator link to "//_configurator". If I go to localhost:8000/demo directly the page is rendered as usual and all sub links are generated correctly. I could solve the problem by adding one line:
>
>     $_SERVER['SCRIPT_FILENAME'] = 'ANYTHING';
>     require 'app_dev.php';
>
> I'm not sure where this problem comes from. Do you experience the same behaviour? Otherwise I'll do some more investigations to find the source of the problem.

I can reproduce this by changing front controller name from  `app.php` to `app_dev.php`. I'll investigate on this.

> I think it would be a nice feature if you would generate a router.php based on the setting of the --env flag if no custom router file has been specified. This way it would be easy to switch between dev and prod.

You can easily change environment specifying front controller in URL. It works exactly the same way as default Apache configuration. This is intended behavior, as it would be misleading if every server had different rewrite rules.

If you really want to change it, then you can write your own router and pass it as a value to `router` option.

---------------------------------------------------------------------------

by blogsh at 2012-03-06T19:13:55Z

Wasn't aware that github omits the trailing white line, sorry.
Normally I use a rather inflexible nginx configuration, so I also wasn't aware of this (rather obvious) trick of changing the url. Thanks for that.

---------------------------------------------------------------------------

by stof at 2012-03-06T22:12:16Z

@blogsh it does not omit it. It displays it in the Linux way where the newline char is part of the line (and so there is a message ``no newline at end of file`` in the diff when it is missing).

---------------------------------------------------------------------------

by michal-pipa at 2012-03-07T07:18:23Z

@blogsh I've fixed router script. Now you can use both front controllers.

---------------------------------------------------------------------------

by michal-pipa at 2012-03-07T07:34:58Z

I've also hardcoded front controller name in router script and removed global variable, as there was no way to unset it.

---------------------------------------------------------------------------

by michal-pipa at 2012-03-13T07:57:04Z

I've used Process component, but now I don't get any stdout output (only stderr).

---------------------------------------------------------------------------

by michal-pipa at 2012-03-13T18:01:58Z

I've replaced `echo` by `$output->write()` and removed `$process` as it was not used actually.
2012-03-23 13:56:46 +01:00
Tobias Schultze
304e13daa3 replaced command names with supported placeholders in help texts 2012-03-21 05:31:52 +01:00
Fabien Potencier
91e977d38c fixed CS for previous merge 2012-03-16 13:29:17 +01:00
Rafael Dohms
2c4a43d91d Made option to use symlink explicit in the output. This can clear up any issues for example when running composer update to know if assets:install did a symlink or hard copy.
On a general it just makes communication a bit clearer on what is being executed.
2012-03-16 12:37:18 +01:00
Michał Pipa
df11e6287a [FrameworkBundle] Used $output->write() instead of echo 2012-03-13 18:54:56 +01:00
Michał Pipa
c3bf479b14 [FrameworkBundle] Used Process component 2012-03-13 08:53:22 +01:00
Michał Pipa
cfa2dff5ce [FrameworkBundle] Changed server:run command description 2012-03-13 08:47:19 +01:00
Michał Pipa
e7d38c1381 [FrameworkBundle] Changed PHP version detection (see: #3529) 2012-03-13 08:38:03 +01:00
Sebastian Busch
afbb8f215c Fixed misleading help for "name" argument as search for services with wildcards is not implemented 2012-03-07 12:09:07 +01:00
Michał Pipa
d9a0a17e17 [FrameworkBundle] Added server:run command 2012-02-27 22:48:07 +01:00
Fabien Potencier
3e326ff903 fixed typo 2012-02-18 10:47:38 +01:00
Fabien Potencier
92cb685ebc fixed CS 2012-02-10 13:35:11 +01:00
Jeremy Mikola
42c98921a2 [FrameworkBundle] Allow cache:clear/warmup to skip optional warmers 2012-02-08 20:16:02 -05:00
kbond
4847d3ad35 renamed command 2012-02-02 11:47:41 -05:00
Kevin Bond
e97af0bac0 code fixes 2012-02-02 08:20:37 -05:00
kbond
df94282dab [FrameworkBundle] removed unnecessary DebugCommand 2012-02-02 08:20:37 -05:00
kbond
8dc40e4d29 [FrameworkBundle] added config:dump console command 2012-02-02 08:20:37 -05:00
Christian Raue
9db6c8d28a print info about environment and debug mode when running the CacheWarmupCommand 2012-01-29 22:53:47 +01:00
Fabien Potencier
ca8dc87940 merged 2.0 2012-01-09 11:51:30 +01:00
Hugo Hamon
7eb1c436ae [FrameworkBundle] harmonized commands descriptions. 2012-01-09 10:01:34 +01:00
Fabien Potencier
05285e429c merged branch dustin10/cache-clearers (PR #2857)
Commits
-------

3ae976c fixed CS
84ad40d added cache clear hook

Discussion
----------

[Cache][2.1] Added cache clear hook

Allows bundles to hook into the `cache:clear` command by using the `kernel.cache_clearer` tag instead of using the `event_dispatcher` service.

See #1884

Bug fix: No
Feature addition: Yes
Backwards compatibility break: No
Symfony2 tests pass: Yes
Fixes the following tickets: #1884
References the following tickets: #1884

---------------------------------------------------------------------------

by dustin10 at 2011/12/16 11:03:54 -0800

Rebased to squash all commits into one.

---------------------------------------------------------------------------

by lsmith77 at 2011/12/17 05:27:29 -0800

@fabpot: we figured that priorities wouldn't be needed for cleaning .. haven't tested the PR, but conceptually it looks good to me and aside from the priority stuff its modeled after the cache warners.

---------------------------------------------------------------------------

by dustin10 at 2011/12/19 09:46:26 -0800

@fabpot Updated to pass cache dir to `clear` method.

---------------------------------------------------------------------------

by dustin10 at 2011/12/19 10:02:21 -0800

@stof and @fabpot Another thought I just had. Should the `$this->getContainer()->get('cache_clearer')->clear($realCacheDir);` call in the `CacheClearCommand` be done before the warming?

---------------------------------------------------------------------------

by stof at 2011/12/19 10:03:59 -0800

indeed. the clearing should be done before the warming.

---------------------------------------------------------------------------

by dustin10 at 2011/12/19 10:19:28 -0800

Squashed all commits into one. Let me know if there is anything else.

---------------------------------------------------------------------------

by dustin10 at 2011/12/19 10:31:50 -0800

Fixed extra lines.
2011-12-19 19:52:15 +01:00
Dustin Dobervich
3ae976cd5a fixed CS 2011-12-19 12:30:32 -06:00
Dustin Dobervich
84ad40dcc8 added cache clear hook 2011-12-19 12:17:48 -06:00
Fabien Potencier
142cef21bb merged 2.0 2011-12-13 16:12:53 +01:00
Fabien Potencier
e3421a0b1d [DoctrineBridge] fixed some CS 2011-12-13 10:22:12 +01:00
Fabien Potencier
fd12796673 merged 2.0 2011-12-11 18:50:50 +01:00
Robert Gruendler
40e5b609b2 [FrameworkBundle] added return type for getContainer() 2011-12-09 22:04:44 +01:00
Fabien Potencier
d34d50f0b0 fixed CS 2011-10-29 12:05:45 +02:00
Fabien Potencier
dec43f5539 merged 2.0 2011-10-29 12:01:39 +02:00
Fabien Potencier
851eb73778 removed unused use statements 2011-10-29 11:56:30 +02:00
Fabien Potencier
8cc3158d89 [FrameworkBundle] added a command to help debugging route matching problems 2011-10-24 09:08:38 +02:00
Richard Miller
79638d3734 Removed abstract as these services will not appear anyway 2011-10-18 14:02:24 +01:00
Richard Miller
312b20f94b [FrameworkBundle] Added more info to debug command output 2011-10-18 13:54:39 +01:00
Richard Miller
1768544710 Changed debug output to say Service Id rather than name for the service ids 2011-10-17 14:03:16 +01:00
Fabien Potencier
f45b1df38c merged branch stof/router_check (PR #2409)
Commits
-------

63d2ce2 [FrameworkBundle] Fixed the ckeck for the router class

Discussion
----------

[FrameworkBundle] Fixed the ckeck for the router class

The getRouteCollection method is now part of the RouterInterface so the
command should accept any implementation of the interface instead of just
the implementations extending the core one.
2011-10-16 22:37:48 +02:00
Hugo Hamon
64d970ef2d [FrameworkBundle] removed "use" statements for unused classes. 2011-10-16 18:42:34 +02:00