Thing which seemed very Thingish inside you is quite different when it gets out into the open and has other people looking at it

Friday, March 16, 2012

Validate Domain Ownership using StratosLive


In order to prove that your company is the owner of the domain, you need to validate the ownership of your domain. In < a href="https://stratoslive.wso2.com/home/index.html">WSO2 StratosLive there are two ways to validate your domain.
  • Creating a text file in the domain web root
  • Setting up a CNAME entry in your DNS.
From the above two methods creating a text file in the domain web root is the fastest way to validate your domain and you can do it within few seconds. If you proceed with the second option, it'll take up to 48 hours to reflect the added CNAME entry in your DNS. So in this knowledge-base, I'll explains how we can validate the domain ownership by adding a text file in the web root using WSO2 StratosLive.

Domain validation in stratos is easy. First login to WSO2 StratosLive as tenant admin using your account and go to Configurations -> Account -> Domain validation.


Under "Validate Domain Ownership", click on "Validate Now" and it will redirect to the domain validation page.
Then  you will get two options to validate your domain. Use the first option. And create a text file in your domain root call wso2multitenancy.txt. And add the given text content inside that text file you just created.

Click the "Validate" button, after you complete the above step. You will get a success message  for a successful validation. Click on continue to finish the validation process. After a sucessful validation, you will be redirected to Account management page with a message saying "Domain Validation Sucessful".

Expose your entire database as data services in two steps !!!


WSO2-Data Services Server provides the feature to expose your data as a service right away!!!. All you need to give is your database information and then generate data services to expose your database tables/schemas as per your need.

if you are using wso2 products for the first time ...
You need to download wso2 dataservices server.
Start up the server -> go to DS_HOME/bin/wso2server.bat | wso2server.sh (DS_HOME is where your set up is located)
Once the server is up and running open a web browser and navigate to https://localhost:9443/carbon.
Login it the server using the default credentials (username=admin, password=admin).

Also note that you need to provide the related jdbc driver for the database and put in repository/component/lib in order for this feature to work.

Step 1 :- Create a data source

In order to expose your database you need to create a data source using wso2 data services server.
To create data source click on Configure -> datasources

Click on add data source and give your data base information.


Once you create your data source you can test your connection by giving a validation query (ie Select 1) to make sure your connection is successful.

Step 2 Generating data services

You can start by clicking on the generate link in the main menue. Once you click on generate you will be directed to a wizard which will ask for the datasource and the database name which will be needed to expose.

Once you create you give your database name you will get the list of schemas/tables to select for your data service.

Click on next to view the created data services


Click on finish to view the deployed services.

You can try your service by clicking on try this sample for database transactions :) You can also generate axis2 clients by clicking on the data service and going to the service dashboard.



Once you create your data service there are features to enable security, throttling and caching by going to the service dashboard as shown below.
Try your service - using the try it tool.