There are two methods to increment an attribute in Rails:
Instance-level: http://apidock.com/rails/ActiveRecord/Base/increment!
Class-level: http://apidock.com/rails/ActiveRecord/Base/increment_counter/class
I want to update a counter attribute on my Post model that saves the number of comments for a post.
Is any of the two better for my use case?
I will use it with a PostgreSQL database.