Skip to content

Commit b6bae56

Browse files
committed
Vestigial log is removed
1 parent 742c066 commit b6bae56

File tree

1 file changed

+20
-16
lines changed

1 file changed

+20
-16
lines changed

lib/consumer/postgres/postgres.rb

Lines changed: 20 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,28 +12,32 @@ def self.included(cls)
1212
end
1313
end
1414

15-
def starting
16-
## unless batch_size.nil?
17-
## logger.info(tag: :*) { "Batch Size: #{batch_size.inspect}" }
18-
## end
19-
logger.debug(tag: :*) { "Batch Size: #{batch_size.inspect}" }
15+
def print_startup_info
16+
STDOUT.puts " Batch Size: #{get.batch_size.inspect}"
2017

21-
## unless correlation.nil?
22-
## logger.info(tag: :*) { "Correlation: #{correlation.inspect}" }
23-
## end
24-
logger.debug(tag: :*) { "Correlation: #{correlation.inspect}" }
18+
unless correlation.nil?
19+
STDOUT.puts " Correlation: #{correlation || '(none)'}"
20+
end
21+
22+
unless group_member.nil? && group_size.nil?
23+
STDOUT.puts " Group Member: #{group_member.inspect}"
24+
STDOUT.puts " Group Size: #{group_size.inspect}"
25+
end
26+
27+
unless condition.nil?
28+
STDOUT.puts " Condition: #{condition.inspect}"
29+
end
30+
end
2531

26-
## unless group_member.nil? && group_size.nil?
27-
## logger.info(tag: :*) { "Group Member: #{group_member.inspect}, Group Size: #{group_size.inspect}" }
28-
## end
32+
def log_startup_info
33+
logger.debug(tag: :*) { "Batch Size: #{get.batch_size.inspect}" }
34+
logger.debug(tag: :*) { "Correlation: #{correlation.inspect}" }
2935
logger.debug(tag: :*) { "Group Member: #{group_member.inspect}" }
3036
logger.debug(tag: :*) { "Group Size: #{group_size.inspect}" }
31-
32-
## unless condition.nil?
33-
## logger.info(tag: :*) { "Condition: #{condition.inspect}" }
34-
## end
3537
logger.debug(tag: :*) { "Condition: #{condition.inspect}" }
38+
end
3639

40+
def starting
3741
if identifier.nil? && !group_member.nil? && !group_size.nil?
3842
raise Identifier::Error, 'Identifier must not be omitted when the consumer is a member of a group'
3943
end

0 commit comments

Comments
 (0)