facebook

JAR file locking after build-automatically

💡
Our Forums Have Moved

For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub

  1. MyEclipse IDE
  2.  > 
  3. General Development
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #243039 Reply

    jwatson21
    Member

    I am currently working on a program where an Eclipse nature is being added to a MyEclipse Web project via the project context menu.

    During the process of adding the nature to the MyEclipse project, several JAR files are copied into the WebRoot/WEB-INF/lib directory. Once the nature has been added, the project workspace is rebuilt and the JAR files are subsequently locked.

    This causes a few problems. First, it prevents the JAR files from showing up under the lib directory in the tree-view. Second, it prevents me from deleting the files (or the project) through the Eclipse IDE or through Windows Explorer. Third, it prevents the files from being removed from the project (or from the project’s classpath) if the nature is removed at a later time.

    If I turn off build-automatically and rebuild the project at a later point none of this happens. Which leaves me wondering why the files are being locked only when the automated build process is invoked immediately after the nature is added. Also, I have tried adding this nature to a Web Tools project and this problem does not occur, which leads me to believe it is local to MyEclipse.

    Any help will be more than appreciated!

    #243048

    Riyad Kalla
    Member

    This causes a few problems. First, it prevents the JAR files from showing up under the lib directory in the tree-view.

    Actually they should be locked IF they were automatically added to your build path and thus show up in your package view. This is a setting under Window > Prefs > MyEclipse > J2EE Projects > Web Projects.

    Second, it prevents me from deleting the files (or the project) through the Eclipse IDE or through Windows Explorer. Third, it prevents the files from being removed from the project (or from the project’s classpath) if the nature is removed at a later time.

    Eclipse will typically release the lock after shutdown and after a fresh startup you can remove them. But agreed, this can be annoying if you are adding/removing JARs a lot, although most users won’t be and the indexer keeps read locks open on these JARs for autocomplete.

    If I turn off build-automatically and rebuild the project at a later point none of this happens.

    This could be related to automatically parsing the JAR contents, but that’s just a guess.

    Also, I have tried adding this nature to a Web Tools project and this problem does not occur, which leads me to believe it is local to MyEclipse.

    WTP doesn’t have the option to automatically mount JARs in the WEB-INF/lib dir into the build path, we do, that might be why you are not seeing this behavior with WTP.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: JAR file locking after build-automatically

You must be logged in to post in the forum log in