emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Remote asynchronous processes


From: Michael Albinus
Subject: Remote asynchronous processes
Date: Mon, 13 Apr 2020 12:19:43 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Hi,

On the Tramp ML, there is a discussion about performance of remote
asynchronous processes. start-file-process / make-process take too much
time to finish.

One of the reasons is, that Tramp opens first a shell on the remote
host, performs sanity checks, and runs the command after that. Well, I
cannot change this in general; the sanity checks have been added due to
feedback from users.

One idea to change the situation is, to remove all sanity checks from
make-process. That is, if a user has a default directory
"/ssh:user@host:/path/to/dir", and if he calls

--8<---------------cut here---------------start------------->8---
(make-process
 :name "test"
 :buffer (current-buffer)
 :command '("cmd")
 :file-handler t))
--8<---------------cut here---------------end--------------->8---

this is translated directly into

--8<---------------cut here---------------start------------->8---
ssh -l user -o ControlMaster=auto -o ControlPath='tramp.%C' \
  -o ControlPersist=no host "cd /path/to/dir; cmd"
--8<---------------cut here---------------end--------------->8---

This would improve performance significantly. The drawback is, that
Tramp does not perform convenience checks, like password handling.

start-file-process would not be changed, and it behaves like before.

Comments?

Best regards, Michael.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]