Skip to content
Snippets Groups Projects

mkpkglists improvements

Merged Kevin Morris requested to merge kevr/aurweb:teapot into master
All threads resolved!

This overlaid MR changes a couple things, namely the format of the meta package archive and only updating archives when needed.

Update When Needed:

We now use the information_schema.tables AUTO_INCREMENT column to keep track of a "serial number" that can be used to tell us whether we need to update or not.

Metadata Format:

    The SQL logic in this file for package metadata now exactly
    reflects RPC's search logic, without searching for specific
    packages.

    Two command line arguments are available:

        --extended | Include License, Keywords and Groups fields

    When one of these arguments are passed, the script will create
    a packages-meta-ext-v1.json.gz, configured via packagesmetaextfile.

    Archive JSON is in the following format: line-separated package objects
    enclosed in a list:

        [
        {...},
        {...},
        {...}
        ]

    This allows users to stream the archive and process packages
    line-by-line, during the local storage process.

    Signed-off-by: Kevin Morris <kevr@0cost.org>
Edited by Kevin Morris

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Jelle van der Waa
  • Kevin Morris added 1 commit

    added 1 commit

    • 5af86a9a - fix(php): route packages-meta-v1.json.gz for packages meta archive

    Compare with previous version

  • Jelle van der Waa resolved all threads

    resolved all threads

  • Kevin Morris added 1 commit

    added 1 commit

    • c2dc6083 - fix(mkpkglists): revert to iterating over cur.fetchall() once

    Compare with previous version

  • Kevin Morris resolved all threads

    resolved all threads

  • Kevin Morris resolved all threads

    resolved all threads

  • Author Contributor

    Status: Not really sure why sharness tests are now failing. I'll look into this and resolve it, but otherwise, the script is functional.

    Edit: Fixed.

    Edited by Kevin Morris
  • Author Contributor

    Question: Should I just remove the print(...)s out of this MR? I figure that logging for cache state would be nice, but that means if a persistent log is kept, we can't let it get too large.

    Edited by Kevin Morris
  • Kevin Morris added 1 commit

    added 1 commit

    • 89cdabda - fix(mkpkglists): revert to iterating over cur.fetchall() once

    Compare with previous version

  • Kevin Morris changed the description

    changed the description

  • Kevin Morris added 1 commit

    added 1 commit

    • d33845e8 - fix(mkpkglists): fix tuple return for non-mysql

    Compare with previous version

  • Author Contributor

    We probably want to provide the same exact format that RPC [multi]info does.

    Tasks:

    • Use [multi]info JSON format.
    Edited by Kevin Morris
  • Kevin Morris added 1 commit

    added 1 commit

    • 3d31e860 - fix(mkpkglists): add all info fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • 33d58386 - fix(mkpkglists): add all info fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • 2949e39d - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • 491e1018 - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris changed the description

    changed the description

  • Kevin Morris added 1 commit

    added 1 commit

    • 001e16a9 - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris changed the description

    changed the description

  • Kevin Morris added 1 commit

    added 1 commit

    • 1229c464 - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • ce635a1d - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • e5cd3e1e - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • 334f73af - cleanup(mkpkglists): Last minute sanitization

    Compare with previous version

  • Kevin Morris changed the description

    changed the description

  • Kevin Morris added 13 commits

    added 13 commits

    • 334f73af...64ba18e4 - 4 commits from branch archlinux:master
    • 69773a5b - feat(PHP): Add packages dump file with more metadata
    • 928ef295 - fix(mkpkglists): improve package meta archive
    • 5b4931d9 - feat(mkpkglists): cache update states of mkpkglists
    • adee633d - fix(mkpkglists): only check against cache if we're using mysql
    • 197b04d6 - fix(php): route packages-meta-v1.json.gz for packages meta archive
    • d8c0921e - fix(mkpkglists): revert to iterating over cur.fetchall() once
    • c53041f9 - fix(mkpkglists): fix tuple return for non-mysql
    • 37e7c201 - fix(mkpkglists): add all RPC type=search fields to packages-meta-v1
    • 758c755f - cleanup(mkpkglists): Last minute sanitization

    Compare with previous version

  • Kevin Morris changed the description

    changed the description

  • Kevin Morris added 1 commit

    added 1 commit

    • 51fb24ab - fix(mkpkglists): improve package meta archive

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • d5df4182 - feat(mkpkglists): added metadata archives

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • df0b70bc - feat(mkpkglists): added metadata archives

    Compare with previous version

  • Kevin Morris added 1 commit

    added 1 commit

    • cdca8bd2 - feat(mkpkglists): added metadata archives

    Compare with previous version

  • merged

  • Please register or sign in to reply
    Loading