Skip to main content

Posts

WSO2 App Factory - Developing New Application Type

This post will describe how to use extension points to develop an application type. In [1] you can find step by step guide of adding a new application type and its runtime. In this post I will explain following. Adding new Application Event Handlers Maven Archetype creation for App Factory Applications Extending the Application Type Processor Interface Extending Deployer Interface Adding new Application Event Handlers You can find the interface ApplicationEventsHandler in [3] Lets say you need to do some special stuff for your application type (like create a database when creating an application to support your app type), you can extend methods of this to do that. For example we are creating a datasource using an handler when we create a Data Service type application. You can find that code in [4]. After you develop your handler you can add it to an OSGI bundle and then deploy it to the AppFactory server's following location. $APPFACTORY_HOME/repository/components/dr...

WSO2 App Factory - Life Cycle of an application

This post will try to explain the general life-cycle of an application in WSO2 AppFactory. WSO2 AppFactory is a place where multiple project teams can collaboratively create run and manage enterprise applications[1]. With WSO2 AppFactory users can create an complex application and push it to production within a matter of couple of hours. Figure 1 - App Cloud Create Application Page If you go to WSO2 AppFactory and create an application it will do several operations that generates the resources needed for your application such as Create Repository Generate Sample Code for the Application Create Build Job Create Issue Tracker Project Deploy initial artifact in to PAAS artifact repository etc.. When you hit create application it will create an instance of the application RXT installed in WSO2 AppFactory and then will call a bpel which is hosted in the BPS. Any one can edit this bpel to add their workflow in to it. Currently this will just trigger the AF service to trigger...

WSO2 Products - How User Stores work

Today we keep our users and profiles in several forms. Some times they are in a LDAP. Some uses Active Directory (AD). Some uses databases and etc. WSO2 Products are written in a way any of these format could support. If some one have their own way of storing users and any one can easily plug them in to WSO2 products by just writing a custom user store. In this post I will explain how these user stores works and the other components connected to them. When we discuss about user management in WSO2 world, there are several key components. They are User Store Manager Authorization Manger Tenant Manager In simple user management we need to authorize some user to some action / permission. Normally we group these actions / permissions as groups and assign these groups / roles to users. So there are two kind of mappings that we need to consider. They are User to Role Mapping Role to Permission Mapping User to Role Mapping is managed by user store implementation...

How to include artifactid in a folder or file name or content of a file in a maven archetype.

When we create maven archetypes, specially the multi module ones, we might need to include the artifact id in to a folder or file name or include it to a content of a file. This can be done very easily. To include artifactid to a folder or file name you just have to add the place holder __rootArtifactId__ . **Note that there are two '_' characters before and after the word rootArtifactId. So for example if  you want a file name like -development.xml, then you can simply name it as __rootArtifactId__-development.xml. When file name is mentioned like this inside the archetype, when you run archetype generate command it will replace with the artifactid provided. Next thing is how to include this inside a file. This was tricky. I couldn't find a way to do it first. So I keep trying things and it works and it's simple. You can simply add the place holder ${rootArtifactId} . In the same pattern you can use other parameters like version as well by using __vers...

Tips to write an Enterprise Application On WSO2 Platform

Enterprise applications or Business Applications, are complex, scalable and distributed. They could deploy on corporate networks, Intranet or Internet. Usually they are data centric and user-friendly. And they must meet certain security, administration and maintenance requirements. Typically Enterprise Applications are large. Which is multi user, runs on clustered environments, contains large number of components, manipulates large amount of data and may use parallel processing and distributed resources. And they will try to meet some business requirements and at the same time it should provide robust and maintenance, monitoring and administration. Here are some features and attributes that may include in an Enterprise Application. Complex business logic. Read / Write data to / from databases. Distributed Computing. Message Oriented Middleware. Directory and naming services Security User Interfaces (Web and / or Desktop) Integration of Other systems ...

Dell Vostro 1520 Boot problem, Recovering & restore Grub from a live Ubuntu cd.

In Vostro 1520 Dell Laptop series, when Ubuntu installed with windows (Dual Boot), due to a problem in bios the MBR will get corrupted and after that you will be unable to see the Grub loader at the startup and you want be able to load either windows or Ubuntu. This happens only because of the corruption at MBR record or partition table.  So by reinstalling grub to the partition u can resolve this problem. The steps of resolving are given below. First you have to boot from the Ubuntu Live CD Then you have to find the sd number of the partition that grub is installed in. ( If you have a separate /boot partition it should be the boot partition sd number otherwise it should be the Ubuntu file system sd number. ). And here I assume that sd number is x . Open the Terminal and execute following codes sudo mkdir /mnt/root -- Setup a folder before change root. Using th...

Linux Mint updates bug found

Bug Description : Failed to fetch http://packages.linuxmint.com/dists/isadora/Release (malformed Release file?) Unable to find expected entry multiverse/binary-i386/Packages in Meta-index file Some index files failed to download, they have been ignored, or old ones used instead. Reasoning and Solution : There is no multiverse section in the Mint repository... please edit your /etc/apt/sources.list and remove the "multiverse" keyword from the lines referring to the Mint repositories.   How to Fix it: This command will open the sources list. ~$ sudo gedit /etc/apt/sources.list This is my file before editing and after editing Before :- deb http://packages.linuxmint.com/ isadora main upstream import multiverse import deb http://archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse deb http://archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse deb http://security.ubuntu.com...