|
|
@ -397,6 +397,7 @@ void ChaoticGoodServerTransport::AbortWithError() { |
|
|
|
// Close all the available pipes.
|
|
|
|
// Close all the available pipes.
|
|
|
|
outgoing_frames_.MarkClosed(); |
|
|
|
outgoing_frames_.MarkClosed(); |
|
|
|
ReleasableMutexLock lock(&mu_); |
|
|
|
ReleasableMutexLock lock(&mu_); |
|
|
|
|
|
|
|
aborted_with_error_ = true; |
|
|
|
StreamMap stream_map = std::move(stream_map_); |
|
|
|
StreamMap stream_map = std::move(stream_map_); |
|
|
|
stream_map_.clear(); |
|
|
|
stream_map_.clear(); |
|
|
|
state_tracker_.SetState(GRPC_CHANNEL_SHUTDOWN, |
|
|
|
state_tracker_.SetState(GRPC_CHANNEL_SHUTDOWN, |
|
|
@ -439,6 +440,9 @@ absl::Status ChaoticGoodServerTransport::NewStream( |
|
|
|
GRPC_TRACE_LOG(chaotic_good, INFO) |
|
|
|
GRPC_TRACE_LOG(chaotic_good, INFO) |
|
|
|
<< "CHAOTIC_GOOD " << this << " NewStream " << stream_id; |
|
|
|
<< "CHAOTIC_GOOD " << this << " NewStream " << stream_id; |
|
|
|
MutexLock lock(&mu_); |
|
|
|
MutexLock lock(&mu_); |
|
|
|
|
|
|
|
if (aborted_with_error_) { |
|
|
|
|
|
|
|
return absl::UnavailableError("Transport closed"); |
|
|
|
|
|
|
|
} |
|
|
|
auto it = stream_map_.find(stream_id); |
|
|
|
auto it = stream_map_.find(stream_id); |
|
|
|
if (it != stream_map_.end()) { |
|
|
|
if (it != stream_map_.end()) { |
|
|
|
return absl::InternalError("Stream already exists"); |
|
|
|
return absl::InternalError("Stream already exists"); |
|
|
|