Settings JavaBridgeSettings/en

Aus expecco Wiki (Version 2.x)
(Weitergeleitet von Settings JavaBridgeSettings)
Zur Navigation springen Zur Suche springen

Java Bridge Settings[Bearbeiten]

Show Java Bridge Menu in Main Menu[Bearbeiten]

If off, menu items for Java Bridge functions are only shown in the corresponding plugins submenu. If on, an extra submenu is shown in the top menu area. Disable this, if you are not (heavily) using the Java Bridge functionality, and you want to keep the menu more compact.

Use System's Default JVM[Bearbeiten]

If on, the system's default JVM is used and the JVM path below is ignored. That means, that the Java VM is used which is found via the plain "java" command. This may make your test runs somewhat unreproducible, because JVMs may differ in their behavior, depending on the Java version. However, it may be useful to test default setups or to allow for a quick start, in case you do not know which JVM to use, or you do not know the installation path.

However, we recommend using a definite JVM version for real test runs, to ensure consistent behavior.

Specifying a different JVM Installation[Bearbeiten]

If you are to test deployability of your Java application, it may be a good idea to test against multiple JVM versions. For this, you can use two mechanisms:

  • either save and keep multiple settings files, each with different JVM settings, and run expecco with a corresponding "--settings" comamnd line argument.
  • create a little elementary action which shuts down all runing Java Bridges and changes the default path for future new bridges and execute this action before each test run. The action's Smalltalk code should be:
execute
    JBridge::Java exitAllInstances.
    JBridge::Java setJavaPath:'...path to your JRE or JDK...'.

or as JavaScript action:

execute() {
    JBridge.Java.exitAllInstances();
    JBridge.Java.setJavaPath("...path to your JRE or JDK...");

Notice that you'll have to duplicate "\"-characters inside a string constant in JavaScript, but not in Smalltalk. An even better implementation would have an input pin, and the path be passed in as action parameter.

The path given should be to the JRE/JDK folder, where "bin" and "lib" subfolders are present. Especially, "bin/java" or "bin\java.exe" should be present there.

(a corresponding action is included in the newest version of the standard library as "Java [ Set Java Installation Path ]")

Path to the Java Installation[Bearbeiten]

Defines the path to the Java VM and Java libraries that are to be used. The system tries to find out itself about which Java frameworks have been installed on the system and offers those paths in the combo list. However, if you have installed Java at a non standard or private place, either enter the path or select it using a browser dialog (click on the "..." button).

Because Java VMs may differ in their behavior and set of supported features, we recommend that you use an explicit path for reproducible test results. It may even be advisable, to use multiple tests/suites/runs that test the behavior against multiple commonly used Java installations.

Use the Builtin Java VM for local Groovy Actions[Bearbeiten]

This is an experimental feature, which should (currently) only be enabled by expecco developers (i.e. eXept staff). When enabled, the ST/X-libjava builtin JVM is used. This VM is tightly integrated into the ST/X system itself and does not use an external (Oracle-) JVM. This VM allows for much improved hot-pluggable code changes in the browser and debugger and offers a Smalltalk-like user experience to programmers. It does not support all of the newest Java features, and may therefore be not able to execute all Java programs. Please do not enable this feature in the current (2.8) version.

JDI Debugging enabled[Bearbeiten]

This checkbox is only shown if the Java Debugging Plugin is loaded, licensed and enabled. Please be aware that JDI Debugging is an experimental feature that eXept is not supporting as of yet.

Expecco can make use of the JDI (Java Debugging Interface) to interact with the Java VM for debugging purposes. This is especially useful to set/clear breakpoints, to single step in the tested Java application and to get more detailed information about the call stack in the debugger. However, it may affect the tested Java application's behavior, especially timing. Also, it may require appropriate security rights for the debug connection to be made.

If you encounter problems with the JDI interface, you may want to disable this feature.

Be aware that line breakpoints, single stepping in a Java application and some other features will be disabled in the debugger then. You can still place coded breakpoints (i.e. "halt();") and print statements into Groovy blocks for debugging.

Confirm Close of Bridge Connections[Bearbeiten]

Especially during debugging, you may very often use the "Shutdown Bridge Connections" menu item from the main menu. By default, this operations must be confirmed by a dialog window, which may be annoying. This checkbox allows for the confirmation dialog to be suppressed.



Copyright © 2014-2024 eXept Software AG