So once we are done with the installation and configuration of domain and we can go ahead and create our first OSB process.
I will make it easy.We will be creating a simple business process where in we will just poll a particular directory and we will archieve that data.
So first of all start weblogic server and one of the managed server.For this exercise we need not start both the managed server.
ONce it is up and running log in to the OSB console using the following url
http://localhost:port/sbconsole.
ONce you log in to OSB console you can Click on Project Explorer where in we can define our project.
For any OSB Process to create we need to create a session.So first of all we will create a session.Creating a session is just like keeping a record of what all things have been done in the process at what time.
So just say create a new session.
Now add a new project to the service
Now go the new project you have created and select the proxy service
Proxy service is the front end url provided to the customer.
Now provide some service name to the service and let the other configuration be the default
Now in the next page select File as the protocol and provide the location which you wanted to poll
Now in the next page provide details,I am archiving it so have chosen archieve as option you can choose delete also,Again i have already created three folder structure for stage,archieve and error.
Archieve and error are clear from their nameitself but i am not sure of what is the use of stage directory.Seeking readers input.Once changes are done say next
Verify the settings and save the changes.
Now activate the changes.While activating the changes you may get an error like this
Failed to obtain WLS Edit lock; it is currently held by user weblogic. This indicates that you have either started a WLS change and forgotten to activate it, or another user is performing WLS changes which have yet to be activated. The WLS Edit lock can be released by logging into WLS console and either releasing the lock or activating the pending WLS changes.
For this Log in to the weblogic console
http://host:port/console and say activate changes there.once done come back to the sbconsole and try to activate the OSB service.
So once it is activated you can check the process.Copy a file in the inbound location and then check the archieve location if the result file is store over there.
So you are ready with your first sample in OSB.NOw if you want you can further add business Service in the Project.Business Service is nothing but the place where in we define our business logic.
We will try to add one business service which will further write this input file in to some other directory.So lets add one Business Service.
Go to your project and add a business Service there
Now choose file as protocol and give location where you want to write the file
Then add the URI location and say next
Keep saying next till you get the final configuration page.Verify all the configuration details and save the changes.Once done activate the changes.
Now We need to define some business logic to add these two proxy and business service
Now go to file polling P{roxy service and click on edit message flow
Now add a pipeline which is nothing but a request response scenario in OSB
You can define your business logic so i am leaving it up to you to design it further.
1 comment:
You chose http protocol instead of file protocol for the business service :)
Post a Comment