Classpath jar files kept in use on Windows (Scala IDE)

41 views
Skip to first unread message

Lee Sanders

unread,
Aug 24, 2016, 12:01:40 PM8/24/16
to Scala IDE User
Hey, our Eclipse .classpath references jar files that are replaced by a command-line build when dependencies change as part of executing that build.  With Java this worked fine and we would just Refresh the Java project to pick up the changed dependencies.  Now adding Scala builder and Scala nature to that project the command-line build fails as the jar files seemed to be kept in use in memory and the jar files cannot be replaced because of that.  I don't want to close the project to do a rebuild.  

Is this expected behavior?   A limitation or requirement of keeping file handles to those jars open constantly?

Thanks for any input.

Simon Schäfer

unread,
Aug 24, 2016, 1:59:22 PM8/24/16
to scala-ide-user



---- On Wed, 24 Aug 2016 17:16:35 +0200 Lee Sanders <hlees...@gmail.com> wrote ----
> Hey, our Eclipse .classpath references jar files that are replaced by a command-line build when dependencies change as part of executing that build. With Java this worked fine and we would just Refresh the Java project to pick up the changed dependencies. Now adding Scala builder and Scala nature to that project the command-line build fails as the jar files seemed to be kept in use in memory and the jar files cannot be replaced because of that. I don't want to close the project to do a rebuild.
>
> Is this expected behavior? A limitation or requirement of keeping file handles to those jars open constantly?

There shouldn't be a need to keep JAR files open - the question now is where this happens because I don't think that we keep JAR files open knowingly.

iulian dragos

unread,
Aug 27, 2016, 3:42:56 PM8/27/16
to scala-i...@googlegroups.com
It's the Scala compiler (and presentation compiler): https://issues.scala-lang.org/browse/SI-9682

iulian
 

--
You received this message because you are subscribed to the Google Groups "Scala IDE User" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scala-ide-user+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/scala-ide-user/156bdb4cacc.b80ec1d167510.4217196560994670796%40antoras.de.
For more options, visit https://groups.google.com/d/optout.



--
« Je déteste la montagne, ça cache le paysage »
Alphonse Allais

Arnaud

unread,
Aug 28, 2016, 8:44:35 AM8/28/16
to Scala IDE User
I had similar problems when switching the current Git branch on Windows, because jar files were locked by something in the Scala project.

It works better on MacOS :)
(I suppose it's because the FileSystem allows to delete open files.)

Arnaud
Reply all
Reply to author
Forward
0 new messages