Skip to content
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

apache-sshd-2.1.0: Various compilation errors #2161

Closed
uli-heller opened this issue Oct 5, 2018 · 0 comments
Closed

apache-sshd-2.1.0: Various compilation errors #2161

uli-heller opened this issue Oct 5, 2018 · 0 comments
Milestone

Comments

@uli-heller
Copy link
Contributor

uli-heller commented Oct 5, 2018

Upgrading apache-sshd from 1.7.0 to 2.1.0 produces these compilation errors:

...
  100,0% [##########] 8,4 MiB (2,2 MiB / s)
https://repo1.maven.org/maven2/org/apache/sshd/apache-sshd/2.1.0/apache-sshd-2.1.0.tar.gz
  100,0% [##########] 8,4 MiB (1,5 MiB / s)
[info] Fetched artifacts of root
[info] Compiling 284 Scala sources and 3 Java sources to /home/uli/git/forked/gitbucket/target/scala-2.12/classes ...
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/SshServerListener.scala:20:55: type mismatch;
[error]  found   : java.io.File
[error]  required: java.nio.file.Path
[error]     val provider = new SimpleGeneratorHostKeyProvider(new File(s"${Directory.GitBucketHome}/gitbucket.ser"))
[error]                                                       ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/GitCommand.scala:8:8: object Command is not a member of package org.apache.sshd.server
[error] import org.apache.sshd.server.{Command, CommandFactory, Environment, ExitCallback, SessionAware}
[error]        ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/GitCommand.scala:233:74: not found: type CommandFactory
[error] class GitCommandFactory(baseUrl: String, sshUrl: Option[String]) extends CommandFactory {
[error]                                                                          ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/SshServerListener.scala:26:7: type mismatch;
[error]  found   : gitbucket.core.ssh.GitCommandFactory
[error]  required: org.apache.sshd.server.command.CommandFactory
[error]       new GitCommandFactory(baseUrl, Some(s"${sshAddress.genericUser}@${sshAddress.host}:${sshAddress.port}"))
[error]       ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/NoShell.scala:5:8: object Command is not a member of package org.apache.sshd.server
[error] import org.apache.sshd.server.{Environment, ExitCallback, Command}
[error]        ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/NoShell.scala:9:55: not found: type Command
[error] class NoShell(sshAddress: SshAddress) extends Factory[Command] {
[error]                                                       ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/Plugin.scala:11:8: object Command is not a member of package org.apache.sshd.server
[error] import org.apache.sshd.server.Command
[error]        ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/Plugin.scala:312:56: not found: type Command
[error]   val sshCommandProviders: Seq[PartialFunction[String, Command]] = Nil
[error]                                                        ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/Plugin.scala:321:34: not found: type Command
[error]   ): Seq[PartialFunction[String, Command]] = Nil
[error]                                  ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/PluginRegistry.scala:27:8: object Command is not a member of package org.apache.sshd.server
[error] import org.apache.sshd.server.Command
[error]        ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/PluginRegistry.scala:62:87: not found: type Command
[error]   private val sshCommandProviders = new ConcurrentLinkedQueue[PartialFunction[String, Command]]()
[error]                                                                                       ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/PluginRegistry.scala:190:73: not found: type Command
[error]   def addSshCommandProvider(sshCommandProvider: PartialFunction[String, Command]): Unit =
[error]                                                                         ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/plugin/PluginRegistry.scala:193:59: not found: type Command
[error]   def getSshCommandProviders: Seq[PartialFunction[String, Command]] = sshCommandProviders.asScala.toSeq
[error]                                                           ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/GitCommand.scala:18:8: object UnknownCommand is not a member of package org.apache.sshd.server.scp
[error] import org.apache.sshd.server.scp.UnknownCommand
[error]        ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/GitCommand.scala:26:35: not found: type Command
[error] abstract class GitCommand extends Command with SessionAware {
[error]                                   ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/GitCommand.scala:236:48: not found: type Command
[error]   override def createCommand(command: String): Command = {
[error]                                                ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/GitCommand.scala:255:25: not found: type UnknownCommand
[error]           case _ => new UnknownCommand(command)
[error]                         ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/NoShell.scala:10:26: not found: type Command
[error]   override def create(): Command = new Command() {
[error]                          ^
[error] /home/uli/git/forked/gitbucket/src/main/scala/gitbucket/core/ssh/NoShell.scala:10:40: not found: type Command
[error]   override def create(): Command = new Command() {
[error]                                        ^
[error] 19 errors found
[error] (Compile / compileIncremental) Compilation failed
[error] Total time: 190 s, completed 05.10.2018 12:08:52

Here the diff relative to current master:

uli@ulinuc:~/git/forked/gitbucket$ git diff
diff --git a/build.sbt b/build.sbt
index 3bc6f070..994de3a4 100644
--- a/build.sbt
+++ b/build.sbt
@@ -43,7 +43,7 @@ libraryDependencies ++= Seq(
   "org.apache.commons"              % "commons-compress"             % "1.18",
   "org.apache.commons"              % "commons-email"                % "1.5",
   "org.apache.httpcomponents"       % "httpclient"                   % "4.5.6",
-  "org.apache.sshd"                 % "apache-sshd"                  % "1.7.0" exclude ("org.slf4j", "slf4j-jdk14"),
+  "org.apache.sshd"                 % "apache-sshd"                  % "2.1.0" exclude ("org.slf4j", "slf4j-jdk14"),
   "org.apache.tika"                 % "tika-core"                    % "1.19",
   "com.github.takezoe"              %% "blocking-slick-32"           % "0.0.10",
   "com.novell.ldap"                 % "jldap"                        % "2009-10-07",

I'll probably have a look at the issue within the upcoming days...

@uli-heller uli-heller changed the title apache-sshd-2.0.0: Various compilation errors apache-sshd-2.1.0: Various compilation errors Oct 5, 2018
@takezoe takezoe closed this as completed in 0cc42f3 Oct 7, 2018
takezoe added a commit that referenced this issue Oct 7, 2018
@takezoe takezoe added this to the 4.30.0 milestone Oct 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants