Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
1ff5f845
Commit
1ff5f845
authored
Jun 19, 2011
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added apc driver notes in cache configuration file.
parent
ab3be568
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
23 deletions
+14
-23
cache.php
application/config/cache.php
+14
-14
apc.php
system/cache/driver/apc.php
+0
-9
No files found.
application/config/cache.php
View file @
1ff5f845
...
...
@@ -12,12 +12,24 @@ return array(
| Caching can be used to increase the performance of your application
| by storing commonly accessed data in memory or in a file.
|
| Supported Drivers: 'file', 'memcached'.
| Supported Drivers: 'file', 'memcached'
, 'apc'
.
|
*/
'driver'
=>
'file'
,
/*
|--------------------------------------------------------------------------
| Cache Key
|--------------------------------------------------------------------------
|
| This key will be prepended to items stored using Memcached and APC to
| prevent collisions with other applications on the server.
|
*/
'key'
=>
'laravel'
,
/*
|--------------------------------------------------------------------------
| Memcached Servers
...
...
@@ -35,18 +47,6 @@ return array(
'servers'
=>
array
(
array
(
'host'
=>
'127.0.0.1'
,
'port'
=>
11211
,
'weight'
=>
100
),
),
/*
|--------------------------------------------------------------------------
| Memcached Key
|--------------------------------------------------------------------------
|
| This key will be prepended to items stored using Memcached to avoid
| collisions with other applications on the server.
|
*/
'key'
=>
'laravel'
,
),
);
\ No newline at end of file
system/cache/driver/apc.php
View file @
1ff5f845
...
...
@@ -29,22 +29,13 @@ class APC implements \System\Cache\Driver {
*/
public
function
get
(
$key
,
$default
=
null
)
{
// --------------------------------------------------
// If the item has already been loaded, return it.
// --------------------------------------------------
if
(
array_key_exists
(
$key
,
$this
->
items
))
{
return
$this
->
items
[
$key
];
}
// --------------------------------------------------
// Attempt to the get the item from cache.
// --------------------------------------------------
$cache
=
apc_fetch
(
\System\Config
::
get
(
'cache.key'
)
.
$key
);
// --------------------------------------------------
// Verify that the item was retrieved.
// --------------------------------------------------
if
(
$cache
===
false
)
{
return
$default
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment