Getting errors with ant in netbeans, but no meaningful error message is produced

I am pretty new to Java EE and Netbeans in general. I am getting errors with my build-impl.xml file when I am trying to deploy a project to glassfish. The project consists of a client folder, an ejb folder and a common folder.

 <ant antfile="${project.202-slit-ejb}/build.xml" inheritall="false" target="dist-ear">
        <property location="${build.dir}" name="dist.ear.dir"/>
        <property name="deploy.on.save" value="${build.deploy.on.save}"/>
    </ant>

<ant antfile="${project.202-slit-common}/build.xml" inheritall="false" target="jar">
        <property name="deploy.on.save" value="false"/>
    </ant>

<target depends="init" if="netbeans.automatic.build" name="-clean-after-automatic-build">
    <antcall target="clean"/>
</target>

These are code snippets from three errors I am getting. All of them followed by:

The following error occurred while executing this line:

Except for the last one, which is followed by:

 Unable to delete file C:\Users\User\Documents\NetbeansProjects\is202SLIT\Downloads\202-slit\202-slit-common\dist\202-slit-common.jar

From netbeans output. I have no idea what to do with this information, and after an entire night of browsing I can't find any fixes to similar problems.

Is there any common error when trying to deploy project files? In addition, these files work fine on my friends computer, even though we have the same version of netbeans, and the same version of JDK. We can't get it to work on any computer other than his.

I have tried to clone the project numerous time, also tried to copy it without using git, nothing is working so far. Please tell me if you need more information.

Answers


Solved! Apparently, glassfish preserves sessions across redeployment, which makes it impossible for ant to perform a clean build. Simply uncheck the "Preserve Sessions Across Redeployment" checkbox in Glassfish properties, and this is taken care for. This is Glassfish server 4.1, by the way.


Need Your Help

Select max int from varchar column

sql-server tsql

I am trying to retrieve the largest number from a varchar column that includes both numbers and strings. An example of the data I'm working with:

Android Dashboard Layout with TabHost

android user-interface android-activity android-tabhost

I have search and could seem to find anything close to the issue I am having so I figured I would ask.