git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Shawn O. Pearce" <spearce@spearce.org>
To: Robin Rosenberg <robin.rosenberg@dewire.com>
Cc: git@vger.kernel.org
Cc: Constantine Plotnikov <constantine.plotnikov@gmail.com>
Subject: [JGIT PATCH 00/19] More Config class cleanup work
Date: Sat, 25 Jul 2009 11:52:43 -0700	[thread overview]
Message-ID: <1248547982-4003-1-git-send-email-spearce@spearce.org> (raw)

Yet another series to cleanup the Config class and its
implementations to be slightly more useful.

The later part of the series makes Config thread safe and introduces
caching of application-specific model instances as part of the
Config, making it more efficient for code to query for multiple
values at once.

This new caching feature is especially useful for ReceivePack on
the server side, where the values aren't expected to change between
connections, but connections come in at a steady enough rate that
reparsing the configuration each time is just a waste of time.

Later I plan to extend the caching by using it RemoteConfig and
also for a new SubmoduleConfig.


The entire series applies on top of my 1 patch from yesterday that
fixes the Turkish locale problems in Config.


Shawn O. Pearce (19):
  Cleanup nonstandard references to encoding strings to bytes
  Delete incorrect Javadoc from Config's getRawString method
  Make Config.escapeValue a private method
  Allow a RemoteConfig to use the more generic Config class
  Use type specific sets when creating a new RepositoryConfig
  Move SystemReader out of RepositoryConfig
  Correct user config to be of type FileBasedConfig
  Extract the test specific SystemReader out of RepositoryTestCase
  Refactor Config hierarchy to make IO more explicit
  Test for the config file when creating a new repository
  Remove the map lookup for values in Config
  Return base values first from Config.getStringList()
  Make Config thread safe by using copy-on-write semantics
  Support cached application models in a Config
  Cache Config subsection names when requested by application code
  Refactor author/committer lookup to use cached data
  Move repository config creation fully into Repository class
  Use Config SectionParser cache to store daemon enable states
  Use Config cache for fetch and receive configuration parsing

 .../org/spearce/jgit/lib/ConcurrentRepackTest.java |    2 +-
 .../tst/org/spearce/jgit/lib/MockSystemReader.java |   78 ++
 .../org/spearce/jgit/lib/RepositoryConfigTest.java |  193 +++---
 .../org/spearce/jgit/lib/RepositoryTestCase.java   |   51 +--
 .../tst/org/spearce/jgit/lib/T0003_Basic.java      |   16 +-
 .../org/spearce/jgit/revwalk/RevWalkTestCase.java  |    3 +-
 .../spearce/jgit/transport/RemoteConfigTest.java   |  166 ++---
 .../jgit/errors/ConfigInvalidException.java        |   53 ++
 .../src/org/spearce/jgit/lib/BlobBasedConfig.java  |  110 ++--
 .../src/org/spearce/jgit/lib/Config.java           |  743 +++++++++++---------
 .../src/org/spearce/jgit/lib/CoreConfig.java       |   16 +-
 .../src/org/spearce/jgit/lib/FileBasedConfig.java  |   83 ++-
 .../src/org/spearce/jgit/lib/ObjectWriter.java     |    2 +-
 .../src/org/spearce/jgit/lib/Repository.java       |   38 +-
 .../src/org/spearce/jgit/lib/RepositoryConfig.java |  144 +----
 .../src/org/spearce/jgit/lib/TransferConfig.java   |   11 +-
 .../src/org/spearce/jgit/lib/UserConfig.java       |  149 ++++
 .../jgit/revwalk/filter/PatternMatchRevFilter.java |   10 +-
 .../jgit/transport/BasePackFetchConnection.java    |   21 +-
 .../org/spearce/jgit/transport/DaemonService.java  |   30 +-
 .../org/spearce/jgit/transport/ReceivePack.java    |   45 +-
 .../org/spearce/jgit/transport/RemoteConfig.java   |   15 +-
 .../org/spearce/jgit/util/RawSubStringPattern.java |   10 +-
 .../src/org/spearce/jgit/util/SystemReader.java    |   65 ++-
 24 files changed, 1172 insertions(+), 882 deletions(-)
 create mode 100644 org.spearce.jgit.test/tst/org/spearce/jgit/lib/MockSystemReader.java
 create mode 100644 org.spearce.jgit/src/org/spearce/jgit/errors/ConfigInvalidException.java
 create mode 100644 org.spearce.jgit/src/org/spearce/jgit/lib/UserConfig.java

             reply	other threads:[~2009-07-25 18:53 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-25 18:52 Shawn O. Pearce [this message]
2009-07-25 18:52 ` [JGIT PATCH 01/19] Cleanup nonstandard references to encoding strings to bytes Shawn O. Pearce
2009-07-25 18:52   ` [JGIT PATCH 02/19] Delete incorrect Javadoc from Config's getRawString method Shawn O. Pearce
2009-07-25 18:52     ` [JGIT PATCH 03/19] Make Config.escapeValue a private method Shawn O. Pearce
2009-07-25 18:52       ` [JGIT PATCH 04/19] Allow a RemoteConfig to use the more generic Config class Shawn O. Pearce
2009-07-25 18:52         ` [JGIT PATCH 05/19] Use type specific sets when creating a new RepositoryConfig Shawn O. Pearce
2009-07-25 18:52           ` [JGIT PATCH 06/19] Move SystemReader out of RepositoryConfig Shawn O. Pearce
2009-07-25 18:52             ` [JGIT PATCH 07/19] Correct user config to be of type FileBasedConfig Shawn O. Pearce
2009-07-25 18:52               ` [JGIT PATCH 08/19] Extract the test specific SystemReader out of RepositoryTestCase Shawn O. Pearce
2009-07-25 18:52                 ` [JGIT PATCH 09/19] Refactor Config hierarchy to make IO more explicit Shawn O. Pearce
2009-07-25 18:52                   ` [JGIT PATCH 10/19] Test for the config file when creating a new repository Shawn O. Pearce
2009-07-25 18:52                     ` [JGIT PATCH 11/19] Remove the map lookup for values in Config Shawn O. Pearce
2009-07-25 18:52                       ` [JGIT PATCH 12/19] Return base values first from Config.getStringList() Shawn O. Pearce
2009-07-25 18:52                         ` [JGIT PATCH 13/19] Make Config thread safe by using copy-on-write semantics Shawn O. Pearce
2009-07-25 18:52                           ` [JGIT PATCH 14/19] Support cached application models in a Config Shawn O. Pearce
2009-07-25 18:52                             ` [JGIT PATCH 15/19] Cache Config subsection names when requested by application code Shawn O. Pearce
2009-07-25 18:52                               ` [JGIT PATCH 16/19] Refactor author/committer lookup to use cached data Shawn O. Pearce
2009-07-25 18:53                                 ` [JGIT PATCH 17/19] Move repository config creation fully into Repository class Shawn O. Pearce
2009-07-25 18:53                                   ` [JGIT PATCH 18/19] Use Config SectionParser cache to store daemon enable states Shawn O. Pearce
2009-07-25 18:53                                     ` [JGIT PATCH 19/19] Use Config cache for fetch and receive configuration parsing Shawn O. Pearce
2009-07-25 22:54                   ` [JGIT PATCH 09/19] Refactor Config hierarchy to make IO more explicit Robin Rosenberg
2009-07-25 22:55                     ` Shawn O. Pearce
2009-07-25 23:34                       ` Robin Rosenberg
2009-07-25 23:38                         ` Shawn O. Pearce
2009-07-25 20:32     ` [JGIT PATCH 02/19] Delete incorrect Javadoc from Config's getRawString method Robin Rosenberg
2009-07-25 20:33       ` Shawn O. Pearce

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1248547982-4003-1-git-send-email-spearce@spearce.org \
    --to=spearce@spearce.org \
    --cc=git@vger.kernel.org \
    --cc=robin.rosenberg@dewire.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).