|
|
@@ -669,7 +669,7 @@ func refreshUserStaticTable(wikiCountMap map[string]int, tableName string, pageS |
|
|
|
log.Info("insert all data failed." + err.Error()) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
log.Info("TotalHasActivityUser=" + fmt.Sprint(userMetrics["TotalHasActivityUser"])) |
|
|
|
//normalization |
|
|
|
for k, v := range userIndexMap { |
|
|
|
tmpResult := (v - minUserIndex) / (maxUserIndex - minUserIndex) |
|
|
@@ -868,6 +868,7 @@ func CounDataByDateAndReCount(wikiCountMap map[string]int, startTime time.Time, |
|
|
|
dateRecord.UserIndexPrimitive = getUserIndex(dateRecord, ParaWeight) |
|
|
|
setUserMetrics(userMetrics, userRecord, start_unix, end_unix, dateRecord) |
|
|
|
if getUserActivate(dateRecord) > 0 { |
|
|
|
log.Info("has activity." + userRecord.Name) |
|
|
|
addUserToMap(userNewAddActivity, userRecord.CreatedUnix, dateRecord.ID) |
|
|
|
} |
|
|
|
if userRecord.IsActive { |
|
|
|