Oracle Java Cloud Service - SaaS Extension

All the productivity of Java, without the IT.

Local Weblogic Domain

Using the SDK against a local WebLogic domain - localextension.jar

The command-line tool javacloud.jar can be used against a local WebLogic domain. The associated Ant Tasks and Maven Plug-in can also be used against a local WebLogic domain. This provides you with the ability to write one build script that can be used in your development environment against a local WebLogic domain, and also against Java Cloud Service - SaaS Extension.

How will I use it?

Most of the commands do support an optional local argument. When this argument takes the value of true, the command is performed against the local WebLogic domain. The corresponding Ant tasks take local as an attribute. Similarly, the Maven plug-in goals also take local as a property.
For example:

  • -local or -local true (command line)
  • local="true" (Ant task)
  • -Dlocal=true or -Dlocal (Maven)

Implication of local mode in other arguments

Note: The argument classpath is applicable only when local is true.

Implications on other arguments when javacloud.jar is used in the local mode:
Argument Description
adminurl This becomes mandatory to point the local WebLogic domain's admin server. For example: t3://localhost:7001
user WebLogic admin user.
password Password of the WebLogic admin user.
identitydomain The value is not applicable and is not used currently.
serviceinstance The value is not applicable and is not used currently.
classpath The value must be specified for this argument.
The classpath must include the location of weblogic.jar and the location of localextension.jar.
The classpath can optionally contain whitelist.jar if whitelist validation needs to be enforced upon install and update operations.

Jobs - Async Behaviour

Some of the commands, such as install, are performed asynchronously in Oracle Cloud. The same behaviour can be retained when such operations are performed against a local WebLogic domain using an Ant script or Maven project. However, when these commands are performed against a local WebLogic domain on the command line, either by using javacloud.jar on the command line or the Maven plug-in without a project, the command is executed synchronously. In such cases, the command will not return until the operation on the server is completed.

Customising using

Users can have the property file in a directory pointed to by the the system property localextension.home to control the following things. If this property is not passed, the user home directory is defaulted. This file is completely optional. The following keys and values can be used in this file.
Note: This file should be placed on the machine where the tool runs. It may not be the machine where WebLogic Server runs.

1. Specifying deployment targets

KEY_DEPLOY_TARGETS=c1 # if you want to deploy the apps in a server or cluster c1

You can also specify a comma-separated list of deployment targets.
By default, if there is no cluster, the application is deployed to all available WebLogic Servers in the domain. If there is a cluster, the first cluster is used. This property affects all the application management operations, such as install, start, stop, delete, and update that are performed only in the specified target(s).

2. Specifying a load-balancer


The application URLs that are returned by listaplications or describeapplication will start with this base URL. When it is specified, the hostname or IP address of the WebLogic Server is not used in the application URLs.
By default, the IP address:port of the WebLogic Server where the application is targeted is used.

Note: Configuring the load balancer is outside the scope of localextension. You can only specify the load-balancer that is configured, here.