This sample illustrates the use of SCA to wire components together inside a composite. All connections between the components are local and are defined using Java interfaces.
Please install Apache Maven and build the library composites as described in the Getting Started section of the root readme.
To build the sample run:
$ mvn package
This will build and package the code that calls the calculator composite from a command line client environment.
To run the client, use the launcher
command from the standalone distribution:
$ java -jar {tuscany.installDir}/bin/launcher.jar target/calc.jar {add|subtract|multiply|divide} {param} {param}
where tuscany.installDir
is the path where you installed the standalone distribution.
The sample when run will display to the standard output:
$ java -jar {tuscany.installDir}/bin/launcher.jar target/calc.jar add 2 5 result = 7.0