Tuscany SCA Native Samples - Ruby BigBank Sample
This sample implements the "Simplified BigBank" scenario. A whitepaper describing
the scenario based on the SCA 0.9 Assembly specification can be found
here.
This sample uses multiple Ruby components, calls out to an external Web Service via a reference
and exposes the service as a Web Service.
The Ruby BigBank sample requires the following extensions:
Please follow the documentation to ensure you have these extensions built and installed
on your system
There are three sub projects in this workspace:
- bigbank.account
This contains the source code and SCDL artifacts for the SCA Ruby BigBank
composite implementing the account services.
- bigbank.client
A sample client which does a local call to the BigBank service.
- bigbank.wsclient
A sample client which uses an SCA Web Service reference to make a remote
call to the BigBank service.
Additionally, there is the bigbank.app.composite file. This
describes the configuration of the SCA BigBank composite deployed to the SCA
runtime.
Building the Ruby BigBank sample on Linux and Mac OS X
If using the binary distribution the samples are built and installed in
<tuscany_sca_install_dir>/samples - go directly to Running the samples on Linux and Mac OS X.
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- As the Ruby BigBank sample is based on Ruby scripts, a specific compilation step is not necessary -
only deployment is required. Deploy the Ruby samples only with the following command sequence:
- cd <tuscany_sca_install_dir>/samples
- ./configure --enable-ruby --enable-cpp=no --prefix=$TUSCANY_SCACPP/samples
- make install
NOTE: If you don't provide the --prefix configure option, it will by default install into
/usr/local/tuscany/sca/samples/RubyBigBank
Running the Ruby BigBank sample on Linux and Mac OS X
BigBank with basic client
- The Ruby BigBank sample requires the following extensions:
Please follow the documentation to ensure you have these extensions built and installed
on your system
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- Run the sample with the following commands:
- cd <tuscany_sca_install_dir>/samples/RubyBigBank/deploy/bigbank.client
- ./runclient.sh
BigBank with Web Service clients
- The Ruby BigBank sample requires the following extensions:
Please follow the documentation to ensure you have these extensions built and installed
on your system
- Ensure you have enabled Axis2/C to run Tuscany SCA services. Follow the instructions
found here.
- Start the Axis2/C simple http server:
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- AXIS2C_HOME=<path to Axis2/C version 0.96>
- cd <tuscany_sca_install_dir>/samples/RubyBigBank/deploy/bigbank.account
- ./runwsserver.sh
- Now run the Web Service client:
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- AXIS2C_HOME=<path to Axis2/C version 0.96>
- Run the sample with the following commands:
- cd <tuscany_sca_install_dir>/samples/RubyBigBank/deploy/bigbank.wsclient
- ./runwsclient.sh
- The PHP web client detailed in the
CppBigBank sample can also be used
with the Ruby BigBank service that is served by the Axis2/C http server started above.
Building the Ruby BigBank sample on Windows
If using the binary distribution the samples are built and installed in
<tuscany_sca_install_dir>\samples - go directly to Running the samples on Windows.
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- As this sample is based on Ruby scripts, a specific compilation step is not necessary -
only deployment is required. Deploy the sample with the following commands:
- cd <tuscany_sca_install_dir>\samples\RubyBigBank
- deploy.bat
Running the Ruby BigBank sample on Windows
BigBank with basic client
- The Ruby BigBank sample requires the following extensions:
Please follow the documentation to ensure you have these extensions built and installed
on your system
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- Run the sample with the following commands:
- cd <tuscany_sca_install_dir>\samples\RubyBigBank\deploy\bigbank.client
- runclient.bat
BigBank with Web Service clients
- The Ruby BigBank sample requires the following extensions:
Please follow the documentation to ensure you have these extensions built and installed
on your system
- Ensure you have enabled Axis2/C to run Tuscany SCA services. Follow the instructions
found here.
- Start the Axis2/C simple http server:
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- AXIS2C_HOME=<path to Axis2/C version 0.96>
- cd <tuscany_sca_install_dir>\samples\RubyBigBank\deploy\bigbank.account
- runwsserver.bat
- Now run the Web Service client:
- The following environment variables are required:
- TUSCANY_SCACPP=<path to installed Tuscany SCA>
- TUSCANY_SDOCPP=<path to installed Tuscany SDO>
- AXIS2C_HOME=<path to Axis2/C version 0.96>
- Run the sample with the following commands:
- cd <tuscany_sca_install_dir>/samples/RubyBigBank/deploy/bigbank.wsclient
- ./runwsclient.bat
- The PHP web client detailed in the
CppBigBank sample can also be used
with the Ruby BigBank service that is served by the Axis2/C http server started above.