New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Injection over plain socket repl #96

Open
cgrand opened this Issue Dec 12, 2018 · 2 comments

Comments

Projects
None yet
2 participants
@cgrand
Copy link
Contributor

cgrand commented Dec 12, 2018

Make it possible to upgrade a plain socket repl to a nREPL connection.

A socket repl is a UTF-8 (Is it even guaranteed ?) connection, so upgrading it to bencode is not possible if real binary payloads are in use; are they? In any case we would need a custom bencoder that knows the underlying stream is already UTF-8.

The edn transport (#60) would be an easier target.

Since nREPL has multiplexed input a different injection strategy can be used than with unrepl: we can basically just inject a sideloader (#97). That would spare us all the blob generation.

@cgrand cgrand self-assigned this Dec 12, 2018

@cgrand cgrand added the Enhancement label Dec 12, 2018

@cgrand

This comment has been minimized.

Copy link
Contributor Author

cgrand commented Jan 10, 2019

So I started working on injection based on bencode. Work lives on this branch https://github.com/nrepl/nrepl/tree/injection

Right now the nrepl.upgrade namespace is a deps-free namespace that will be sent to the socket repl to upgrade it.

Currently it starts a pseudo-nrepl equipped only with a light version of the sideloader. Meanwhile it tries to eval (require 'XXX). This (require 'XXX) is a placeholder for real code to start nrepl.

@bbatsov

This comment has been minimized.

Copy link
Contributor

bbatsov commented Jan 10, 2019

Fantastic! Looks very promising!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment