A completed Java archive can be deployed directly to an eWON Flexy 202 over FTP. Eclipse is only one way to build and transfer the application; the gateway starts the uploaded archive from instructions stored in /usr/jvmrun. The deciding checks are whether the JAR already exists, whether it targets JRE 1.4, whether both files reach /usr, and whether jvmrun ends with an empty line.
Deployment prerequisites and artifact decision
- Confirm whether you have a finished
.jaror only Java source. If the JAR already exists, skip compilation and move to the FTP check. If only source exists, build the JAR before attempting deployment. - Confirm that the archive complies with JRE 1.4. A JAR produced for a newer runtime can transfer successfully but still fail when the Flexy tries to load it.
- Identify the class that starts the application. This value becomes the argument to
-emain; it is not the JAR filename. - Obtain the Flexy IP address and current administrator credentials. The example credentials
adm/admillustrate the login format but are not a required credential pair. - Confirm that rebooting the gateway is permitted. The documented launch sequence requires a reboot after the JAR and
jvmrunhave been transferred.
| Reading or item | Required outcome | Next check |
|---|---|---|
| Application artifact | Finished .jar
|
FTP access |
| Runtime target | JRE 1.4 compatible | Main-class value |
| Entry class | Known Java main class |
jvmrun construction |
| Reboot window | Available | Transfer and restart |
FTP access and destination check
- Open Windows File Explorer and enter
ftp://[eWON IP address]in the address bar. - Enter the gateway administrator credentials when prompted. Do not move on until the directory listing opens.
- Open the
usrfolder. The deployment destination isftp://[eWON IP address]/usr. - Copy the completed JAR into that folder. Refresh the listing and confirm that the uploaded filename exactly matches the filename you will place after
-classpath /usr/.
If File Explorer cannot establish the FTP session, test the same address and credentials with an FTP client or command-line FTP workflow. Failure before the directory listing appears is an access, addressing, or FTP-session problem; changing Java code will not correct it. If the listing opens but the upload does not persist, resolve write access or transfer failure before creating the startup file.
FTP transfer and Java execution are separate stages. Seeing the JAR in /usr proves only that the file reached the gateway. It does not prove runtime compatibility, a valid classpath, or a valid entry class.
jvmrun content and terminator check
Create a plain-text file named exactly jvmrun. Do not add a filename extension. Use the following three lines, replacing the JAR filename and main-class placeholder with the application values:
-heapsize 5M
-classpath /usr/YourJarFileName.jar
-emain YourMainClassName
- Set
-heapsizeto5Mfor this documented configuration. - Set
-classpathto the uploaded archive under/usr. The spelling, capitalization, and.jarsuffix must match the transferred file. - Set
-emainto the Java class that starts the program. - Press Enter after the
-emainline so the file contains an empty final line. Do not move on until a text editor shows the trailing blank line. - Copy
jvmruninto the same/usrdirectory and refresh the FTP listing to confirm that both files are present.
The gateway recognizes the fixed startup filename jvmrun. A file such as jvmrun.txt is a different filename, even when Windows hides the extension. The empty line at the end is part of the required file format; omitting it can prevent the launch configuration from being processed as intended.
Runtime and build-path decision
A customer deployment utility must distinguish building from uploading. Building converts source and dependencies into the JAR. Uploading moves an already-built binary to the FTP server. These operations have different prerequisites.
| Starting condition | Required action | Customer-PC dependency |
|---|---|---|
| Validated JRE 1.4-compatible JAR already exists | Upload the JAR and jvmrun
|
FTP capability |
| Java source must be compiled at the customer PC | Run a command-line or tool-driven build, then upload | Compiler, build files, and application dependencies |
| Only configuration data changes | Keep the Java binary separate from the generated configuration when the application design permits it | Configuration generator plus the defined transfer method |
The build.xml supplied with the eWON Java SDK provides the build sequence to reproduce when Eclipse is unavailable. A Windows front end can invoke an equivalent command-line build, but the customer PC must have the proper build dependencies. If the Java binary does not change, distributing a prebuilt, validated JAR removes the compiler and SDK from the customer workflow. The utility can then generate the installation-specific configuration and perform the FTP transfer.
Do not treat a JAR as a configuration file. It is an archive of compiled output and associated resources. Rebuilding it on every installation adds a failure point unless configuration must be embedded during compilation. When configuration remains external, use the filename and destination defined by the Java application rather than inventing a gateway path.
Restart and log-diagnosis branches
- Recheck the
/usrlisting immediately before restart. It must contain the expected JAR and a file namedjvmrun. - Reboot the eWON Flexy 202.
- Open the gateway web interface and navigate to
Diagnostic > Logs > Realtime Logs. - Look for Java startup information. Do not move on until the logs show whether the runtime processed the application.
| Observed outcome | Meaning | Next check |
|---|---|---|
| No expected Java startup activity | The startup file may be missing, misnamed, malformed, or not processed | Check the exact jvmrun name and final empty line |
| Startup reaches archive loading but not the entry class | The classpath or -emain value is wrong |
Compare both values with the uploaded filename and compiled class |
| Application begins loading and then stops | Runtime compatibility, dependencies, or application initialization requires inspection | Read the adjacent realtime-log entries and rebuild for JRE 1.4 if compatibility is the cause |
| Application starts and remains active | The transfer and launch configuration are working | Verify application behavior |
Repeatable customer deployment procedure
- Build and validate the JRE 1.4-compatible JAR before distribution, unless the customer utility intentionally includes every required build dependency.
- Have the utility collect the gateway IP address, administrator credentials, JAR filename, and Java main-class value.
- Generate
jvmrunwith-heapsize 5M, the exact/usr/[filename].jarclasspath, the correct-emainvalue, and an empty final line. - Upload the JAR to
/usr, then uploadjvmrunto the same directory. Read back or relist both remote filenames before offering the reboot action. - Reboot the gateway and open
Diagnostic > Logs > Realtime Logs. Confirm startup there before reporting a successful deployment.
FAQ
Why does the eWON Flexy 202 ignore my JAR?
A JAR in /usr is not sufficient by itself. Place a file named exactly jvmrun beside it, include the correct -classpath and -emain values, add an empty final line, and reboot the gateway.
Why does jvmrun fail when its three settings look correct?
Check that the file is not actually named jvmrun.txt and that it contains a carriage return producing an empty line after the -emain line. Also compare the classpath filename character for character with the JAR stored in /usr.
Why does the JAR upload successfully but not start?
FTP success verifies transfer, not execution. Check JRE 1.4 compatibility, the -emain class, the -classpath /usr/YourJarFileName.jar value, and then read the realtime log entries generated after reboot.
Can I deploy an eWON Flexy 202 JAR without Eclipse?
Yes. Upload the validated JAR and jvmrun to /usr by FTP, reboot the Flexy, and perform the final verification in Diagnostic > Logs > Realtime Logs.