Try to create a generator for yaml dumping
Try to create a generator for yaml dumping

When fetching a huge yaml file, generating one item by one is in fact faster.
Without this change, fetching 25000 results is impossible (timout in gunicorn).

Change-Id: Ib21555010dc5b1c3b9fc57c2ee0df65bcfb94e70

Linaro/lava-server,Linaro/lava-server,Linaro/lava-server,Linaro/lava-server