Added debug messages to get more details about issue on ci env.

This commit is contained in:
Martin Edenhofer 2015-05-02 13:57:20 +02:00
parent 4b7026ab4d
commit 752ed6d73f

View file

@ -24,12 +24,13 @@ class Sessions::Backend::TicketOverviewList
data = { list: overview_data, index: overview } data = { list: overview_data, index: overview }
result.push data result.push data
} }
puts "LOG A #{result.inspect}"
# no data exists # no data exists
return if !result || result.empty? return if !result || result.empty?
# no change exists # no change exists
return if @last_change == result return if @last_change == result
puts "LOG B #{result.inspect}"
# remember last state # remember last state
@last_change = result @last_change = result
@ -44,19 +45,22 @@ class Sessions::Backend::TicketOverviewList
def push def push
# check interval # check interval
puts "LOG 1 #{@user.inspect}"
return if Sessions::CacheIn.get( self.client_key ) return if Sessions::CacheIn.get( self.client_key )
# reset check interval # reset check interval
puts "LOG 2 #{@ttl.seconds}"
Sessions::CacheIn.set( self.client_key, true, { expires_in: @ttl.seconds } ) Sessions::CacheIn.set( self.client_key, true, { expires_in: @ttl.seconds } )
# check if min one ticket has changed # check if min one ticket has changed
last_ticket_change = Ticket.latest_change last_ticket_change = Ticket.latest_change
puts "LOG 3 #{last_ticket_change}/#{@last_ticket_change}"
return if last_ticket_change == @last_ticket_change return if last_ticket_change == @last_ticket_change
@last_ticket_change = last_ticket_change @last_ticket_change = last_ticket_change
# load current data # load current data
items = self.load items = self.load
puts "LOG 4 #{items.inspect}"
return if !items return if !items
# push overviews # push overviews