Take out comment rendering logging

This commit is contained in:
Raphael 2010-11-27 23:46:13 -05:00
parent 6d6b07fb92
commit 5b29cff56a
2 changed files with 18 additions and 13 deletions

View file

@ -34,7 +34,12 @@ class StatusMessagesController < ApplicationController
respond_to do |format|
format.js{ render :json => { :post_id => @status_message.id,
:html => render_to_string(:partial => 'shared/stream_element', :locals => {:post => @status_message, :aspects => current_user.aspects, :current_user => current_user})},
:html => render_to_string(
:partial => 'shared/stream_element',
:locals => {
:post => @status_message,
:aspects => current_user.aspects,
:current_user => current_user})},
:status => 201 }
format.html{ respond_with @status_message }
end

View file

@ -3,23 +3,23 @@
-# the COPYRIGHT file.
%li.comment{:data=>{:guid=>comment.id}}
-start=Time.now
/-start=Time.now
%a{:href => "/people/#{person.id}"}
%img{:src => image_or_default(person), :class => "avatar", :alt => person.real_name, :title => person.real_name, "data-person_id" => person.id}
- post_image_link=Time.now
/- post_image_link=Time.now
.content
.from
%a{:href => "/people/#{person.id}"}=person.real_name
- post_person_link=Time.now
/- post_person_link=Time.now
= markdownify(comment.text, :youtube_maps => comment[:youtube_titles])
- markdownified=Time.now
/- markdownified=Time.now
%div.time
= "#{time_ago_in_words(comment.updated_at)} #{t('ago')}"
- time_agoed=Time.now
- log_string = "event=comment_partial im_link=#{(post_image_link - start)*1000} "
- log_string << "pr_link=#{(post_person_link - post_image_link)*1000} "
- log_string << "markdown=#{(markdownified - post_person_link)*1000} "
- log_string << "time_agoed=#{(time_agoed - markdownified)*1000} "
- log_string << "total=#{(time_agoed - start)*1000} "
- log_string << "comment_id=#{comment.id}"
- Rails.logger.info(log_string)
/- time_agoed=Time.now
/- log_string = "event=comment_partial im_link=#{(post_image_link - start)*1000} "
/- log_string << "pr_link=#{(post_person_link - post_image_link)*1000} "
/- log_string << "markdown=#{(markdownified - post_person_link)*1000} "
/- log_string << "time_agoed=#{(time_agoed - markdownified)*1000} "
/- log_string << "total=#{(time_agoed - start)*1000} "
/- log_string << "comment_id=#{comment.id}"
/- Rails.logger.info(log_string)