add index V1 format, a direct translation of internal dict

Python encode/decode libs work directly with dicts, so the internal dict
can just be passed directly to any of these libs (pyyaml, pyjson, msgpack,
simplejson, etc).  This still generates the exact same index.xml as before.

This converts the internal format for the repo timestamp to a datetime
instance, which can be easily converted to UNIX time in seconds for XML
and UNIX time in milliseconds for the new index formats.  UNIX time in
milliseconds is directly serialized into a java.util.Date instance by
Jackson.
This commit is contained in:
Hans-Christoph Steiner 2016-11-28 21:09:07 +01:00
parent b3a5db52f7
commit c9aa26d89e
5 changed files with 196 additions and 77 deletions

View file

@ -2192,5 +2192,7 @@ def is_repo_file(filename):
'index_unsigned.jar',
'index.xml',
'index.html',
'index-v1.jar',
'index-v1.json',
'categories.txt',
]