Project

General

Profile

ANT DEPLOY.ALL ERROR

Added by Ritish Mehta over 6 years ago

Hello Team,

I am getting the following error "Target Deploy.all does not exist in P2J Conversion Project in BUILD.XML file" while running ANT DEPLOY.ALL using cmd.

Please help.

Thanks,
Ritish
[email redacted]

Ant-targets.png (23.3 KB)


Replies (45)

RE: ANT DEPLOY.ALL ERROR - Added by Greg Shah over 6 years ago

Some ideas:

The Apache Ant targets are case-sensitive. Please use ant deploy.all instead of ANT DEPLOY.ALL.

There are two different build processes involved in a given project:

  • The FWD technology.
  • The application being converted, such as Hotel GUI.

If your current directory is in the directory in which you installed the FWD code (usually named p2j), then you would be building FWD instead of converting the application. When building FWD, you should not use Apache Ant, but rather the ./gradlew.sh/gradlew.bat.

If your current directory is the "project" directory (e.g. for Hotel GUI) where the converted application exists, then you would use Apache Ant to run the conversion. The p2j directory should be a subdirectory of the project directory.

I mention this because the screen capture shows that the current directory is \Projects\p2j and that normally would be the place where the FWD technology is installed NOT where the application is being converted. Thus you would not normally run ant deploy.all there.

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Greg,

Really Thanks for quick reply!!.

I ran the ant script in project directory(chui project) and getting the error mentioned below.

BUILD FAILED
C:\Projects\hotel\hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_2
0170925\build.xml:211: C:\Projects\hotel\hotel_chui_demo_application_rev_52_fwd_
3_1_0_p2j_trunk_11165_20170925\p2j\build\lib does not exist.

FYI - Folder(C:\Projects\hotel\hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925\) does not contain any p2j folder.

Thanks,
Ritish

Image.png (12.7 KB)

RE: ANT DEPLOY.ALL ERROR - Added by Eric Faulhaber over 6 years ago

Ritish Mehta wrote:

FYI - Folder(C:\Projects\hotel\hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925\) does not contain any p2j folder.

In order for Ant to find the FWD binaries, you will need to create a symbolic link from the conversion project root folder (in this case, C:\Projects\hotel\hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925\) to the folder where FWD is installed. Please see here for instructions:

https://proj.goldencode.com/projects/p2j/wiki/Hotel_ChUI_Demo_Application#Create-the-FWD-Directory-Symlink-in-the-Hotel-Project-Directory

You may have to adjust the instructions slightly to account for the actual folder names/locations on your system.

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Thanks Greg for detailed explanation!!

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hello Team,

while using the URL https://localhost:7443/chui , i got a login screen on chrome browser for which i am giving my OS credentials but it shows me error "cannot start the embedded server". Please let me know how to resolve this error.

Thanks
Ritish

browse_error.png (10.1 KB)

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

Have you installed FWD spawner tool either by install_spawner.cmd or manually? The manual instructions:
Spawner Setup

Have you configured your browser with required certificates?

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Eugenie ,

Thanks for your response, Yes i have installed the FWD spawner tool by install_spawner.cmd and also configured the required certificates with my browser but i am still having the same error.

Thanks,
Ritish

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

Hi, Ritish,

1. Can you tell what is the Windows version you use?
2. What the ...\deploy\server\server.log says after Server Ready entry?
3. Are you able to start Swing client from command line:

cd ...\deploy\client
client.cmd

What is the result?
4. Make sure the Java jvm.dll is in system path in addition to java.exe, location: jre\bin\server\jvm.dll.

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Eugenie,

Below are the answers to your questions.

1. 8.1 Pro.

2. Please see the attached screenshot for logs after server ready entry.

3. Yes I am able to start Swing clients.

4. Yes it is available in (jre\bin\server\) path.

Note: we are running the following link(https://localhost:7443/chui) in Chrome Browser with all the required certificates to launch converted application.

Logs.png (68 KB)

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Please also see the attached error.

Error.png (10.1 KB)

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

Hi Ritish,

OK. Thanks for info. My suggest is to minimize path strings used.

1. Please re-organize your project tree the following way:
- main project: C:\Project\hotel\chui
- deploy directory: C:\Project\hotel\chui\deploy
- FWD directory: C:\Project\hotel\p2j with link to this directory inside C:\Project\hotel\chui
- spawner directory: C:\Project\hotel\spawner

2. Inspect your directory.xml file (in deploy\server dir) for the following entries to make sure they reflect new changes:

        <node class="container" name="clientConfig">
          <node class="string" name="spawner">
            <node-attribute name="value" value="C:\Project\hotel\spawner\spawn.exe"/>
          </node>
...
          <node class="string" name="workingDir">
            <node-attribute name="value" value="C:\Project\hotel\chui\deploy\client"/>
          </node>
...
        </node>

The idea is we have found environment limitations for some versions of Windows, including Win 8. Especially for child processes started from main one. So minimizing path entries length will decrease the possibility to have windows environment block or total path length limitation.

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Eugenie,

Directory.xml shows

&lt;node class="string" name="spawner"&gt;
&lt;node-attribute name="value" value="[spawner-path]"/&gt;
&lt;/node&gt;
&lt;node class="string" name="jvmArgs"&gt;
&lt;node-attribute name="value" value="-Xmx512m -Djava.awt.headless=true"/&gt;
&lt;/node&gt;
&lt;node class="string" name="workingDir"&gt;
&lt;node-attribute name="value" value="[client-start-dir]"/&gt;
&lt;/node&gt;

do we need to replace [spawner-path] and [client-start-dir] with exact paths?

Thanks,
Ritish

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

Yes,

Instead of [spawner-path] and [client-start-dir] in your directory.xml you need to have exact paths matching your current config. This is important to have properly configured directory.xml entries for web client to work.

Regards,
Eugenie.

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Eugenie,

Please see attached server log and directory.xml files. We are getting the different errors now. Please review the files.

Thanks,
Ritish

server.log Magnifier (16.3 KB)

directory.xml Magnifier (66.9 KB)

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

Hi Ritish,

Please reconfigure your demo directory tree according my previous hints for today. Looks like the resulting path is too long for environment block to be OK.

BTW, do you start the server and client under same user account?

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Eugenie,

Yes i have started under same user account.

Also i have some questions:

1. Can is it possible to have server and client on one machine and we can run the link on different machine for running the converted application?

2. Is this link is fixed for running the converted application?

Our project directory and FWD directory looks like: "C:\Projects\hotel\hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925" and
"C:\Projects\p2j" .

Do we need to change this directory so that it will look like: "C:\Projects\hotel\chui\"? I think only difference is replacing hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925 with chui keyword. Will this work?

Thanks
Ritish

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Eugenie,

I need your help on this. We are not able to process further.

Thanks,
Ritish

RE: ANT DEPLOY.ALL ERROR - Added by Greg Shah over 6 years ago

1. Can is it possible to have server and client on one machine and we can run the link on different machine for running the converted application?

Yes, this will work. In this case, the /server/default/webClient/host section of the directory will need to have the actual hostname of the system on which the server and client are running:

          <node class="string" name="host">
            <node-attribute name="value" value="FWD_SERVER_HOSTNAME"/>
          </node>

Replace FWD_SERVER_HOSTNAME with the real hostname. Do NOT use localhost.

2. Is this link is fixed for running the converted application?

I don't understand the question. The link chui/ is hard coded into the FWD project. We don't have a configurable way to change it at this time. But the code can be easily edited to change it.

Do we need to change this directory so that it will look like: "C:\Projects\hotel\chui\"? I think only difference is replacing hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925 with chui keyword. Will this work?

Yes, this is important. As Eugenie noted above, we have found problems with Windows 8 in handling long paths.

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

Hi Ritish,

Shortly speaking you need to replace your hotel_chui_demo_application_rev_52_fwd_3_1_0_p2j_trunk_11165_20170925 path entry with something shorter, like chui. In file system tree and in directry.xml

The p2j directory must be on the same file-system machine as demo code. There must be link inside demo main dir (where buil.xml, install_spawner.cmd)

Answering to your question (1) above I guess it is possible but directory tree must be exactly the same on two systems, java must be the same, ... so it is better to build on the same machine as server/client expected to be run.

Regards,
Eugenie.

RE: ANT DEPLOY.ALL ERROR - Added by Greg Shah over 6 years ago

Answering to your question (1) above I guess it is possible but directory tree must be exactly the same on two systems, java must be the same, ... so it is better to build on the same machine as server/client expected to be run.

If I understand correctly, I think Ritish was saying that both the server and client would run on the same system. It is the browser that would be running on a separate system. For this external access to work, the web client must be configured with the proper hostname instead of using localhost.

RE: ANT DEPLOY.ALL ERROR - Added by Eugenie Lyzenko over 6 years ago

My understanding was the case when demo is building on one machine but running on another. But this can be the wrong assumption.

RE: ANT DEPLOY.ALL ERROR - Added by Greg Shah over 6 years ago

My understanding was the case when demo is building on one machine but running on another. But this can be the wrong assumption.

OK, I understand your point now.

For the purposes of setting up a test system, I agree that it is best to convert/build on the same system that will run the server and client. This is not the way most will do it for a production system, but it will be easier for testing.

RE: ANT DEPLOY.ALL ERROR - Added by Greg Shah over 6 years ago

When using the ChUI web client from a separate system, you must make sure that the browser has network access to the IP address and ports for the system on which the FWD server and clients are running. If the browser is on the same network as the FWD system, then this is not an issue unless the FWD system has a firewall implemented. If the browser is on a remote network, the ports and IP address in use must not be blocked via firewall or router.

There are multiple components in use on the FWD system. The FWD server will be accessed via a single fixed port (7443 in your example, though this can be configured in the directory). The FWD clients (one per simultaneous user) will be accessed on different ports, one per client. Those client ports can be random (if the /server/default/webClient/port is set to 0) or a specific port range can be used.

If a firewall is in between the browser and the FWD system, then a reverse proxy can be implemented to expose only a single port. More details on reverse proxy can be found in #2683 (we haven't done the official docs yet for that feature yet but it is available in FWD v3.1).

RE: ANT DEPLOY.ALL ERROR - Added by Ritish Mehta over 6 years ago

Hi Team,

I have applied the changes as per Eugenie suggestions. Now Our project directory and FWD directory looks like: "C:\Projects\hotel\chui" and
"C:\Projects\p2j" .But still I am getting the error while launching the URL in Chrome Broser.

Please see the error in logs.

[01/31/2018 11:17:11 IST] (SessionManager.listen():INFO) {00000000:00000001:standard} Server ready
ERROR: API = CreateProcessWithLogonW
error code = 1783
message = The stub received bad data.

[01/31/2018 11:19:10 IST] (ClientSpawner.spawn():SEVERE) {qtp2122624820-38} Failed spawn with exit code: -6
ERROR: API = CreateProcessWithLogonW
error code = 1783
message = The stub received bad data.

I have also attached the log and directory.xml file.

Please help !! We are not able to proceed further.

Thanks,
Ritish

server.log Magnifier (6.46 KB)

directory.xml Magnifier (66.8 KB)

RE: ANT DEPLOY.ALL ERROR - Added by Greg Shah over 6 years ago

Ritish,

We are looking into this. Here are some links that may be related:

https://support.microsoft.com/en-us/help/2028588/error-1783-the-stub-received-bad-data (not very helpful)
https://stackoverflow.com/questions/27272919/createprocesswithlogonw-error-1783-the-stub-received-bad-data

The suggestion is that it is a UAC conflict in Windows 8.1.

We will be back in touch shortly.

Greg

(1-25/45)