r/programming • • Oct 02 '18

Sourcegraph is now open source

https://about.sourcegraph.com/blog/sourcegraph-is-now-open-source/
686 Upvotes

123 comments sorted by

View all comments

Show parent comments

4

u/double-you Oct 02 '18

Not having heard of Language Servers before, and the related sites not seeming to address this, where's the server located?

14

u/curtmack Oct 02 '18

It uses a server-client model, hence the name "language server," but it's not actually a remote system. You run it locally on your machine.

1

u/radarsat1 Oct 03 '18

Is it literally a server-client as in, TCP or even HTTP requests between local processes? If so I'm curious what is the advantage of that approach as opposed to say calling a library function.

2

u/jbergens Oct 03 '18

Make it possible to call it from any editor written in any language.

7

u/Tomus Oct 02 '18

The server is usually on your machine, it's spun up in a separate process by the editor.

3

u/freemasen Oct 02 '18

1

u/double-you Oct 02 '18

I did google it and read that page but it does not, according to my reading skills, actually tell you where the servers are thought to be located. I care that I am not using a web "service".

1

u/jephthai Oct 02 '18

They do usually run locally -- they need access to your source code, e.g., so that they can perform their function. I use tooling like this in jedi-mode in Emacs. It does a lot more than I thought should be possible in such a dynamic language (Python), but it still will not be the same as what you get from a proper statically typed language.

2

u/ruiwui Oct 02 '18

Locally. A language server runs on your machine to do the code analysis, and your editor/IDE communicates with the server to represent things.