mirror of https://github.com/zlatinb/muwire
count the times a file has been hit due to feed update
parent
886effa3b6
commit
54f4874ad6
|
@ -574,7 +574,9 @@ class ConnectionAcceptor {
|
||||||
|
|
||||||
DataOutputStream dos = new DataOutputStream(new GZIPOutputStream(os))
|
DataOutputStream dos = new DataOutputStream(new GZIPOutputStream(os))
|
||||||
JsonOutput jsonOutput = new JsonOutput()
|
JsonOutput jsonOutput = new JsonOutput()
|
||||||
|
final long now = System.currentTimeMillis();
|
||||||
published.each {
|
published.each {
|
||||||
|
it.hit(requestor, now, "Feed Update");
|
||||||
int certificates = certificateManager.getByInfoHash(new InfoHash(it.getRoot())).size()
|
int certificates = certificateManager.getByInfoHash(new InfoHash(it.getRoot())).size()
|
||||||
def obj = FeedItems.sharedFileToObj(it, certificates)
|
def obj = FeedItems.sharedFileToObj(it, certificates)
|
||||||
def json = jsonOutput.toJson(obj)
|
def json = jsonOutput.toJson(obj)
|
||||||
|
|
Loading…
Reference in New Issue