milleruntime commented on code in PR #2632:
URL: https://github.com/apache/accumulo/pull/2632#discussion_r852185596
##########
server/tserver/src/main/java/org/apache/accumulo/tserver/ThriftClientHandler.java:
##########
@@ -686,16 +685,27 @@ private void setUpdateTablet(UpdateSession us, KeyExtent
keyExtent) {
@Override
public void applyUpdates(TInfo tinfo, long updateID, TKeyExtent tkeyExtent,
- List<TMutation> tmutations) {
+ List<TMutation> tmutations) throws TException {
UpdateSession us = (UpdateSession)
server.sessionManager.reserveSession(updateID);
if (us == null) {
return;
}
+ ThreadPoolExecutor writeThreadExecutor = server.getWriteThreadExecutor();
boolean reserved = true;
+
try {
KeyExtent keyExtent = KeyExtent.fromThrift(tkeyExtent);
- setUpdateTablet(us, keyExtent);
+
+ // get write thread pool handler but only for user tablets
+ if (TabletType.type(keyExtent) == TabletType.USER) {
+ if (writeThreadExecutor.isTerminating()) {
+ throw new TException("Write Thread pool is terminating");
+ }
+ writeThreadExecutor.execute(() -> setUpdateTablet(us, keyExtent));
Review Comment:
I don't know. It might help if we knew the exact bottle neck.
`setUpdateTablet()` is just populating the `UpdateSession`. There is another
method after that flushes the update session.
This makes me wonder if the original problem was just too many mutations
going to a single tablet.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]