-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #273 from steverobbins/feature/memory-usage
Add memory usage column to scheduler list
- Loading branch information
Showing
6 changed files
with
45 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
app/code/community/Aoe/Scheduler/Block/Adminhtml/Scheduler/Renderer/Memory.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?php | ||
|
||
class Aoe_Scheduler_Block_Adminhtml_Scheduler_Renderer_Memory | ||
extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract | ||
{ | ||
public function render(Varien_Object $row) | ||
{ | ||
$value = $row->getMemoryUsage(); | ||
if ($value) { | ||
return number_format($row->getMemoryUsage(), 2) . ' MB'; | ||
} | ||
return parent::render($row); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
app/code/community/Aoe/Scheduler/sql/aoescheduler_setup/mysql4-upgrade-1.4.0-1.5.0.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?php | ||
|
||
$installer = $this; /* @var $installer Mage_Core_Model_Resource_Setup */ | ||
|
||
$installer->startSetup(); | ||
|
||
$installer->getConnection()->addColumn($installer->getTable('cron/schedule'), 'memory_usage', array( | ||
'type' => Varien_Db_Ddl_Table::TYPE_DECIMAL, | ||
'length' => '12,4', | ||
'unsigned' => true, | ||
'nullable' => true, | ||
'default' => null, | ||
'comment' => 'Memory Used in MB', | ||
)); | ||
|
||
$installer->endSetup(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters