TODO
author Kristian H?gsberg <krh@jiraiya.boston.redhat.com>
Wed Apr 09 21:28:17 2008 -0400 (2008-04-09)
changeset 213 8f8b782b7a0e
parent 200 4c4955871c21
child 214 d1e9e6a80151
permissions -rw-r--r--
Edit TODO a bit.
krh@65
     1
Towards replacing rpm + yum (0.1):
krh@65
     2
krh@82
     3
- installer part:
krh@65
     4
krh@82
     5
   - pre install check; check that dirs can be created (no files where
krh@82
     6
     want to create dirs), move config files according to file
krh@82
     7
     flags. (.rpmnew etc)
krh@65
     8
krh@82
     9
   - store rpm headers for installed packages.
krh@65
    10
krh@189
    11
- rpm seems to consider glibc > 2.6.90 to mean greater than
krh@189
    12
  2.6.90-anything.  That is, a comparison that doesn't mention the
krh@189
    13
  release field, shouldn't regard the release field of pkgs it
krh@189
    14
  compares against.  glibc-common-2.6.90 has
krh@189
    15
krh@189
    16
	conflicts: glibc < 2.6.90, glibc > 2.6.90
krh@189
    17
krh@189
    18
  since rpm doesn't let you do glibc != 2.6.90, and
krh@189
    19
krh@189
    20
	requires: glibc = 2.6.90
krh@189
    21
krh@189
    22
  will always pull in glibc.  But even with a != relation, would
krh@189
    23
  glibc-2.6.90-16 be equal to 2.6.90?  glibc 2.7.90-8 dropped it in
krh@189
    24
  favor of requires = 2.7.90-8 (#225806).
krh@189
    25
krh@65
    26
- signed packages
krh@65
    27
krh@65
    28
- figure out how to canonically represent empty string... ~0?
krh@65
    29
krh@70
    30
- space calculation before transaction, but ideally, do a number of
krh@70
    31
  smaller transactions.
krh@70
    32
krh@70
    33
- pre-link changing binaries and libs on disk screwing up checksum?
krh@70
    34
krh@82
    35
- pipelined download and install; topo-sort packages in update set,
krh@82
    36
  pick one with all deps in the current set, add it to the current set
krh@82
    37
  and satisfy deps against update set => result: minimal update
krh@82
    38
  transaction.  Queue download and install/update transaction for the
krh@82
    39
  packages in the minimal set, start over.  This also makes the
krh@82
    40
  installation phase much more interruptible, basically just stop
krh@82
    41
  after a sub-transaction finishes.  As we keep the update set around
krh@82
    42
  as a target, we can restart if needed.  Probably don't need to, can
krh@82
    43
  just do a new update.  During a sub-transaction we should keep the
krh@82
    44
  target set (i.e. the current set to be) around as a lock file
krh@82
    45
  (system.repo.lock or so, see git) so that razor updates are
krh@82
    46
  prevented if the systems crashes during an update.
krh@74
    47
krh@213
    48
krh@213
    49
Package set file format items:
krh@213
    50
krh@213
    51
- drop the 4k section alignment
krh@213
    52
krh@213
    53
- just use strings for header identifiers, make the string pool
krh@213
    54
  section have a fixed string (maybe make "strings" always the first
krh@213
    55
  string so its index is 0), or maybe just require that it's the first
krh@213
    56
  section in the file.
krh@213
    57
krh@213
    58
- nail down byte-order of repo file.
krh@213
    59
krh@213
    60
- version the sections in the file, put the element size in the header
krh@213
    61
  so we can add stuff to elements in a backwards compatible way.
krh@213
    62
  maybe not necessary, we can just add sections that augment the
krh@213
    63
  sections we want to add to (similar to how rpm has add versioned
krh@213
    64
  deps).
krh@213
    65
krh@213
    66
krh@65
    67
Misc ideas:
krh@65
    68
krh@1
    69
- keep history of installed packages/journal of package transaction,
krh@1
    70
  so we can roll back to yesterday, or see what got installed in the
krh@1
    71
  latest yum update.
krh@1
    72
krh@8
    73
- transactions, proper recovery, make sure we don't poop our package
krh@8
    74
  database (no more rm /var/lib/rpm/__cache*).
krh@8
    75
krh@18
    76
- use hash table for package and property lists so we only store
krh@18
    77
  unique lists (like for string pool).
krh@40
    78
krh@40
    79
- use existing, running system as repo; eg
krh@40
    80
krh@40
    81
	razor update razor://other-box.local evince
krh@40
    82
krh@40
    83
  to pull eg the latest evince and dependencies from another box.  We
krh@40
    84
  should be able to regenerate a rzr pkg from the system so we can
krh@40
    85
  reuse the signature from the originating repo.
krh@41
    86
krh@41
    87
- Ok, maybe the fastest package set merge method in the end is to use
krh@41
    88
  the razor_importer, but use a hash table for the properties.  This
krh@41
    89
  way we can assign them unique IDs immediately (like tokenizing
krh@41
    90
  strings).
krh@47
    91
krh@47
    92
- test suite should be easy, just keep .repo files around and test
krh@47
    93
  different type of upgrades that way (obsoletes, conflicts, file
krh@47
    94
  conflicts, file/dir problems etc).  Or maybe just keep a simple file
krh@47
    95
  format ad use a custom importer to create the .repo files.
krh@47
    96
krh@56
    97
- try to clean up the
krh@56
    98
krh@56
    99
	do { ... } while (((e++)->name & RAZOR_ENTRY_LAST) == 0);
krh@56
   100
krh@56
   101
  idiom for iteration of directories.
krh@63
   102
krh@63
   103
- overlay package sets?  mount a read-only /usr over nfs or from the
krh@63
   104
  virt-host and have a local package set overlaid over the read-only
krh@63
   105
  one.  shouldn't need new features in the core package set data
krh@63
   106
  structure, but should be just conventions on top.  we have the base
krh@63
   107
  package set from the r/o system, the overlay set from the local
krh@63
   108
  system and we can have an effective package set which is the merge
krh@63
   109
  of everything from the overlay into the base set.  the effective set
krh@63
   110
  is easy to compute and we could do it on the fly or cache it.  or
krh@63
   111
  maybe the effective set is the on-disk representation and the
krh@63
   112
  overlay can be computed when needed, we just keep a link back to the
krh@63
   113
  base.
krh@71
   114
krh@71
   115
- incremental rawhide repo updates? instead of downloading 10MB zipped
krh@82
   116
  repo every time, download a diff repo?  Should be pretty small,
krh@82
   117
  especially if we don't have file checksums in metadata.  Filenames
krh@82
   118
  and properties are for the most part already present, typically just
krh@82
   119
  a version bump plus maybe tweaking a couple requires.  The upstream
krh@82
   120
  repo can store multiple incremental updates in one big file and
krh@82
   121
  provide an index file that maps updates for a given date (we should
krh@82
   122
  use repo-file checksums though) to a range in the file: Download the
krh@82
   123
  index file, search for a match for your latest rawhide.repo file,
krh@82
   124
  download range of updates that brings it up to date.
krh@74
   125
krh@74
   126
- use hash tables for dirs when importing files to avoid qsorting all
krh@74
   127
  files in rawhide.
krh@75
   128
krh@82
   129
Bugs:
krh@82
   130
krh@82
   131
- eliminate duplicate entries in package property lists.