Skip to content
Snippets Groups Projects
  1. Oct 06, 2013
    • Jared Hancock's avatar
      Crazy performance penalty scanning blob tables · 60fcf00c
      Jared Hancock authored
      When scanning the file_chunk table for orphaned file chunks that can be
      deleted, apparently, MySQL will read (at least part of) the blob data from
      the disk. For databases with lots of large attachments, this can take
      considerable time. Considering that it is triggered from the autocron and
      will run everytime the cron is run, the database will spend considerable
      time scanning for rows to be cleaned.
      
      This patch changes the orphan cleanup into two phases. The first will search
      just for the pk's of file chunks to be deleted. If any are found, then the
      chunks are deleted by the file_id and chunk_id, which is the primary key of
      the table.
      
      The SELECT query seems to run at least 20 times faster than the delete
      statement, and DELETEing against the primary key of the blob table should
      be the fastest possible operation. Somehow, both queries required a full
      table scan; however, because the SELECT statement is explictly only
      interested in two fields, it is more clear to the query optimizer that the
      blob data should not be scanned.
      
      References:
      http://stackoverflow.com/q/9511476
      60fcf00c
  2. Sep 20, 2013
  3. Sep 18, 2013
  4. Sep 13, 2013
    • Jared Hancock's avatar
      Avoid double-encoding thread titles · bd680889
      Jared Hancock authored
      This is safe now, because the title is appropriately encoded in
      class.thread.php/ThreadEntry::create()
      
      Fixes #567, #718
      bd680889
    • Jared Hancock's avatar
      Fixes cookie domain specification · eecd0b1a
      Jared Hancock authored
      if the domain given in HTTP_HOST variable happens to have a port
      specification. Technically, the port specification should not be included in
      the domain spec given in the cookie.
      
      (And for the record, that makes no sense to me, seeing as a cookie would
      otherwise be valid for all servers on any ports at a particular domain).
      eecd0b1a
  5. Sep 12, 2013
    • Jared Hancock's avatar
      Fix up ROOT_PATH, yet again · c8197915
      Jared Hancock authored
      The previous implementation did not work correctly for symlinked folders.
      The new approach uses debug_backtrace() and ROOT_DIR to determine the
      difference between ROOT_DIR and the osTicket installation path.
      
      This thing is like a turd that won't flush
      c8197915
  6. Sep 11, 2013
  7. Sep 09, 2013
    • Jared Hancock's avatar
      Forbid message loops for alert messages · 6e5c1f6a
      Jared Hancock authored
      If an alert message manages to loop back into the ticketing system, refuse
      posting to the ticket thread. Technically, the message should be marked as
      an auto-response message; however, auto-response messages should usually be
      allowed to be appended to the ticket thread.
      
      This patch will check if the From email header cites an email address that
      is a system email address (visible in the Emails section of the Admin
      Panel). If it is, the email is completely ignored.
      6e5c1f6a
    • Peter Rotich's avatar
  8. Sep 06, 2013
  9. Sep 05, 2013
Loading