I want to fetch data from MySQL database into a WSO2 BPEL process (designed in wso2 developer studio eclipse).
How to invoke the database from the bpel process?
You can create a data service in DSS to fetch data from DB. Refer [1]. Then invoke that service from BPS using a bpel invoke like explained in [2].
[1] - https://docs.wso2.com/display/DSS321/RDBMS+Sample
[2] - http://wso2.com/library/tutorials/2011/04/using-carbon-studio-model-wsbpel-process-using-bpel-editor/#scenario
Related
So quick question regarding WSO2 API manager and BAM from what I can tell Bam saves the basic requests to the API manager to the DB and the Publisher then reads from the DB when displaying the stats. At what point in the analyzer part of BAM in action ie Casandra and Hadoop. Or does that just get used if I write my own hive queries?
Thanks
When you integrate WSO2 BAM with API Manager for Analytics following happens.
API Manager publishers data using thrift for BAM.
There are hive scripts which is included in the toolbox. There are scheduled and when they are running summarized data will be inserted into the databases.
I have configured WSO2 DAS server to receive statistics from WSO2 API manager. I want see realtime statistics. Is there any way to configure it, So that I will get realtime stats & test?
In [1] you can find an example CAR file that has a usecase of showing an alert in the DAS backend console which has used with CEP realtime execution engine. You may refer it and modify it for your requirements with APIM stats visualization.
[1] https://docs.wso2.com/display/DAS301/Analyzing+Realtime+Service+Statistics
I have an Rest service build on wso2 Dss. This Rest call an SQL query link to an datasource.
I cannot find the way to switch on runtime the datasource. I want with the same service, do the same query on an different datasource that I can specified in parameter.
Thank for your help.
Best regards,
Nicolas
You can make several DSS services with different datasource and make Proxy service in WSO ESB to balancing requests to your DSS services by parameter in url.
I am new to WSO2 family (WSS, ESB & BPS).
Previously I did samples on creating datasource in WSO2 ESB and I have retrieved data from datasource using DBLookup in WSO2 ESB.
Now I have configured datasource in WSO2 BPS(from UI) and it is successfully connected to the database.
How Can I use the datasource that I configured in BPS in BPEL Workflow?
Please someone guide through it.
Thanks in Advance.
Please refer the doucumentation[1] which shows how to define a datasource and refer [2] which shows how to configure datasource in bps.xml
[1] http://docs.wso2.org/wiki/display/BPS300/Adding+RDBMS+Data+Sources#AddingRDBMSDataSources-jndi
[2] http://docs.wso2.org/wiki/display/BPS300/ODE+Configurations#ODEConfigurations-DataSource
I think the better approach would be to use WSO2 Data Services Server and create Data Service using the data source. (You can define the data source in Data Services server). After that you can call them using the BPS. Please refer following tutorial on such a comprehensive tutorial.
http://docs.wso2.org/wiki/display/DVS300/Retail+Banking+Sample
I am configuring Stratos 1.6.0 and trying get the following scenario working.
Create a database in Storage Server
Create a user in Storage Server
Assign the user to the database
Generate datasource for the user/database combination in the Storage Server
Create DataService in Data Service Server and use the data source above
From what I can see in the code... when one creates a datasource in a Carbon application, the org.wso2.carbon.ndatasource.core.DataSourceRepository will notify the member's in the cluster of the new DataSource. These members will then invalidate the registry cache.
The problem comes is that in the default clustering configuration in Stratos 1.6.0, the Storage Server and the Data Service Server are in different Tribe domains, so messaging using Tribe is not possible between the two types of applications.
How can one get the Data Service Server to update its datasource configuration when datasources are created in the Storage Server?
What you've mentioned in your query itself is exactly what's expected from providing the option to create a datasource via WSO2 Storage Server. However, there are certain technical complexities associated with sharing datasources across nodes/clusters of different Carbon products (other than the type of Carbon product in which the datasources are created) and we're currently in the middle of attending to them. Therefore, all considered, a better way to integrate SS with DSS would be, first create your database/database user in WSO2 SS, then create datasources with that information (connection strings, user credentials, etc) in WSO2 DSS and consume them.
Regards,
Prabath
P.S. You can refer http://sparkletechthoughts.blogspot.in/2013/04/relational-storage-solution-using-wso2.html which provides you with a comprehensive guide for creating databases/database users/privilege templates.