Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Use a resource collection to copy directories.

Posted on 2010-11-23
6
1,907 Views
Last Modified: 2012-05-10
Hello, I am working through a batch script to deploy EJBs because I was unsuccessful using the GlassFish Console to deploy EJB files.

This is what happens to me:


This file previously said this:

<target name="deploy.shared.lib.to.glassfish">
<copy file="${deployment.glassfish.shared.lib.file.path}" todir="${glassfish.home}/lib" overwrite="true" />
</target>

The problem is that where I work, we are not allowed to run anything on the c: drive, it has to be run on the d: drive. Well, the batch script has apparently been coded to work with the c: drive.

so I changed it to this:

<target name="deploy.shared.lib.to.glassfish">
<copy file="d:\NHINC" todir="d:\Sun\AppServer\domains\domain\lib" overwrite="true" />
</target>


Okay well, here's the problem. When I comment out and hard code in the location of these files just referenced directly above, I get this error:

Use a resource collection to copy directories.


I did some research that said this was a bug. It was like, well, great a bug, but I still need to get this deploy.bat to run!!!  

I am running GlassFish 2.1.1 bundled with NetBeans 6.7.1 on a 32bit Windows 2008 Server SP with 2 Gb. of RAM

Thanks,
Michele deploy.xml
0
Comment
Question by:midani222
  • 3
  • 3
6 Comments
 
LVL 86

Expert Comment

by:CEHJ
ID: 34201493
Try
<target name="deploy.shared.lib.to.glassfish">
	<copy todir="d:/Sun/AppServer/domains/domain/lib" overwrite="true">
		<fileset dir="d:/NHINC">
			<include name="**/*"/>
		</fileset>
	</copy>
</target>

Open in new window

0
 

Author Comment

by:midani222
ID: 34206485
Hello I implemented this, it is kind of interesting what happened. It was late last night when I told you the path to the library.

It should have been Sun\AppServer\domains\domain1\lib

anyway I used the other one the one with domain in it and what happened is that it keeps saying:

deploy.shared.lib.to.glassfish:
[copy] Copying 4060 files to:
d:\Sun\AppServer\domains\domain\lib

It has been doing this for about 40 minutes now.

I will try to kill the process and rethink this problem again.

Can you think of anything?
0
 
LVL 86

Accepted Solution

by:
CEHJ earned 500 total points
ID: 34207360
>>It has been doing this for about 40 minutes now.

So it works then?

0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 

Author Comment

by:midani222
ID: 34207566
well it would appear this this worked.
0
 

Author Closing Comment

by:midani222
ID: 34207571
thanks a whole bunch!
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 34208935
:)
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
servlet  URL Rewriting 1 42
jboss 7.1 start up error 1 40
Java: anonymous class 4 29
jsp error 6 26
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question