Your description is still a little bit too abstract to determine whether a storage extension is the best place to handle this- could you be a little bit more specific about why it is you want to do this.
There is user information available on the content delivery side, however this is not necessarily the user who published the item. If you look in the ITEMS table in the broker database, you will see a TRUSTEE column which contains the username (not ID) of the user who last edited the item. If you look at a transport package you can also find this information in the xml file for the item(s) published. For example for a component, in components.xml:
<Component Id="tcm:9-99" isMultimedia="false">
<Schema Id="tcm:9-95-8" />
<OwningPublication Id="tcm:0-4-1" />
So I guess you can access this information from within a storage/deployer extension.
If you really need the user who published the transaction, Version 2013+ contains an update whereby you can, from templates access the user who published via
Engine.PublishContext.RenderContext.PublishTransaction.Creator. Note that this is not applicable for 2011 and earlier versions, where its a bit harder to get the Publish Transaction
So one thing you could do is add a binary on the fly into the publish transaction which is an xml file containing user id and whatever other details you want to store. Give it a suitably unique file extension (like .ptinfo or something) and then create a Item mapping for this file extension in your storage conf and a storage extension to put it in your MySQL database. The following gives some (untested) TBB code to do this...
public class AddTransactionInfo : ITemplate
public void Transform(Engine engine, Package package)
var renderContext = engine.PublishingContext.RenderContext;
//Context variables have scope of the whole transaction, so we can use them
//to ensure we only generate the binary once per transaction.
if (renderContext != null && !renderContext.ContextVariables.Contains("PublishTransactionInfo"))
var pubTransaction = renderContext.PublishTransaction;
//Create an XML binary stream with the user id
XDocument infoXml = XDocument.Parse("<transaction/>");
MemoryStream binaryStream = new MemoryStream();
//Add the binary with unique filename and special file extension
engine.PublishingContext.RenderedItem.AddBinary(binaryStream, pubTransaction.Id.ItemId + ".ptinfo", "ptinfo", "text/xml");
//Set the context variable to prevent repeating this process