Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

Use php://temp instead of php://memory by default in Request #14

Closed
wants to merge 1 commit into from

Conversation

dunglas
Copy link
Contributor

@dunglas dunglas commented May 24, 2015

Avoid problem of exceeded memory when dealing with large requests.

@dunglas dunglas changed the title Use php://temp instead of php:// memory by default in Response Use php://temp instead of php://memory by default in Response May 24, 2015
@Ocramius
Copy link
Member

@dunglas pardon the ignorance, but will php://temp write to memory until a limit is reached? I just want to avoid file I/O on each usage, and couldn't find clear documentation about this wrapper ;-)

@Ocramius Ocramius added this to the 1.0.1 milestone May 25, 2015
@Ocramius Ocramius self-assigned this May 25, 2015
@dunglas
Copy link
Contributor Author

dunglas commented May 25, 2015

@Ocramius yes. The default limit is 2 Mo (can be configured by using the following syntax php://temp:NN: where NN is the limit in bytes).

The doc is available here: http://php.net/manual/en/wrappers.php.php I struggled to find it too.

@Ocramius
Copy link
Member

Thanks!

@Ocramius Ocramius closed this in f347705 May 26, 2015
Ocramius added a commit that referenced this pull request May 26, 2015
…-response-crashes' into develop

Close #14
Forward port #14
@Ocramius
Copy link
Member

Merged, thanks!

master: f347705
develop: 0d5bc99

@sasezaki
Copy link
Contributor

Title is Response, but changed is Request ?

@dunglas
Copy link
Contributor Author

dunglas commented May 26, 2015

@sasezaki good catch my title is wrong. I update it.

@dunglas dunglas changed the title Use php://temp instead of php://memory by default in Response Use php://temp instead of php://memory by default in Request May 26, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants