public abstract class BaseReceivePack
extends java.lang.Object
Contains high-level operations for initializing and closing streams, advertising refs, reading commands, and receiving and applying a pack. Subclasses compose these operations into full service implementations.
Modifier and Type | Class and Description |
---|---|
static class |
BaseReceivePack.FirstLine
Deprecated.
Use
FirstCommand instead. |
(package private) class |
BaseReceivePack.MessageOutputWrapper
Output stream that wraps the current
msgOut . |
protected static class |
BaseReceivePack.ReceiveConfig
Configuration for receive operations.
|
(package private) static class |
BaseReceivePack.Reporter
Interface for reporting status messages.
|
Modifier and Type | Field and Description |
---|---|
(package private) java.util.Set<ObjectId> |
advertisedHaves
All SHA-1s shown to the client, which can be possible edges.
|
private java.lang.StringBuilder |
advertiseError |
private AdvertiseRefsHook |
advertiseRefsHook
Hook used while advertising the refs to the client.
|
private boolean |
allowAnyDeletes
Should an incoming transfer permit delete requests?
|
private boolean |
allowBranchDeletes |
private boolean |
allowCreates
Should an incoming transfer permit create requests?
|
private boolean |
allowNonFastForwards
Should an incoming transfer permit non-fast-forward requests?
|
private boolean |
allowOfsDelta |
private boolean |
allowPushOptions
Should an incoming transfer permit push options?
|
private boolean |
allowQuiet |
private boolean |
atomic
Should the requested ref updates be performed as a single atomic
transaction?
|
private boolean |
biDirectionalPipe
Is the client connection a bi-directional socket or pipe?
|
private boolean |
checkReferencedIsReachable |
private java.util.Set<ObjectId> |
clientShallowCommits |
private java.util.List<ReceiveCommand> |
commands |
(package private) Repository |
db
Database we write the stored objects into.
|
private java.util.Set<java.lang.String> |
enabledCapabilities
Capabilities requested by the client.
|
private SideBandOutputStream |
errOut |
private boolean |
expectDataAfterPackFooter
Expecting data after the pack footer
|
private long |
maxCommandBytes |
private long |
maxDiscardBytes |
private long |
maxObjectSizeLimit
Git object size limit
|
private long |
maxPackSizeLimit
Total pack size limit
|
protected java.io.OutputStream |
msgOut
Optional message output stream.
|
private BaseReceivePack.MessageOutputWrapper |
msgOutWrapper |
private ObjectChecker |
objectChecker
Should an incoming transfer validate objects?
|
private java.io.OutputStream |
origOut |
private PackLock |
packLock
Lock around the received pack file, while updating refs.
|
private java.lang.Long |
packSize
The size of the received pack, including index size
|
private PackParser |
parser |
protected PacketLineIn |
pckIn
Packet line input stream around
rawIn . |
protected PacketLineOut |
pckOut
Packet line output stream around
rawOut . |
(package private) PushCertificate |
pushCert |
private PushCertificateParser |
pushCertificateParser |
private boolean |
quiet |
protected java.io.InputStream |
rawIn
Raw input stream.
|
protected java.io.OutputStream |
rawOut
Raw output stream.
|
(package private) RefFilter |
refFilter
Filter used while advertising the refs to the client.
|
private PersonIdent |
refLogIdent
Identity to record action as within the reflog.
|
(package private) java.util.Map<java.lang.String,Ref> |
refs
The refs we advertised as existing at the start of the connection.
|
private boolean |
sideBand
If
BasePackPushConnection.CAPABILITY_SIDE_BAND_64K is enabled. |
private SignedPushConfig |
signedPushConfig |
private ReceivedPackStatistics |
stats |
private int |
timeout
Timeout in seconds to wait for client interaction.
|
private TimeoutInputStream |
timeoutIn |
private InterruptTimer |
timer
Timer to manage
timeout . |
(package private) java.lang.String |
userAgent |
(package private) RevWalk |
walk
Revision traversal support over
db . |
Modifier | Constructor and Description |
---|---|
protected |
BaseReceivePack(Repository into)
Create a new pack receive for an open repository.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
anyRejects()
Whether any commands have been rejected so far.
|
private void |
checkConnectivity() |
(package private) void |
checkRequestWasRead() |
private void |
checkSubmodules() |
protected void |
close()
Close and flush (if necessary) the underlying streams.
|
private void |
discardCommands() |
protected void |
enableCapabilities()
Enable capabilities based on a previously read capabilities line.
|
protected void |
executeCommands()
Execute commands to update references.
|
protected void |
failPendingCommands()
Set the result to fail for any command that was not processed yet.
|
private void |
fatalError(java.lang.String msg) |
protected java.util.List<ReceiveCommand> |
filterCommands(ReceiveCommand.Result want)
Filter the list of commands according to result.
|
java.util.Set<ObjectId> |
getAdvertisedObjects()
Get objects advertised to the client.
|
protected java.util.Map<java.lang.String,Ref> |
getAdvertisedOrDefaultRefs()
Get advertised refs, or the default if not explicitly advertised.
|
abstract java.util.Map<java.lang.String,Ref> |
getAdvertisedRefs()
Deprecated.
|
AdvertiseRefsHook |
getAdvertiseRefsHook()
Get the hook used while advertising the refs to the client
|
java.util.List<ReceiveCommand> |
getAllCommands()
Get all of the command received by the current request.
|
protected java.util.Set<ObjectId> |
getClientShallowCommits()
Get the commits from the client's shallow file.
|
protected abstract java.lang.String |
getLockMessageProcessName()
Get the process name used for pack lock messages.
|
java.io.OutputStream |
getMessageOutputStream()
Get an underlying stream for sending messages to the client.
|
long |
getPackSize()
Get the size of the received pack file including the index size.
|
java.lang.String |
getPeerUserAgent()
Get the user agent of the client.
|
abstract PushCertificate |
getPushCertificate()
Deprecated.
|
private PushCertificateParser |
getPushCertificateParser() |
ReceivedPackStatistics |
getReceivedPackStatistics()
Returns the statistics on the received pack if available.
|
RefFilter |
getRefFilter()
Get the filter used while advertising the refs to the client
|
PersonIdent |
getRefLogIdent()
Get identity of the user making the changes in the reflog.
|
abstract Repository |
getRepository()
Deprecated.
|
abstract RevWalk |
getRevWalk()
Deprecated.
|
int |
getTimeout()
Get timeout (in seconds) before aborting an IO operation.
|
protected boolean |
hasCommands()
Whether any commands to be executed have been read.
|
protected boolean |
hasError()
Whether an error occurred that should be advertised.
|
protected void |
init(java.io.InputStream input,
java.io.OutputStream output,
java.io.OutputStream messages)
Initialize the instance with the given streams.
|
boolean |
isAllowBranchDeletes()
Whether the client can delete from
refs/heads/ . |
boolean |
isAllowCreates()
Whether the client can request refs to be created.
|
boolean |
isAllowDeletes()
Whether the client can request refs to be deleted.
|
boolean |
isAllowNonFastForwards()
Whether the client can request non-fast-forward updates of a ref,
possibly making objects unreachable.
|
boolean |
isAllowPushOptions()
Whether the server supports receiving push options.
|
boolean |
isAllowQuiet()
Whether clients may request avoiding noisy progress messages.
|
boolean |
isAtomic()
Whether the client's commands should be performed as a single atomic
transaction.
|
boolean |
isBiDirectionalPipe()
Whether this class expects a bi-directional pipe opened between the
client and itself.
|
protected boolean |
isCapabilityEnabled(java.lang.String name)
Check if the peer requested a capability.
|
boolean |
isCheckReceivedObjects()
Whether this instance will verify received objects are formatted
correctly.
|
boolean |
isCheckReferencedObjectsAreReachable()
Whether this instance will validate all referenced, but not supplied by
the client, objects are reachable from another reference.
|
boolean |
isExpectDataAfterPackFooter()
Whether there is data expected after the pack footer.
|
boolean |
isQuiet()
True if the client wants less verbose output.
|
boolean |
isSideBand()
Check whether the client expects a side-band stream.
|
private boolean |
needCheckConnectivity() |
protected boolean |
needPack()
Whether a pack is expected based on the list of commands.
|
private java.io.InputStream |
packInputStream() |
(package private) static ReceiveCommand |
parseCommand(java.lang.String line) |
private void |
parseShallow(java.lang.String idStr) |
(package private) void |
readPostCommands(PacketLineIn in) |
private void |
receivePack()
Receive a pack from the input and store it in the repository.
|
protected void |
receivePackAndCheckConnectivity()
Receive a pack from the stream and check connectivity if necessary.
|
protected void |
recvCommands()
Receive a list of commands from the input.
|
protected void |
release()
Release any resources used by this object.
|
void |
sendAdvertisedRefs(RefAdvertiser adv)
Generate an advertisement of available refs and capabilities.
|
void |
sendError(java.lang.String what)
Send an error message to the client.
|
void |
sendMessage(java.lang.String what)
Send a message to the client, if it supports receiving them.
|
protected void |
sendStatusReport(boolean forClient,
java.lang.Throwable unpackError,
BaseReceivePack.Reporter out)
Send a status report.
|
abstract void |
setAdvertisedRefs(java.util.Map<java.lang.String,Ref> allRefs,
java.util.Set<ObjectId> additionalHaves)
|
void |
setAdvertiseRefsHook(AdvertiseRefsHook advertiseRefsHook)
Set the hook used while advertising the refs to the client.
|
void |
setAllowBranchDeletes(boolean canDelete)
Configure whether to permit deletion of branches from the
refs/heads/ namespace. |
void |
setAllowCreates(boolean canCreate)
Whether to permit create ref commands to be processed.
|
void |
setAllowDeletes(boolean canDelete)
Whether to permit delete ref commands to be processed.
|
void |
setAllowNonFastForwards(boolean canRewind)
Configure whether to permit the client to ask for non-fast-forward
updates of an existing ref.
|
void |
setAllowPushOptions(boolean allow)
Configure if the server supports receiving push options.
|
void |
setAllowQuiet(boolean allow)
Configure if clients may request the server skip noisy messages.
|
void |
setAtomic(boolean atomic)
Configure whether to perform the client's commands as a single atomic
transaction.
|
void |
setBiDirectionalPipe(boolean twoWay)
Whether this class will assume the socket is a fully bidirectional pipe
between the two peers and takes advantage of that by first transmitting
the known refs, then waiting to read commands.
|
void |
setCheckReceivedObjects(boolean check)
Whether to enable checking received objects
|
void |
setCheckReferencedObjectsAreReachable(boolean b)
Validate all referenced but not supplied objects are reachable.
|
void |
setExpectDataAfterPackFooter(boolean e)
Whether there is additional data in InputStream after pack.
|
void |
setMaxCommandBytes(long limit)
Set the maximum number of command bytes to read from the client.
|
void |
setMaxCommandDiscardBytes(long limit)
Set the maximum number of command bytes to discard from the client.
|
void |
setMaxObjectSizeLimit(long limit)
Set the maximum allowed Git object size.
|
void |
setMaxPackSizeLimit(long limit)
Set the maximum allowed pack size.
|
void |
setObjectChecker(ObjectChecker impl)
Set the object checking instance to verify each received object with
|
abstract void |
setPushCertificate(PushCertificate cert)
Deprecated.
|
void |
setRefFilter(RefFilter refFilter)
Set the filter used while advertising the refs to the client.
|
void |
setRefLogIdent(PersonIdent pi)
Set the identity of the user appearing in the affected reflogs.
|
void |
setSignedPushConfig(SignedPushConfig cfg)
Set the configuration for push certificate verification.
|
void |
setTimeout(int seconds)
Set the timeout before willing to abort an IO call.
|
protected void |
unlockPack()
Unlock the pack written by this object.
|
protected void |
validateCommands()
Validate the command list.
|
final Repository db
private boolean biDirectionalPipe
If true, this class assumes it can perform multiple read and write cycles with the client over the input and output streams. This matches the functionality available with a standard TCP/IP connection, or a local operating system or in-memory pipe.
If false, this class runs in a read everything then output results mode, making it suitable for single round-trip systems RPCs such as HTTP.
private boolean expectDataAfterPackFooter
private ObjectChecker objectChecker
private boolean allowCreates
private boolean allowAnyDeletes
private boolean allowBranchDeletes
private boolean allowNonFastForwards
private boolean allowPushOptions
private boolean atomic
private boolean allowOfsDelta
private boolean allowQuiet
private PersonIdent refLogIdent
private AdvertiseRefsHook advertiseRefsHook
RefFilter refFilter
private int timeout
private InterruptTimer timer
timeout
.private TimeoutInputStream timeoutIn
private java.io.OutputStream origOut
protected java.io.InputStream rawIn
protected java.io.OutputStream rawOut
protected java.io.OutputStream msgOut
private SideBandOutputStream errOut
protected PacketLineIn pckIn
rawIn
.protected PacketLineOut pckOut
rawOut
.private final BaseReceivePack.MessageOutputWrapper msgOutWrapper
private PackParser parser
java.util.Map<java.lang.String,Ref> refs
java.util.Set<ObjectId> advertisedHaves
private java.util.Set<java.lang.String> enabledCapabilities
java.lang.String userAgent
private java.util.Set<ObjectId> clientShallowCommits
private java.util.List<ReceiveCommand> commands
private long maxCommandBytes
private long maxDiscardBytes
private java.lang.StringBuilder advertiseError
private boolean sideBand
BasePackPushConnection.CAPABILITY_SIDE_BAND_64K
is enabled.private boolean quiet
private PackLock packLock
private boolean checkReferencedIsReachable
private long maxObjectSizeLimit
private long maxPackSizeLimit
private java.lang.Long packSize
private PushCertificateParser pushCertificateParser
private SignedPushConfig signedPushConfig
PushCertificate pushCert
private ReceivedPackStatistics stats
protected BaseReceivePack(Repository into)
into
- the destination repository.@Deprecated public abstract PushCertificate getPushCertificate()
ReceivePack.getPushCertificate()
.Only valid after commands are read from the wire.
@Deprecated public abstract void setPushCertificate(PushCertificate cert)
ReceivePack.setPushCertificate(PushCertificate)
.
Should only be called if reconstructing an instance without going through
the normal recvCommands()
flow.
cert
- the push certificate to set.protected abstract java.lang.String getLockMessageProcessName()
@Deprecated public abstract Repository getRepository()
ReceivePack.getRepository()
@Deprecated public abstract RevWalk getRevWalk()
ReceivePack.getRevWalk()
@Deprecated public abstract java.util.Map<java.lang.String,Ref> getAdvertisedRefs()
ReceivePack.getAdvertisedRefs()
setAdvertisedRefs(Map, Set)
has not been called yet.@Deprecated public abstract void setAdvertisedRefs(java.util.Map<java.lang.String,Ref> allRefs, java.util.Set<ObjectId> additionalHaves)
ReceivePack.setAdvertisedRefs(java.util.Map<java.lang.String, org.eclipse.jgit.lib.Ref>, java.util.Set<org.eclipse.jgit.lib.ObjectId>)
Intended to be called from a
PreReceiveHook
.
allRefs
- explicit set of references to claim as advertised by this
ReceivePack instance. This overrides any references that may
exist in the source repository. The map is passed to the
configured getRefFilter()
. If null, assumes all refs
were advertised.additionalHaves
- explicit set of additional haves to claim as advertised. If
null, assumes the default set of additional haves from the
repository.public final java.util.Set<ObjectId> getAdvertisedObjects()
setAdvertisedRefs(Map, Set)
has not been called
yet.public boolean isCheckReferencedObjectsAreReachable()
public void setCheckReferencedObjectsAreReachable(boolean b)
If enabled, this instance will verify that references to objects not
contained within the received pack are already reachable through at least
one other reference displayed as part of getAdvertisedRefs()
.
This feature is useful when the application doesn't trust the client to
not provide a forged SHA-1 reference to an object, in an attempt to
access parts of the DAG that they aren't allowed to see and which have
been hidden from them via the configured
AdvertiseRefsHook
or
RefFilter
.
Enabling this feature may imply at least some, if not all, of the same
functionality performed by setCheckReceivedObjects(boolean)
.
Applications are encouraged to enable both features, if desired.
b
- true
to enable the additional check.public boolean isBiDirectionalPipe()
public void setBiDirectionalPipe(boolean twoWay)
twoWay
- if true, this class will assume the socket is a fully
bidirectional pipe between the two peers and takes advantage
of that by first transmitting the known refs, then waiting to
read commands. If false, this class assumes it must read the
commands before writing output and does not perform the
initial advertising.public boolean isExpectDataAfterPackFooter()
true
if there is data expected after the pack footer.public void setExpectDataAfterPackFooter(boolean e)
e
- true
if there is additional data in InputStream after
pack.public boolean isCheckReceivedObjects()
true
if this instance will verify received objects are
formatted correctly. Validating objects requires more CPU time on
this side of the connection.public void setCheckReceivedObjects(boolean check)
check
- true
to enable checking received objects; false to
assume all received objects are valid.setObjectChecker(ObjectChecker)
public void setObjectChecker(ObjectChecker impl)
impl
- if non-null the object checking instance to verify each
received object with; null to disable object checking.public boolean isAllowCreates()
true
if the client can request refs to be created.public void setAllowCreates(boolean canCreate)
canCreate
- true
to permit create ref commands to be processed.public boolean isAllowDeletes()
true
if the client can request refs to be deleted.public void setAllowDeletes(boolean canDelete)
canDelete
- true
to permit delete ref commands to be processed.public boolean isAllowBranchDeletes()
refs/heads/
.true
if the client can delete from refs/heads/
.public void setAllowBranchDeletes(boolean canDelete)
refs/heads/
namespace.canDelete
- true
to permit deletion of branches from the
refs/heads/
namespace.public boolean isAllowNonFastForwards()
true
if the client can request non-fast-forward updates
of a ref, possibly making objects unreachable.public void setAllowNonFastForwards(boolean canRewind)
canRewind
- true
to permit the client to ask for non-fast-forward
updates of an existing ref.public boolean isAtomic()
true
if the client's commands should be performed as a
single atomic transaction.public void setAtomic(boolean atomic)
atomic
- true
to perform the client's commands as a single
atomic transaction.public PersonIdent getRefLogIdent()
public void setRefLogIdent(PersonIdent pi)
The timestamp portion of the identity is ignored. A new identity with the current timestamp will be created automatically when the updates occur and the log records are written.
pi
- identity of the user. If null the identity will be
automatically determined based on the repository
configuration.public AdvertiseRefsHook getAdvertiseRefsHook()
public RefFilter getRefFilter()
public void setAdvertiseRefsHook(AdvertiseRefsHook advertiseRefsHook)
If the AdvertiseRefsHook
chooses to
call setAdvertisedRefs(Map,Set)
, only refs set by this hook
and selected by the RefFilter
will be shown to the client. Clients may still attempt to create or
update a reference not advertised by the configured
AdvertiseRefsHook
. These attempts
should be rejected by a matching
PreReceiveHook
.
advertiseRefsHook
- the hook; may be null to show all refs.public void setRefFilter(RefFilter refFilter)
Only refs allowed by this filter will be shown to the client. The filter
is run against the refs specified by the
AdvertiseRefsHook
(if applicable).
refFilter
- the filter; may be null to show all refs.public int getTimeout()
public void setTimeout(int seconds)
seconds
- number of seconds to wait (with no data transfer occurring)
before aborting an IO read or write operation with the
connected client.public void setMaxCommandBytes(long limit)
limit
- command limit in bytes; if 0 there is no limit.public void setMaxCommandDiscardBytes(long limit)
Discarding remaining bytes allows this instance to consume the rest of the command block and send a human readable over-limit error via the side-band channel. If the client sends an excessive number of bytes this limit kicks in and the instance disconnects, resulting in a non-specific 'pipe closed', 'end of stream', or similar generic error at the client.
When the limit is set to -1
the implementation will default to
the larger of 3 * maxCommandBytes
or 3 MiB
.
limit
- discard limit in bytes; if 0 there is no limit; if -1 the
implementation tries to set a reasonable default.public void setMaxObjectSizeLimit(long limit)
If an object is larger than the given size the pack-parsing will throw an exception aborting the receive-pack operation.
limit
- the Git object size limit. If zero then there is not limit.public void setMaxPackSizeLimit(long limit)
A pack exceeding this size will be rejected.
limit
- the pack size limit, in bytespublic boolean isSideBand() throws RequestNotYetReadException
RequestNotYetReadException
- if the client's request has not yet been read from the wire, so
we do not know if they expect side-band. Note that the client
may have already written the request, it just has not been
read.public boolean isAllowQuiet()
public void setAllowQuiet(boolean allow)
allow
- true to allow clients to request quiet behavior; false to
refuse quiet behavior and send messages anyway. This may be
necessary if processing is slow and the client-server network
connection can timeout.public boolean isAllowPushOptions()
public void setAllowPushOptions(boolean allow)
allow
- true to optionally accept option strings from the client.public boolean isQuiet() throws RequestNotYetReadException
RequestNotYetReadException
- if the client's request has not yet been read from the wire,
so we do not know if they expect side-band. Note that the
client may have already written the request, it just has not
been read.public void setSignedPushConfig(SignedPushConfig cfg)
cfg
- new configuration; if this object is null or its SignedPushConfig.getCertNonceSeed()
is null, push certificate
verification will be disabled.private PushCertificateParser getPushCertificateParser()
public java.lang.String getPeerUserAgent()
If the client is new enough to use agent=
capability that value
will be returned. Older HTTP clients may also supply their version using
the HTTP User-Agent
header. The capability overrides the HTTP
header if both are available.
When an HTTP request has been received this method returns the HTTP
User-Agent
header value until capabilities have been parsed.
public java.util.List<ReceiveCommand> getAllCommands()
public void sendError(java.lang.String what)
If any error messages are sent before the references are advertised to the client, the errors will be sent instead of the advertisement and the receive operation will be aborted. All clients should receive and display such early stage errors.
If the reference advertisements have already been sent, messages are sent in a side channel. If the client doesn't support receiving messages, the message will be discarded, with no other indication to the caller or to the client.
PreReceiveHook
s should always try to
use
ReceiveCommand.setResult(Result, String)
with a result status of
ReceiveCommand.Result.REJECTED_OTHER_REASON
to indicate any reasons for rejecting an update. Messages attached to a
command are much more likely to be returned to the client.
what
- string describing the problem identified by the hook. The
string must not end with an LF, and must not contain an LF.private void fatalError(java.lang.String msg)
public void sendMessage(java.lang.String what)
If the client doesn't support receiving messages, the message will be discarded, with no other indication to the caller or to the client.
what
- string describing the problem identified by the hook. The
string must not end with an LF, and must not contain an LF.public java.io.OutputStream getMessageOutputStream()
public long getPackSize()
java.lang.IllegalStateException
- if called before the pack has been receivedprotected java.util.Set<ObjectId> getClientShallowCommits()
protected boolean hasCommands()
true
if any commands to be executed have been read.protected boolean hasError()
protected void init(java.io.InputStream input, java.io.OutputStream output, java.io.OutputStream messages)
input
- raw input to read client commands and pack data from. Caller
must ensure the input is buffered, otherwise read performance
may suffer.output
- response back to the Git network client. Caller must ensure
the output is buffered, otherwise write performance may
suffer.messages
- secondary "notice" channel to send additional messages out
through. When run over SSH this should be tied back to the
standard error channel of the command execution. For most
other network connections this should be null.protected java.util.Map<java.lang.String,Ref> getAdvertisedOrDefaultRefs()
protected void receivePackAndCheckConnectivity() throws java.io.IOException
java.io.IOException
- an error occurred during unpacking or connectivity checking.protected void unlockPack() throws java.io.IOException
java.io.IOException
- the pack could not be unlocked.public void sendAdvertisedRefs(RefAdvertiser adv) throws java.io.IOException, ServiceMayNotContinueException
adv
- the advertisement formatter.java.io.IOException
- the formatter failed to write an advertisement.ServiceMayNotContinueException
- the hook denied advertisement.@Nullable public ReceivedPackStatistics getReceivedPackStatistics()
receivePack()
is called.protected void recvCommands() throws java.io.IOException
java.io.IOException
private void discardCommands()
private void parseShallow(java.lang.String idStr) throws PackProtocolException
PackProtocolException
static ReceiveCommand parseCommand(java.lang.String line) throws PackProtocolException
PackProtocolException
void readPostCommands(PacketLineIn in) throws java.io.IOException
in
- request stream.java.io.IOException
- request line cannot be read.protected void enableCapabilities()
protected boolean isCapabilityEnabled(java.lang.String name)
name
- protocol name identifying the capability.void checkRequestWasRead()
protected boolean needPack()
true
if a pack is expected based on the list of commands.private void receivePack() throws java.io.IOException
java.io.IOException
- an error occurred reading or indexing the pack.private java.io.InputStream packInputStream()
private boolean needCheckConnectivity()
private void checkSubmodules() throws java.io.IOException
java.io.IOException
private void checkConnectivity() throws java.io.IOException
java.io.IOException
protected void validateCommands()
protected boolean anyRejects()
protected void failPendingCommands()
protected java.util.List<ReceiveCommand> filterCommands(ReceiveCommand.Result want)
want
- desired status to filter by.protected void executeCommands()
protected void sendStatusReport(boolean forClient, java.lang.Throwable unpackError, BaseReceivePack.Reporter out) throws java.io.IOException
forClient
- true if this report is for a Git client, false if it is for an
end-user.unpackError
- an error that occurred during unpacking, or null
out
- the reporter for sending the status strings.java.io.IOException
- an error occurred writing the status report.protected void close() throws java.io.IOException
java.io.IOException
protected void release() throws java.io.IOException
java.io.IOException
- the pack could not be unlocked.