Scaling Magento presentation with 60 slides and notes, which was then reviewed by Alan Storm.
backend default { | |
.host = "127.0.0.1"; | |
.port = "80"; | |
.first_byte_timeout = 300s; | |
} | |
/* | |
Like the default function, only that cookies don't prevent caching | |
*/ | |
sub vcl_recv { |
/* | |
* clearIntArray | |
* This function deletes all items in array (sets it to 0) and resizes array according to size (default = 1). | |
* @param int& theArray - passing the array by reference | |
* @param int size - size of the array (default = 1) | |
* @return int blank array of size | |
*/ | |
int clearIntArray( int& theArray[], int size = 0 ) { | |
ArrayResize( theArray, size ); | |
if ( size > 0 ) { ArrayInitialize( theArray, 0 ); } |
<?php | |
define('MAGENTO', realpath(dirname(__FILE__))); | |
require_once MAGENTO . '/app/Mage.php'; | |
Mage::app(); | |
$category = Mage::getModel ('catalog/category'); | |
$tree = $category->getTreeModel(); | |
$tree->load(); |
After having many deadlocks due to a high order volumne I've applied the these fixes to the core. Some can be found in a Magento forum. Before the fixes we could only process 1 order every 5-10 secs. Updating to Magento 1.8 is currently not an option but in 1-2 months.
Mage_Sales_Model_Abstract::_afterSave
must be removed and replaced with afterCommitCallback
. This is important to move the grid update (of sales_flat_order_grid) out of the transaction.
Rewrite the method of the Mage_CatalogInventory_Model_Observer::reindexQuoteInventory()
to remove the price reindexing from the transaction. That index process will also be fired in event sales_model_service_quote_submit_success
.
Magento’s checkout throughput can increase to at least 8 times its current capacity and up to 26 times more in ideal conditions.
- The current checkouts per hour limit for large, real-world Magento stores is 4,500
- This limit cannot effectively be increased with more and/or better hardware
- The improper type handling in Magento’s SQL code is the cause of the current limit
- If one SQL query is fixed, large Magento stores can scale to a new, real-world limit of 120,000 checkouts per hour
- For commodity hardware, this new limit might be 36,000 checkouts per hour
<?xml version="1.0"?> | |
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Acl/etc/acl.xsd"> | |
<acl> | |
<resources> | |
<resource id="Magento_Backend::admin"> | |
</resource> | |
</resources> | |
</acl> | |
</config> |
export GIT_PS1_SHOWDIRTYSTATE=true | |
export GIT_PS1_SHOWUNTRACKEDFILES=true | |
export PS1="\$([[ \$? != 0 ]] && echo \"[\[\033[0;31m\]\342\234\227\[\033[0;37m\]] \")[\e[38;5;240m\@\e[m] [$(if [[ ${EUID} == 0 ]]; then echo '\[\033[0;31m\]\h'; else echo '\[\e[38;5;193m\u\[\033[0;37m\]@\e[38;5;26m\h'; fi)\[\033[0;37m\]][\[\033[0;32m\]\w\[\033[0;37m\]]\e[38;5;198m\$(__git_ps1 "[%s]")\e[m\n$ " |
const http = require('http'); | |
const server = http.createServer(); | |
server.on('request', (request, response) => { | |
let body = []; | |
request.on('data', (chunk) => { | |
body.push(chunk); | |
}).on('end', () => { | |
body = Buffer.concat(body).toString(); |
This guide is only for original Ubuntu out-of-the-box packages. If you have added a custom PPA like
pipewire-debian
, you might get into conflicts.
Ubuntu 22.04 has PipeWire partially installed and enabled as it's used by browsers (WebRTC) for recoding the screeen under Wayland. We can enable remaining parts and use PipeWire for audio and Bluetooth instead of PulseAudio.
Starting from WirePlumber version 0.4.8 automatic Bluetooth profile switching (e.g. switching from A2DP to HSP/HFP when an application needs microphone access) is supported. Jammy (22.04) repos provide exactly version 0.4.8. So, we're good.
Based on Debian Wiki, but simplified for Ubuntu 22.04.