def ping(self, before_commit_callback=None):
        pingtime = datetime.utcnow()
        farmer = self.lookup()
        delta = pingtime - farmer.last_seen
        time_limit = delta.seconds >= app.config["MAX_PING"]

        if time_limit:
            farmer.last_seen = pingtime
            if before_commit_callback:
                before_commit_callback()
            db.session.commit()
        # else just ignore

    # TODO: Actually do an audit.
Keep-alive for the farmer. Validation can take a long time, so
dataset/ETHPy150Open Storj/dataserv/dataserv/Farmer.py/Farmer.ping