- Notifications
You must be signed in to change notification settings - Fork69
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
Can we get rid of some of the heavy wight transitive dependencies? Can we split the bsp4j artifact? My motivation is the extensible nature of build tools. Each build tool it designed differently. Where Mill provides Java, Scala, Scala Native and Scala.js support, Maven needs various plugin even to get a Java build started. Yet, when it comes to extensibility, it's not enough to just implement the BSP server support in one central place. Instead, each built tools needs to deal with the fact, that in order to provide a BSP server, it needs to somehow collect multiple parties and orchestrate them to appear as a unique self-aware BSP server. BSP capabilities need to be provided early in the protocol phase. To fulfil the modularity constraints, it's often wise to keep transitive dependencies of each party / module to a minimum and lightweight. In Mill, I'd like to support as much BSP extensions as possible, but that means I need to distribute the server implementation over these plugin. Obviously, those modules need to share some common API. The current bsp4j API isn't well suited for that purpose. The bsp4j artifact it currently rather heavyweight, as it come with lots of transitive dependencies like guava and Xtend. Currently, we mirror already some of these classes in Mill, to avoid to depend on bsp4j in all modules. We especially want to avoid all these libraries end up on the classpath of the build scripts, as some of these dependencies have caused issues in the past. Especially, when versions differ. Would it be possible, to split up bsp4j in some lightweight Java classes, implementing the building blocks of the protocol, and have the server implementation in a dedicated separate artifact? The server artifact can be as heavy as it needs to be, of course. |
BetaWas this translation helpful?Give feedback.
All reactions
What I want is absp4j.api and absp4j.server artifact. The former has no hevyweight implementation specific transitive dependencies and can be easily used in foreign APIs, e.g. amill-rust plugin. The latter may contain whatever is needed to launch a BSP server.
Replies: 2 comments 9 replies
-
I thought Xtend was already on its way out, but maybe@agluszak can elaborate on the status of that. I don't yet understand the entire problem though, could you elaborate a bit on the design you have in mind? |
BetaWas this translation helpful?Give feedback.
All reactions
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
Imaging an arbitrary Mill module, which provides some language support, for example a fictive Of course, this My concern is to split the published bsp4j artifact into an artifact with only some Pojos (without dependencies on gson and guava), and one containing the actual server implementation. |
BetaWas this translation helpful?Give feedback.
All reactions
-
What I want is a |
BetaWas this translation helpful?Give feedback.
All reactions
-
BetaWas this translation helpful?Give feedback.
All reactions
-
Well, so in general something is apparently configured wrong in the sbt file, because xtend shouldn't be needed at all at runtime. About guava I don't know, I'll check it when I'm back from vacation. But that was my idea too - to separate the json-defining API from the server. But before we do that I'd prefer to finish the migration to bazel. |
BetaWas this translation helpful?Give feedback.
All reactions
👍 1
-
@agluszak Maybe, I misunderstood you, but I though this issue should be fixed rather soon. Now, the bazel migration is done for some time, but I didn't receive any comments on#668. |
BetaWas this translation helpful?Give feedback.
All reactions
-
Ah, sorry, we now have a busy time at JB. I'll try to handle it next week, okay? |
BetaWas this translation helpful?Give feedback.
All reactions
👍 1
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
Didn't manage to find time to do that this week and since next week I'm on vacation, perhaps it's best if I write instructions for you and you do it yourself. You don't need to have experience with bazel to do it.
(assuming that you still want to use xtend and write it in kotlin, like the current bsp4j generator).
|
BetaWas this translation helpful?Give feedback.
All reactions
-
@lefou did you make progress there? |
BetaWas this translation helpful?Give feedback.
All reactions
-
No, I didn't try. |
BetaWas this translation helpful?Give feedback.