Added updating resource counters