Accessing WSO2 BPS and ESB registry from code - wso2

I am trying to access the registry of WSO2 BPS and WSO2 ESB from Java in order to automatically fill the registry based on the data I provide.
I have already found a number of resources about the required Java code and dependencies, this being the most helpful one: [WSO2 Governance Registry]Using WSRegistryServiceClient. However, the approach described in these resources depends on the WSRegistryService service. This service is included in Governance Registry by default, but not in the other WSO2 products. I have verified that my code works for the Governance Registry. For any other WSO2 product on my machine, I get this error:
The service cannot be found for the endpoint reference (EPR) https://localhost:9445/services/WSRegistryService
I found an old thread suggesting that it should be possible to install the WSRegistryService on other WSO2 products as well, but I have not been able to find out how to do so. I can't seem to find it within the features I can install from the web console of the products. I have also tried manually copying the relevant jar from the plugins directory of Governance Registry into the plugins directory of other products, but that doesn't seem to be sufficient.
Note that my application for filling the registry will not be running on the carbon server whose registry I want to access, so using CarbonContext.getThreadLocalCarbonContext() (an approach I found in some other articles) is not an option.

I think your referring to how to install features to WSO2 products,
Please find this documentation.

Related

WSO2 APIM storing files in gov registry

I have another question on WSO2 APIM 2.6.0
I am working in one scenario where I have to store one file which is in json in gov registry. I can do that manually from the dashboard but I am looking for a way to perform that using API or in automated way.
Research done till now
1) Checking on the link which ideally enable WSO2 ESB to maintain a remote registry. But I am unable to get how the registry DB will be shared between the applications (APIM and ESB).
Like, ESB has property where we can store the data in registry directly from proxy or an API and also enables us to retrieve them accordingly.
But how do we do in APIM to store the file with json content.
Any suggestions here.
Thanks

Error occurring while Listing wsdl from wso2 governance

I have added wso2 governance registry on wso2 BPS 3 as a feature from http://dist.wso2.org/p2/carbon/releases/turing/
and restarted.
When tried to add wsdl from file it giving error:
org.wso2.carbon.governance.api.exception.GovernanceException: Attribute Search Service not Found.
I am trying to use BPS, GREG as a single component to reduce servers in my project. After GREG added as a feature it adding ".wsdl" file at "_/system/governance" and it is not forming endpoints,services as GREG normally do.
Is there any way to get out of this problem.
Thank's in advance....
The reason for this is missing some of the features which needed in ordered to work governance features. I think best option is using Governance Registry separately and mount the registry of it to BPS. By doing this you can add services from Governance Registry and use them in BPS. You can follow this document for more information on registry mounting.

confused with the relationship between WSO2's products

After study WSO2 products, seems I got the following concepts, all of them are only my understanding, I don't know whether is correct or not, please advice:
All the products are running in Carbon which is a 'container' of the wso2 products, something like JSP like stuffs running in tomcat. am I right?
if No.1 is correct, so 'Enterprise Service Bus', 'Identity Server', 'Data Service Server', 'Governance Reistry' etc are all running in Carbon Server, actually I downloaded all the products, and I found they are all released with carbon together, which mean I can use command to start the management console directly, and each of them can running themselves, they have there own management console. right?
after I read Carbon user guide, it says 'all the products of wso2 are the components of Carbon', so I think 'Enterprise Service Bus', 'Identity Server', 'Data Service Server', 'Governance Reistry' can be put into one management console, which mean they can be integrated together, after I started Carbon server, all the features are running together?
I'm sorry ask such kind a stupid question, but after read many articles I still cant find out the structure between them, please advice, thanks in advance.
WSO2 middleware products come with a bunch of components. These are based on Java OSGi. So every product comes with a set of OSGi bundles (in OSGi terminology). Carbon is a core framework that's common to every product. This is again a bunch of OSGi components. Carbon core (which is also reffered to as just Carbon) contains a set of must have bundles. Logging, clustering, security etc... Carbon is a separate download also which you can run. Running carbon itself by its own is not very interesting unless you're doing something specific and you know what you're doing.
Now, coming back to the products .. each product have carbon core plus some more OSGi components. These additional components reflect product specific functionality. For example if you take the ESB, it's carbon core plus additional components that makes it an "ESB". Likewise for other products.
You can take the carbon server and install all these additional features. Feature installation is done via the same technology Eclipse is using to install plugins. Since everything is an OSGi bundle there has to be an OSGi container that all these run on. Carbon is running on top of Equinox OSGi container.
So Tomcat is also a separate OSGi bundle. You can install these components into any running carbon server and instantly add webapp hosting capability.
Yes. All WSO2 products are running inside WSO2 Carbon which is mainly a OSGi based framework.
Yes. A WSO2 Product (e.g., ESB) is a specialized Carbon framework. Management console is a part of Carbon where you can install external features to the product / uninstall existing features in the product to customize the product.
Yes theoretically. If the Carbon concept is correctly implemented in all the components of WSO2, they (ESB, IS, DSS as you said) should be installable in a single Carbon server without any problem using the WSO2 Feature Manager. But due to some dependency conflicts and version conflicts sometimes it may not be possible if you try to do it. But still you can resolve these OSGi conflicts in code level and make it possible to make them compatible, if you want.
Actually all the WSO2 products share the WSO2 components seamlessly among their products already. And in some instances we recommend to install multiple products in a single Carbon server. For example CEP feature is asked to be installed in BAM product when the user wants to use CEP as a realtime data processing solution with the BAM. For most other product combinations we have not yet tested well so the conflicts can occur. Thats why I said this theoretical.

WSO2 Identity Server - XDAS Auditing

The WSO2 Identity Server features list XDAS, but I can't find any more information on how WSO2 uses it.
Is there any documentation available about how the WSO2 Identity Server uses XDAS?
Does the Identity Server have an XDAS service API that it can offer auditing services for use by other (external) applications?
WSO2 offer a Centralized Auditing & Monitoring solution. How can I set this up for myself?
We have done some work with XDAS in the WSO2 platform and the effort is on hold due to the less demand for XDAS.
You can find additional details from here : http://mail.wso2.org/mailarchive/architecture/2011-February/004868.html
I have checked out the whole WSO2 trunk and performed a find for files containing XDAS in their filename and a grep for files containing XDAS in their contents. Nothing was found.
My guess is that XDAS has not been implemented in the WSO2 platform.

wso2 product Registry menu (config, governance, local)

Is there any authoritative documentation available for data found under the Registry UI menu (for example as found in WSO2 ESB admin screens)?
I have seen snippets of information about this registry, for example:
The configuration registry contains product specific configuration
that can be shared across multiple instances of the same product (a
cluster of ESB nodes for example).
Source: link
To start with, I have a few questions:
What is the difference between this registry and the WSO2 Governance Registry?
What are the typical use cases for a WSO2 esb admin user for interacting with this Registry?
What are the typical use cases for a WSO2 esb developer for interacting with this Registry?
Is there a description of all the meta data stored in this registry?
In All WSO2 products there is an internal registry which is used to store resources. WSo2 Governance Registry uses the same core features + some more feature that gives complete Governance scenario. If you need you can mount to an external WSo2 Governance Registry without using the internal registry you referred.You can find more details here.