5555import java .util .Collections ;
5656import java .util .List ;
5757import java .util .UUID ;
58+ import java .util .concurrent .TimeUnit ;
5859
5960public class TermDeferredStorageSvcImpl implements ITermDeferredStorageSvc {
6061
@@ -157,7 +158,7 @@ private void processDeferredConcepts() {
157158 StopWatch stopwatch = new StopWatch ();
158159
159160 int count = Math .min (1000 , myDeferredConcepts .size ());
160- ourLog .info ("Saving {} deferred concepts..." , count );
161+ ourLog .debug ("Saving {} deferred concepts..." , count );
161162 while (codeCount < count && myDeferredConcepts .size () > 0 ) {
162163 TermConcept next = myDeferredConcepts .remove (0 );
163164 if (myCodeSystemVersionDao .findById (next .getCodeSystemVersion ().getPid ()).isPresent ()) {
@@ -174,8 +175,8 @@ private void processDeferredConcepts() {
174175 }
175176
176177 if (codeCount > 0 ) {
177- ourLog .info ("Saved {} deferred concepts ({} codes remain and {} relationships remain) in {}ms ({}ms / code )" ,
178- codeCount , myDeferredConcepts .size (), myConceptLinksToSaveLater .size (), stopwatch .getMillis (), stopwatch .getMillisPerOperation (codeCount ));
178+ ourLog .info ("Saved {} deferred concepts ({} codes remain and {} relationships remain) in {}ms ({} codes/sec )" ,
179+ codeCount , myDeferredConcepts .size (), myConceptLinksToSaveLater .size (), stopwatch .getMillis (), stopwatch .formatThroughput (codeCount , TimeUnit . SECONDS ));
179180 }
180181
181182 if (codeCount == 0 ) {
@@ -198,8 +199,8 @@ private void processDeferredConcepts() {
198199 }
199200
200201 if (relCount > 0 ) {
201- ourLog .info ("Saved {} deferred relationships ({} remain) in {}ms ({}ms / entry )" ,
202- relCount , myConceptLinksToSaveLater .size (), stopwatch .getMillis (), stopwatch .getMillisPerOperation (relCount ));
202+ ourLog .info ("Saved {} deferred relationships ({} remain) in {}ms ({} entries/sec )" ,
203+ relCount , myConceptLinksToSaveLater .size (), stopwatch .getMillis (), stopwatch .formatThroughput (relCount , TimeUnit . SECONDS ));
203204 }
204205
205206 if ((myDeferredConcepts .size () + myConceptLinksToSaveLater .size ()) == 0 ) {
0 commit comments