Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Profiler] non unique profile token create warnings #7171

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

Closed
DerManoMann opened this issue Feb 24, 2013 · 0 comments
Closed

[Profiler] non unique profile token create warnings #7171

DerManoMann opened this issue Feb 24, 2013 · 0 comments

Comments

@DerManoMann
Copy link
Contributor

I do have a case where in dev mode the app loads heaps of single resources (css/js/etc). Most of those are rather small and in prod they are combined, compressed, etc.

Since the profiler uses uniqid() to create the profile token I see randomly (but consistently) warnings about files/dirs that already exist (using FileProfileStorage). I would expect other storage classes to suffer similarly.
This seems to be a racing condition where two requests do have the same request time in milliseconds.

Are there any reason to not use the more_entropy flag and/or the prefix on the uniqid() call?

Alternatively, are there other ways to avoid this by different means?

@fabpot fabpot closed this as completed Mar 6, 2013
fabpot added a commit that referenced this issue Mar 11, 2013
* 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants