Adds doc-string to EggNameMixin, renames the custom install flag to make
it a bit clearer that the mechanism isn't necessarily limited to linux
(though certainly we'd like it to be; but that's a decision to be made
at the level of the build system and what is made available on GCS, not
here).
Writing "<format string containing one directive> % <expression>"
instead of "<format string containing one directive> % (<expression>,)"
is always a problem; the particular problem in this case came from
face.Abortion being a subclass of a class created with
collections.namedtuple.
functools.wrap is only warranted to work with functions and methods but
logging_pool is warranted to work with callable behaviors, so using
functools.wrap has been wrong all along.
The particular incompatibility motivating this correction is that
callable objects do not have a "__name__" attribute.
In 4a9b1c6988 I mistakenly added statements to test
test_constants.PARALLELISM RPCs made in parallel to the
testSequentialInvocations test method rather than the
testParallelInvocations test method. How embarrassing!
On the service-side, an operation isn't successfully completed with
just the conclusion of transmission to the other side; local ingestion
of the status and code must be completed as well before termination
callbacks are called.
We've been assuming that the server upon invoking start was started.
This has been false; invoking start means that the server will
eventually be started, and to make this reliably observable requires
passing control to core.
This reorganizes the Python code, scraps the current testing
infrastructure, and implements a simple test discovery and run script
based on the standard Python unittest library so we can trust that our
tests are running.
For a termination action to properly mark an _End as having stopped it
must clear the _End's _cycle attribute. To be able to do that the
termination action must hold a reference to the _End instance.
Migrating the _termination_action behavior that creates termination
actions into the scope of the _End instance is the best way to afford
the needed instance reference.
This defect was introduced in 9e4d0610ea. I had thought that
this code was exercised in tests but it is bypassed by the use of
grpc_test.beta.test_utilities.not_really_secure_channel. :-(
(1) Move dependency on protobuf from grpcio to grpcio_test. While the
most-commonly-foreseen use case of grpcio makes use of protobuf,
technically protobuf is not strictly needed and there's no actual
in-code relationship between grpcio and protobuf.
(2) Loosen the dependency on protobuf from ==3.0.0a3 to >=3.0.0a3.
(3) Update all references to 0.10.0* to 0.11.0.
(4) Alphabetize the grpcio_test dependencies.
Servers and stubs were context managers in the Alpha API; they may not
need to be in the Beta API but it's easy enough to do, eases migration,
and probably helps some use cases.
For now the stub is given empty __enter__ and __exit__ methods; we can
always come back and implement the actual work of context management in
a later change.
(1) Renamed the "beta" module "implementations" because it hasn't been
monolithic since "interfaces" was factored out of it a few changes
back.
(2) Moved ChannelConnectivity from grpc.beta.beta to
grpc.beta.interfaces since it is constants that don't depend on the
beta implementation.
(3) Moved the Server interface definition from grpc.beta.beta to
grpc.beta.interfaces since it is an interface.
(4) Dropped the "create_" prefix from "create_<...>_channel" functions
to better match the other creation functions throughout the codebase.
It may seem weird that code and details would travel along two paths
now instead of one but it makes sense after considering that sometimes
the code and details are application data from the remote application
and sometimes they are transport data from the transport between the
local and remote applications.
(1) In _ingestion, it's the "details" attribute of a
NoSuchMethodException that we want. The "message" is inherited from the
base Exception class.
(2) In _transmission, use a proper sum type for representing operation
abortion. Trying to overload the existing _completion value for
status-and-details-when-aborting was trying to be too clever.
(3) In _calls... oof. Just look. Oof. Test coverage for this code path
is added.
(4) In _service, the application-provided
face.MultiMethodImplementation isn't directly callable, but rather
exposes a method named "service".
(5) In crust.implementations, the wrapping that we've put around the
application-provided face.MultiMethodImplementation *is* directly
callable, and *does not* expose a method named "service".
(6) Also in crust.implementations, base.NoSuchMethodError's constructor
takes a code value and a details value.
(7) Again in crust.implementations, the application-provided
face.MultiMethodImplementation may be None, and if it is None, we
shouldn't wrap it with an adaptation function that would only raise a
TypeError at a later time.
(1) Plumb the metadata transformer given at the Beta API through to the
InvocationLink where it will be used.
(2) In both InvocationLink and ServiceLink, if there isn't a registered
serializer or deserializer, just pass the payload through rather than
ignoring the entire RPC.
Tickets should not be ignored if the end is in a grace period; rather
they should be ignored if they are for an unrecognized (likely new)
operation and the end is in a grace period.
(1) Call "cancel" on each future, not on the list of futures.
(2) If and when futures mature their actions should simply abort all
outstanding operations and cancel any other futures. They should not
shut down the _End's internal thread pool; only the termination action
of the last operation to terminate should shut down the pool (in the
case of their having been active operations at the time at which the
_End's stop(grace) method was called).
- Removing service_accounts credentials. These credentials just have
drawbacks compared to service_account_jwt_access credentials, notably
in terms for security.
- Renaming Google specific credentials with a Google prefix for C and
C++. This should be done as well for wrapped languages.
(1) In grpc._links.service._Kernel.add_ticket, premetadata() the call
if it has not already been premetadataed for any non-None ticket
termination, not just links.Ticket.Termination.COMPLETION.
(2) In grpc.framework.core._reception, add an entry to
_REMOTE_TICKET_TERMINATION_TO_LOCAL_OUTCOME for REMOTE_FAILURE.
REMOTE_FAILURE on a received ticket indicates the remote side of the
operation blaming the local side for operation abortion.
(3) In grpc.framework.core._reception.ReceptionManager._abort, only
abort the operation's other managers if the operation has not already
terminated, as indicated by the "outcome" attribute of the
TerminationManager.
(4) In grpc.framework.core._reception.ReceptionManager._abort, don't
transmit the outcome to the other side of the operation. Either it came
from the other side in the first place and to send it back would be
telling the other side something it already knows, or it arose from a
network failure and there's no confidence that it would reach the other
side.
This is the public API of the old face package of RPC Framework
extracted into a first-class interface and adapted to metadata, status,
and flow control.
This is the public API of the old base package of RPC Framework
extracted into a first-class interface and adapted to metadata, status,
and flow control.