Code Monkey home page Code Monkey logo

on-prem-connectivity-test-java-sample's Introduction

Simple on-premises data source connectivity validation tool

๐Ÿšซ This project is no longer maintained.

Bluemix Deployments

Use this utility to validate that Bluemix applications can access on-premises data sources that you've exposed using the Secure Gateway service and user-provided services.

sample output

For a quick introduction on how to configure the gateway service, set up user-provided services and prepare your on-premises environment, read the tutorial.

This application has been pre-configured for DB2, MySQL and PostgreSQL databases. To configure support for other RDBMSs follow these instructions. Note that the pre-configured application does not include the DB2 license file db2jcc_license_cu.jar (DB2 LUW) or db2jcc_license_cisuz.jar (DB2 for z/OS). Follow the instructions listed in section JDBC driver issues of the troubleshooting document to make tha appropriate library available.

Deploy to IBM Bluemix

You can deploy this application to Bluemix using the button provided below or manually. Note that Bluemix applications can only access services that are located in the same space. You must therefore deploy this application to a space where user-provided services have already been created or where user-provided services will be created.

Simple deployment using the Deploy to Bluemix button

The fastest way to deploy this application to Bluemix is to click the button.

Deploy to Bluemix

Don't have a Bluemix account? If you haven't already, you'll be prompted to sign up for a Bluemix account when you click the button. Sign up, verify your email address, then return here and click the the Deploy to Bluemix button again. Your new credentials let you deploy to the platform and also to code online with Bluemix and Git. If you have questions about working in Bluemix, find answers in the Bluemix Docs.

Once the application is deployed, follow the instructions in section Binding user-provided services below.

Manual deployment

To manually deploy this application to Bluemix:

$ git clone https://github.com/ibm-cds-labs/on-prem-connectivity-test-java-sample.git

$ cd on-prem-connectivity-test-java-sample

$ mvn 

$ cf push

Note: You may notice that Bluemix assigns a URL to your application containing a random word. This is defined in the manifest.yml file where the random-route key set to the value of true. This ensures that multiple people deploying this application to Bluemix do not run into naming collisions. To specify your own route, remove the random-route line from the manifest.yml file and add a host key with the unique value you would like to use for the host name.

Binding user-provided services

On-premises data sources are typically exposed to Bluemix applications using user-provided services, as described in the tutorial. By default, no services are bound to this application and the tool therefore won't run any tests. To validate that an application can successfully use the user-provided services that you have defined, bind them to this application using the Bluemix web console or the Cloud Foundry CLI client.

Binding user-provided services using the Bluemix web console

  • Log in to Bluemix.
  • Open the DASHBOARD and navigate to the space where you've deployed the application.
  • Double-click on the on-prem-data-source-access-test application tile.
  • Click BIND A SERVICE OR API.
  • Select the desired service instances.

If you bind a service other than user-provided, it is ignored by the application.

Refresh the application web page to view the test results.

Binding user-provided services using the Cloud Foundry CLI

To bind a user-provided service to the application run the following command, replacing SERVICE_INSTANCE with the name of the appropriate service, such as sample_db2inst1_on_QA1.

$ cf bind-service on-prem-data-source-access-test SERVICE_INSTANCE

Repeat this step for every user-provided service that you would like to test. After you've bound the desired services, restage the application by running

$ cf restage on-prem-data-source-access-test

If you bind a service other than user-provided it is ignored by the application.

Refresh the application web page to view the test results.

Troubleshooting

Refer to this guide.

Related sample application

If you don't have access to an on-premise database but want to explore the Secure Gateway Service, you can use this demo.

Privacy Notice

This web application includes code to track deployments to IBM Bluemix and other Cloud Foundry platforms. The following information is sent to a Deployment Tracker service on each deployment:

  • Application Name (application_name)
  • Space ID (space_id)
  • Application Version (application_version)
  • Application URIs (application_uris)

This data is collected from the VCAP_APPLICATION environment variable in IBM Bluemix and other Cloud Foundry platforms. This data is used by IBM to track metrics around deployments of sample applications to IBM Bluemix to measure the usefulness of our examples, so that we can continuously improve the content we offer to you. Only deployments of sample applications that include code to ping the Deployment Tracker service will be tracked.

Disabling Deployment Tracking

To disable deployment tracking rebuild the war file using the build-plain-war target and deploy the app.

License

Licensed under the Apache License, Version 2.0.

on-prem-connectivity-test-java-sample's People

Contributors

ptitzler avatar lornajane avatar

Watchers

G Adam Cox avatar Mike Elsmore avatar James Cloos avatar Alexia Tanski avatar Raj Singh avatar Maureen McElaney avatar David Taieb avatar Jess Mantaro avatar Chetna Warade avatar  avatar

on-prem-connectivity-test-java-sample's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.