<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://rt-wiki.bestpractical.com/index.php?action=history&amp;feed=atom&amp;title=TransactionAttach</id>
	<title>TransactionAttach - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://rt-wiki.bestpractical.com/index.php?action=history&amp;feed=atom&amp;title=TransactionAttach"/>
	<link rel="alternate" type="text/html" href="https://rt-wiki.bestpractical.com/index.php?title=TransactionAttach&amp;action=history"/>
	<updated>2026-08-22T05:27:07Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.1</generator>
	<entry>
		<id>https://rt-wiki.bestpractical.com/index.php?title=TransactionAttach&amp;diff=3907&amp;oldid=prev</id>
		<title>Admin: 2 revisions imported</title>
		<link rel="alternate" type="text/html" href="https://rt-wiki.bestpractical.com/index.php?title=TransactionAttach&amp;diff=3907&amp;oldid=prev"/>
		<updated>2016-04-06T20:39:30Z</updated>

		<summary type="html">&lt;p&gt;2 revisions imported&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Patch for Transaction_Overlay.pm ==&lt;br /&gt;
&lt;br /&gt;
=== Function: _Attach ===&lt;br /&gt;
&lt;br /&gt;
The original function always returns an RT::Attachment object, which passes for an id in the calling function. The effect is that when the (often inexplicable) &amp;quot;mysql server has gone away&amp;quot; clobbers RT::Transaction::Create, and a subsequent RT::Attachment::Create fails, the calling RT::Transaction object merrily marches ahead and processes scrips (probably sending autoreplies) for a ticket that will never make it into the database. The patch replaces the RT::Attachement object with the $id of the attachment (or zero when RT::Attachement::Create fails) as expected by the calling function. So, instead of a phantom ticket, the requestor gets a message telling him that the ticket did not materialize, and he can proceed accordingly.&lt;br /&gt;
&lt;br /&gt;
# cat /opt/rt3/patches/[[Transaction Overlay|Transaction_Overlay]].patch&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;*** /lib/RT/Transaction_Overlay.pm      Tue Apr  1 16:36:01 2008&lt;br /&gt;
 --- /lib/RTTransaction_Overlay.pm       Tue Apr  1 22:47:18 2008&lt;br /&gt;
 ***************&lt;br /&gt;
 *** 507,513 ****&lt;br /&gt;
           TransactionId =&amp;amp;gt; $self-&amp;amp;gt;Id,&lt;br /&gt;
           Attachment    =&amp;amp;gt; $MIMEObject&lt;br /&gt;
       );&lt;br /&gt;
 !     return ( $Attachment, $msg || $self-&amp;amp;gt;loc(&amp;quot;Attachment created&amp;quot;) );&lt;br /&gt;
 &lt;br /&gt;
   }&lt;br /&gt;
 &lt;br /&gt;
 --- 507,513 ----&lt;br /&gt;
           TransactionId =&amp;amp;gt; $self-&amp;amp;gt;Id,&lt;br /&gt;
           Attachment    =&amp;amp;gt; $MIMEObject&lt;br /&gt;
       );&lt;br /&gt;
 !     return ($id || 0,  $msg || $self-&amp;amp;gt;loc(&amp;quot;Attachment created&amp;quot;) );&lt;br /&gt;
 &lt;br /&gt;
   }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>