tag:blogger.com,1999:blog-74412657785088439932024-03-13T22:22:12.795-07:00Aja wegblogB.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.comBlogger9125tag:blogger.com,1999:blog-7441265778508843993.post-89314651896391869002013-02-17T09:07:00.000-08:002013-02-17T09:11:22.229-08:00How to Run Jaggery.js App in Heroku Cloud<div dir="ltr" style="text-align: left;" trbidi="on">
<a href="http://jaggeryjs.org/">Jaggery.js</a> is a server side javascript framework for writing front-end ,communication ,server side logic and persistence in pure javascript.I felt that there<br />
is no public cloud hosting service available for hosting jaggery apps for free(Other than <a href="https://stratoslive.wso2.com/">stratoslive.wso2.com</a>).So i have attempted to run a jaggery server on famous platform as a service <a href="http://www.heroku.com/">Heroku</a>.In this post i am going to describe how to run a jaggery app on Heroku.<br />
<br />
<div style="text-align: left;">
Pre-request for running apps in Heroku cloud.</div>
<br />
1.The app should be written in supported languages(Ruby, Node.js, Clojure, Java, Python, and Scala).<br />
2.All the java apps should be pushed to git as Maven project <br />
3.Heroku only allow apps to open port that is given by a system variable PORT.<br />
4.App should bind to the port within 60s.<br />
5.App should not store anything to file for long term persistence.<br />
6.Data base details will be given by a system variable DATABASE_URL.<br />
etc... <br />
<br />
<br />
So the challenge is to make the Jaggery server to obey above rules.<br />
<br />
Jaggery server is actually a <a href="http://wso2.com/products/carbon/">WSO2 carbon server</a>.Which is actually a java app.so it should run in Heroku.To run a WSO2 Carbon app we have to set the JAVA_HOME.<br />
But in Heroku during application launch java will be added to system path but JAVA_HOME will not be set .I have added following to WSO2 Carbon startup script to set the JAVA_HOME .<br />
<br />
export JAVA_HOME=$(which java |xargs readlink -f | sed "s:bin/java::");<br />
echo "Setting JAVA_HOME to $JAVA_HOME "<br />
<br />
Next thing is, i have to create a Maven project that should build a Jaggery server and copy Jaggery app into deployment folder.There are no Jaggery server dependency that i can get it as a zip file.But fortunately all the required dependencies for building a Jaggery server from a Carbon server are available.<br />
I was able to create a Maven project that can build a jaggery server form carbon server.<br />
The usual way of running java apps in Heroku, is specifying the launch command in Procfile.Procfile for the above Maven project looks like following<br />
<br />
web: sh server/heroku-run/jaggery-1.0-SNAPSHOT/bin/server.sh<br />
<br />
This means the Maven project has to unzip the built Jaggery server into heroku-run folder of server Maven module.<br />
<br />
Now the a Maven project is ready that can build a Jaggery server and has a Procfile to launch the Jaggery server.But in order to start the server I have to make sure that the Jaggery server opens only one port.<br />
Jaggery server will open altogether 6 ports by default.Following are the ports and how i disable those ports.<br />
<br />
1.http/https:These ports are opened by tomcat connectors.I need to make sure only one port to be opened.so i disabled the https connector in JAGGERY_HOME/carbon/repository/conf/tomcat/catalina-server.xml<br />
<br />
2.jmx(2 ports):There is a configuration to not to start the jmx server.The file name is CARBON_HOME/repository/conf/etc/jmx.xml<br />
<br />
3.Zookeeper server(opens one port):To disable Zookeeper there should be a property(start_zk_server=false) in /carbon/repository/conf/etc/zoo.cfg<br />
<br />
4.jmx remote (opened by tomcat):To disable this -Dcom.sun.management.jmxremote<br />
should not be set.<br />
<br />
Finally the port number in tomcat connector has to be set to the port number in PORT system variable provided by Heroku.All the configuration files in jaggery server can accept java system variable in the form of ${SYSTEM_VARIABLE}.To set that system variable we have to pass -DSYSTEM_VARIABLLE=value in start up script.In this way the value in PORT system variable can be passed to tomcat connector configuration.<br />
<br />
The same way the information in DATABASE_URL(database url,username,password and database name) system variable should be passed to JAGGERY_HOME/carbon/repository/conf/datasources/master-datasources.xml.<br />
<br />
The Maven project can be found in Github here<br />
<a href="https://github.com/ajanthan/heroku-jaggeryjs-app-runner">https://github.com/ajanthan/heroku-jaggeryjs-app-runner</a><br />
<br />
Follows are steps to run your Jaggary app in Heroku.<br />
<br />
0.Register in https://heroku.com and install Heroku tool<br />
1.git clone http://github.com/ajanthan/heroku-jaggeryjs-app-runner.git<br />
2.heroku create<br />
3.heroku addons:add heroku-postgresql:dev<br />
4.heroku config<br />
5.heroku pg:promote HEROKU_POSTGRESQL_RED_URL<br />
6.Insall postgresql (https://devcenter.heroku.com/articles/heroku-postgresql#local-setup)<br />
apt-get install postgresql<br />
7.heroku pg:psql<br />
\i /home/heroku-jaggeryjs-app-runner/dbscript/postgresql.sql<br />
8.add your Jaggery app to apps/ROOT directory<br />
9.git add .<br />
10.git commit -m "adding initial project"<br />
11.git push heroku master<br />
12.heroku logs -t<br />
Access my app here<a href="http://ajanthan.herokuapp.com/"> http://ajanthan.herokuapp.com/</a><br />
<br />
<br /></div>
B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com9tag:blogger.com,1999:blog-7441265778508843993.post-27899587008888253642013-02-15T02:57:00.001-08:002013-02-15T03:04:43.177-08:00WSO2 App Factory Preview <div dir="ltr" style="text-align: left;" trbidi="on">
Yesterday WSO2 announced the public preview of WSO2 App Factory beta on their annual conference <a href="http://wso2con.com/" target="_blank">WSO2Con 2013</a>.You can access App Factory here<br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><span style="color: #134f5c;"><a href="https://appfactorypreview.wso2.com/" target="_blank">https://appfactorypreview.wso2.com </a></span></span></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
In order to login to the App Factory you have to be a registered user in <a href="http://wso2.org/" target="_blank">WSO2 Oxygen Tank</a>.If you are still not a registered user,click get started button it will direct you to</div>
<div style="text-align: left;">
<a href="https://wso2.org/user/register" target="_blank">WSO2 Oxygen Tank registeration</a> page.</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjyY3LleljOyPsEFrUM8SyhGzE6vbgq9X1hO81-rYEbacxeasIO3HX4iLCuYENyuykxepWDkjWJuEX8kjIyLfb8Wr-gsqW5Pba8nweYjPkwC04rMDEVJyAQsfDg5Mhbva1azwFdImf3Plw/s1600/signup.jpeg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="292" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjyY3LleljOyPsEFrUM8SyhGzE6vbgq9X1hO81-rYEbacxeasIO3HX4iLCuYENyuykxepWDkjWJuEX8kjIyLfb8Wr-gsqW5Pba8nweYjPkwC04rMDEVJyAQsfDg5Mhbva1azwFdImf3Plw/s640/signup.jpeg" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
After success full login you can create new application.</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYqXIatGgIfnpzwaXBPWxxZcazgMl-Vd1W_3CbT3NaT4QpbOIpS3B_GiSqEt44Io3BR_VTjXyoGL5H7o5Emi4XKhojzK_Bzcnz9XNnQ3egGXNQZtD3HfpyPMzQsBK0H1ixBs4D-slfLlY/s1600/create-app-p.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYqXIatGgIfnpzwaXBPWxxZcazgMl-Vd1W_3CbT3NaT4QpbOIpS3B_GiSqEt44Io3BR_VTjXyoGL5H7o5Emi4XKhojzK_Bzcnz9XNnQ3egGXNQZtD3HfpyPMzQsBK0H1ixBs4D-slfLlY/s640/create-app-p.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Each Application creation will create a git repository for you with skeleton Maven project.Edit the Maven project to include your changes and push to git repository.App Factory will build your project and deploy to development cloud using Jenkins.</div>
<div style="text-align: left;">
Press goto buid server button in build tab to go to App FactoryJenkins CI. </div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjtpOc_NeP6OgJ_hXv124U-Jg_lUMrB22zfQAymd77oIH032pX2Oe3ayvZ53vAXE0ny_dYJSQyrWx-i3nFJ4jXQsQKufvqEE-85bBHJKPyxE0_lbqpvZ47wTkWLhaZGbP1dC4AWRIaU1TU/s1600/goto-builder.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjtpOc_NeP6OgJ_hXv124U-Jg_lUMrB22zfQAymd77oIH032pX2Oe3ayvZ53vAXE0ny_dYJSQyrWx-i3nFJ4jXQsQKufvqEE-85bBHJKPyxE0_lbqpvZ47wTkWLhaZGbP1dC4AWRIaU1TU/s640/goto-builder.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Use same username and password to login into Jenkins CI. </div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhruPMXi7VR_H0_tX6fjVaSytsMO356mYeehF2Ps2nIIO6zeG6ZvGWURKP921obk62o15anmh_tUEdfnbqdM9GuXmF-SBh9_y1Q3lVMF5qMpDn_3NWnxwx_C7b7hnHV82QIqH3GGSjAPuI/s1600/build-server.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhruPMXi7VR_H0_tX6fjVaSytsMO356mYeehF2Ps2nIIO6zeG6ZvGWURKP921obk62o15anmh_tUEdfnbqdM9GuXmF-SBh9_y1Q3lVMF5qMpDn_3NWnxwx_C7b7hnHV82QIqH3GGSjAPuI/s640/build-server.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
To manually tricker a build use build button in builds page.</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhzxlH1mHvvxhQXXYVuT8n_TcXkwTUFOpVmNtCPEvz95GAh3V_XcASwBcHW16Ex1SOa_0V4Oi1wUEl8XTYPykpU7_FyM5tssfGBHaHAnL3uV5VkPUve6W7UgOiErkVErk04FsWqKncNacs/s1600/manula-build.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhzxlH1mHvvxhQXXYVuT8n_TcXkwTUFOpVmNtCPEvz95GAh3V_XcASwBcHW16Ex1SOa_0V4Oi1wUEl8XTYPykpU7_FyM5tssfGBHaHAnL3uV5VkPUve6W7UgOiErkVErk04FsWqKncNacs/s640/manula-build.png" width="640" /></a></div>
<br />
Observe notification panel to know the build status if you do not want to go to Jenkins. <br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj3KWDv0ImQijBBPV-vqZbCDt7s11QRUmE_-XZ-3lWBxr-E4waqRQN2vuJaYEPqsH2_15MYtB-kXH86i62bTGGtOFjDW7RXAAY1ifacSGrcV6Lfa5nLNUemX0GeT6OSSzbFAbgqvrRcR74/s1600/notifications.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="320" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj3KWDv0ImQijBBPV-vqZbCDt7s11QRUmE_-XZ-3lWBxr-E4waqRQN2vuJaYEPqsH2_15MYtB-kXH86i62bTGGtOFjDW7RXAAY1ifacSGrcV6Lfa5nLNUemX0GeT6OSSzbFAbgqvrRcR74/s320/notifications.png" width="183" /></a></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
</div>
<div style="text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div style="text-align: left;">
Go to repository tab to create new versions of application. </div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhlKGWIb5aJ8KCWg2LqZKur3bFpgo7JDo53KSKadw8liHpush9rDrtDiIlSQgrpObkoi5pUOtMwWcSUsNptMhEHaVAa6uHibpTmwXyNoI2OnmE6NJW4XFytXC5k2q4ZgfZHSu829oR3Fwk/s1600/versions.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhlKGWIb5aJ8KCWg2LqZKur3bFpgo7JDo53KSKadw8liHpush9rDrtDiIlSQgrpObkoi5pUOtMwWcSUsNptMhEHaVAa6uHibpTmwXyNoI2OnmE6NJW4XFytXC5k2q4ZgfZHSu829oR3Fwk/s640/versions.png" width="640" /></a></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Manage your application versions through various stage in governance tab.</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgciizMgLhsBlACw_RuIKy8hmNLifqf2LkNlNxynIF7TX4LctBPIauiTPFfxhJcJgr6bzpbcl2fGwy_VeufqTiOkTsxdroQUr9_HyF65GjpSURwI9CGt4XjLVjpQnX2iWbqwyzd6dEhr94/s1600/gov-page.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgciizMgLhsBlACw_RuIKy8hmNLifqf2LkNlNxynIF7TX4LctBPIauiTPFfxhJcJgr6bzpbcl2fGwy_VeufqTiOkTsxdroQUr9_HyF65GjpSURwI9CGt4XjLVjpQnX2iWbqwyzd6dEhr94/s640/gov-page.png" width="640" /></a></div>
<br />
Download logs of your applications in various stages(dev,test,staging and prod) in same tab.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiVYv9cyTNnylDsGeRg4KU8CHrg3L9CgpDl6lQRFJvVMkzfOYibJL24EBSptIB0P2CrHICkd6xm8iiyZ1qLbD_Nx2DzG80B8p3WR-ek5qW95-YEbFBBEDxPbY-U9nGEO7SfsKb4nj81P3g/s1600/logs.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="219" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiVYv9cyTNnylDsGeRg4KU8CHrg3L9CgpDl6lQRFJvVMkzfOYibJL24EBSptIB0P2CrHICkd6xm8iiyZ1qLbD_Nx2DzG80B8p3WR-ek5qW95-YEbFBBEDxPbY-U9nGEO7SfsKb4nj81P3g/s640/logs.png" width="640" /></a></div>
<br />
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Invite new users to other registered users through user administration tab</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1BE93jDGlb-ka6GoAZRB7JkvBdxJdlUkH7O9_tIAaoiqRkzInvhsJc_AahU2S8XpgK0Ae1JT13L5NYFYk1-wAQ10ZpeKuKKw3gAZAnuNo6soVWeRCDoqYlRjzjmXHFoTlFnQLdYiHl24/s1600/useradmin.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1BE93jDGlb-ka6GoAZRB7JkvBdxJdlUkH7O9_tIAaoiqRkzInvhsJc_AahU2S8XpgK0Ae1JT13L5NYFYk1-wAQ10ZpeKuKKw3gAZAnuNo6soVWeRCDoqYlRjzjmXHFoTlFnQLdYiHl24/s640/useradmin.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Manage your issues in Redmine.</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjFEsG03yg6eSP9izhPoyRQeYimBcgZK_cvhfirGgst15G9YsEnYQZsROpYqM6P_FL-_DnU9r2JgdBFvjL7ghlQAPmh3YkJMtifaLhyqbcAOGWvxL7zIDBkT0VerZX4WntPSvEQfaYKuqo/s1600/redmine.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjFEsG03yg6eSP9izhPoyRQeYimBcgZK_cvhfirGgst15G9YsEnYQZsROpYqM6P_FL-_DnU9r2JgdBFvjL7ghlQAPmh3YkJMtifaLhyqbcAOGWvxL7zIDBkT0VerZX4WntPSvEQfaYKuqo/s640/redmine.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Create new databases and associate those with data sources in configure resource tab.</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-d1DyuYfuMyF2LdGQJw0qAw24IR4ShEbWLwOi2g4pHMrLetbG3RkckfNZSHzKqTg9g6E6F_TGXGpb8WSFqQjJOz6LIpP-upgYO2MjqhEyB2hNr3aQbvHerGqwqHBpuWp90w9yrOTUazc/s1600/res-page.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-d1DyuYfuMyF2LdGQJw0qAw24IR4ShEbWLwOi2g4pHMrLetbG3RkckfNZSHzKqTg9g6E6F_TGXGpb8WSFqQjJOz6LIpP-upgYO2MjqhEyB2hNr3aQbvHerGqwqHBpuWp90w9yrOTUazc/s640/res-page.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Subscribe to APIs or create new APIs using WSO2 API Manager and use those in your application.</div>
<div style="text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhzc5S9Mz-g13koM7XOrVUM85fOUtgXR1b2l7GgW9m37ms_FmNlC6VjFpUJq7VlS9-dcsbK1m8rM2mRmknfbBljjfusB05GMrRAdzW_WpyQpfkJxnmXWPxWcPmN01B-_f4W_CW6zN2Dmoo/s1600/api.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhzc5S9Mz-g13koM7XOrVUM85fOUtgXR1b2l7GgW9m37ms_FmNlC6VjFpUJq7VlS9-dcsbK1m8rM2mRmknfbBljjfusB05GMrRAdzW_WpyQpfkJxnmXWPxWcPmN01B-_f4W_CW6zN2Dmoo/s640/api.png" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Create new properties as a resource in WSO2 Governance registry and use that in your application.</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Note that in all case you will get complete isolation between resources across different stages.</div>
<div style="text-align: left;">
Play with preview and report any issues or new features in <a href="https://wso2.org/jira/browse/APPFAC">https://wso2.org/jira/browse/APPFAC</a></div>
</div>
B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com0tag:blogger.com,1999:blog-7441265778508843993.post-22841340905679182042012-12-23T07:12:00.001-08:002012-12-23T07:21:30.420-08:00WSO2 App Factory v1.0.0 M8<div dir="ltr" style="text-align: left;" trbidi="on">
Recently <a href="http://wso2.com/solutions/app-factory/" target="_blank">WSO2 App Factory</a> team released their 8th mile stone[<a href="http://mail.wso2.org/mailarchive/architecture/2012-July/009161.html" target="_blank">Release mail</a>]. This may be the pre alpha release.You can down load preconfigured VM from <a href="http://wso2.com/solutions/app-factory/" target="_blank">here</a>.<br />
Lets look at the new features of this release briefly.<br />
<br />
1. Now users can create applications either with svn or git repository:In the VM a Apache server based svn deployment and <a href="http://gitblit.com/" target="_blank">Gitblit</a> based git deployments are available .User can select preferred repository type while creating application.The Jenkins job also will be configured automatically according to users' selected repository type.<br />
<br />
2.Integration of Human Task:While user submit registration from we can configure App Factory to fire a human task to get approval from an admin.This feature is valuable in the environment where strict approval process is needed. Refer <a href="http://thiliniishaka.blogspot.com/2012/12/approval-based-user-registration.html" target="_blank">this</a> blog post for further information. <br />
<br />
3.New Gadgets:There are two new gadgets to view application event stream and search applications.<br />
<br />
4.Log download:There is a way to download logs from build ui. App Factory uses WSO2 Stratos logging frame work to collect and display logs.With this release log download links is provided.<br />
<br />
5.Improved Build and Deploy model:Ability to tag a build is provided and the default artefact storage is moved into Jenkins side.There is a REST api is exposed from the Jenkis to deploy a built artifact to a server.All the Jenkins plugins are merged into one "appfactory-plugin" and fixed some problem while deploying Jenkins in master slave mode.<br />
<br />
Ok ,now the time to look at some new features that may come with next(probably Alpha) release.<br />
<br />
*Integration with GitHub :There will be Github based repository provider.<br />
*Artifact deployment with WSO2 Stratos 2 : Final Artifact deployment model will be with WSO2 Appserver Cartridge cluster.WSO2 recently released <a href="http://osdir.com/ml/carbon-wso2-architecture/2012-12/msg00168.html" target="_blank">Stratos Alpha</a>,this is a completely different cloud Linux lxc container based architecture.<br />
*And more..<br />
That's all for now ,Wait for next release...<br />
<br />
<br />
<span style="-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: white; color: #222222; display: inline !important; float: none; font-family: arial, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"></span></div>
B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com2tag:blogger.com,1999:blog-7441265778508843993.post-3533541815979068632012-09-08T09:29:00.000-07:002012-09-08T09:29:17.749-07:00Creating SVN Repository Remotely<div dir="ltr" style="text-align: left;" trbidi="on">
Linux distribution of <a href="http://subversion.apache.org/packages.html" target="_blank">Apache subversion</a> provides <i>svnadmin</i> to create a svn repository.But this is not capable of creating repository remotely.By issuing <i>svnadmin</i> command we can only create a repository within local file system.<br />
Here i am going to describe coup<span style="font-size: small;">le of way</span>s by which we can create svn repositories remotely.Here all my ways achieve above mentioned objective through java.Here is the list of method that i found.<br />
<br />
1.Using ssh to execute <i>svnadmin</i> command remotely.<br />
a)Using <a href="http://mina.apache.org/sshd/" target="_blank">apache sshd</a> library<br />
b)Using <a href="http://www.jcraft.com/jsch/" target="_blank">JSch</a> library<br />
2.Using<a href="https://bitbucket.org/sdorra/scm-manager/wiki/Home" target="_blank"> SCM -Manager</a><br />
3.Using PHP+java Client<br />
<h3 style="text-align: left;">
<span style="font-size: small;">Using ssh to execute <i>svnadmin</i> command remotely</span></h3>
<span style="font-size: large;"><span style="font-size: small;">In this approach the repository is created by executing <i>svnadmin</i> or relevant command in remote host using ssh.Here there are two ssh opensource libraries available for java.</span></span><br />
<h4 style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;">a) </span></span>Using apache sshd library</h4>
<span style="font-size: large;"><span style="font-size: small;"><a href="http://mina.apache.org/sshd/" target="_blank">apache sshd</a> is a pure java implementation of ssh available under apache 2.0 license.This is a sub-project of apache Mina.Here is a example code for executing <i>svnadmin</i> command on remote host as a superuser.</span></span><br />
<br />
<script src="https://gist.github.com/3674764.js?file=gistfile1.java"></script>To use apache sshd library you have to add following maven dependency. <br />
<script src="https://gist.github.com/3674802.js"> </script>
<br />
<br />
<h4 style="text-align: left;">
b)Using JSch library</h4>
This is another popular java implementation of ssh.<a href="http://www.jcraft.com/jsch/examples/" target="_blank">There are good examples</a> also available for this libarary.Here is how to execute <i>svnadmin</i> command using JSch library.<br />
<script src="https://gist.github.com/3674841.js"> </script>
Following is the maven dependency which can be used to create maven project.<br />
<h3 style="text-align: left;">
<script src="https://gist.github.com/3674858.js"> </script>
<span style="font-size: small;">Using SCM -Manager</span></h3>
Next approach is using a source code management system.<a href="https://bitbucket.org/sdorra/scm-manager/wiki/Home" target="_blank">SCM Manager</a> is an open source source code management system which is implemented in java.This is<br />
a server which provide user interface to create repository and manage them with users.Currently it support svn ,git and mercurial.In addition to user interface, it expose REST API to manage repositories.Here i am going to use the <a href="http://docs.scm-manager.org/restdocs/current/" target="_blank">REST API</a> to create a repository.Before staring writing the REST Client Download the SCM Manager from <a href="https://bitbucket.org/sdorra/scm-manager/wiki/download" target="_blank">here</a> and start the server by executing the script which can be found in bin folder of the distribution.<br />
To write the REST client there so many ways.<br />
1.<a href="http://www.mkyong.com/webservices/jax-rs/restful-java-client-with-apache-httpclient/" target="_blank">Using HTTP client</a><br />
2.<a href="https://cwiki.apache.org/WINK/61-getting-started-with-apache-wink-client.html" target="_blank">Apache Wink client</a><br />
3.<a href="http://www.mkyong.com/webservices/jax-rs/restful-java-client-with-jersey-client/" target="_blank">Jersey Client</a><br />
I am using http client wich is very simple to use.All the REST calls are protected by BASIC Auth in SCM Manager.We have to set the credential in http client.<br />
<script src="https://gist.github.com/3676153.js"> </script>Here i used Axiom for generating XML payload.<br />
<br />
<h3 style="text-align: left;">
<span style="font-size: small;">Using PHP+java Client</span></h3>
<span style="font-size: large;"><span style="font-size: small;">In this approach a php page that is hosted in apache 2 server in remote host will create a svn repository using <i>svnadmin</i> command and there will be a java client that is used to call the php.The php page is secured using Basic Auth.Here is the very simple php code to create svn repository.</span></span><br />
<br />
<script src="https://gist.github.com/3676253.js"> </script>
<span style="font-size: large;"><span style="font-size: small;">Here is the java client that is used to call the php page.</span></span><br />
<script src="https://gist.github.com/3676363.js"> </script>
<span style="font-size: large;"><span style="font-size: small;"> </span></span><br />
<span style="font-size: large;"><span style="font-size: small;">This is how we can create svn repositories remotely.This will be helpful when ever there is a requirement of automatic repository provisioning.</span></span><br />
<span style="font-size: large;"><span style="font-size: small;"> </span> </span></div>
B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com0tag:blogger.com,1999:blog-7441265778508843993.post-76461459692257049152012-06-28T19:26:00.000-07:002012-07-12T20:41:35.495-07:00Getting Started with WSO2 Appfactory VMware Image<div dir="ltr" style="text-align: left;" trbidi="on">
In this post i am going to describe how to getting started with WSO2 Appfactory VMware image first mile stone release.<br />
<h3 style="text-align: left;">
WSO2 Appfactory </h3>
WSO2 Appfactory is a new solution that provides a convenient environment to manage Applications between different stages of development.For example each application developed in enterprise goes through so many stages (such as dev and QA)before going to live.While it is moving between stage it goes through so many reviews(such as security review and policy review) by different users and authorities.WSO2 Appfactory provides a convenient and easy to use environment to manage application between different stages.For more information on WSO2 Appfactory refer following <a href="http://blog.cobia.net/cobiacomm/2012/04/16/what-is-wso2-appfactory/">blog</a>.<br />
<h3 style="text-align: left;">
WSO2 Appfactory VMware Image(M1 release)</h3>
WSO2 Appfactory team recently released their first appfactory milestone release as a VMware image.The image has following servers <br />
1.WSO2 Appfactory<br />
2.WSO2 Stratos Manager<br />
3.WSO2 Application server (for each stage(dev and live))<br />
4.SCM manager<br />
All the servers are connected to a single LDAP and a remote governance registry<br />
Following diagram shows the deployment pattern that the image uses.<br />
<br />
<img height="372" src="http://www.gliffy.com/pubdoc/3698634/L.png" width="640" />
Now lets play with this image.<br />
<h3 style="text-align: left;">
Prerequisites</h3>
1)VMware player should be installed in 64 bit machine with visualization enabled. <br />
2)The host machine should have at least 4 GB memory and connected to Internet.<br />
<h3 style="text-align: left;">
Getting Started with vm</h3>
1)Download the image from <a href="http://builder1.us1.wso2.org/%7Eappfactory/releases/wso2appfactory-image-m1.zip">http://builder1.us1.wso2.org/~appfactory/releases/wso2appfactory-image-m1.zip</a><br />
2)Unzip the downloaded file.<br />
3)Start the VMware player.<br />
4)Open the image as following<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgrsyuAoWeasWjfYS3jHhEccBepC5N6jqT1_eWbtlDm31bobEwRcb1KRQDV9TW8KgE2UtOTsl8D9SC-Xdw_HfdOi0dLj7pKlxsmyOoO0USxY74bfqnIOwr1KWvfEMhVVGFoy_eQ6usPOmk/s1600/open-image-1.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="339" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgrsyuAoWeasWjfYS3jHhEccBepC5N6jqT1_eWbtlDm31bobEwRcb1KRQDV9TW8KgE2UtOTsl8D9SC-Xdw_HfdOi0dLj7pKlxsmyOoO0USxY74bfqnIOwr1KWvfEMhVVGFoy_eQ6usPOmk/s640/open-image-1.png" width="640" /> </a></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhT5ohkJ3Y_l7nXz421IGnxIJrdAfFVdJ-tJr_QEcqgolUND82o1u_avzcr7TnlYFjhPkFU2bC8LAsXdrI0V3cShc59czH0frcAZCO0DDLv6-mc7k645IjoV4eezlAE5ckSVnSH9sWpZBU/s1600/open-image-2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="214" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhT5ohkJ3Y_l7nXz421IGnxIJrdAfFVdJ-tJr_QEcqgolUND82o1u_avzcr7TnlYFjhPkFU2bC8LAsXdrI0V3cShc59czH0frcAZCO0DDLv6-mc7k645IjoV4eezlAE5ckSVnSH9sWpZBU/s320/open-image-2.png" width="320" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
</div>
<br />
<br />
5)Edit the image setting as follow<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1lzIl34YcfmWfVNNAACGIYYCcD8stJd7LSNSxCPyEYyh2kbWFK9bYLRIaLrj3wZIQAL3g-Dutgv8R7rfV8gDnFGJHnoBJUZzUQFUWPQkCgGOEssuTKNS4GE_cxigpKSGWq935y2ZmIAY/s1600/edit-vm-setting.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="339" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1lzIl34YcfmWfVNNAACGIYYCcD8stJd7LSNSxCPyEYyh2kbWFK9bYLRIaLrj3wZIQAL3g-Dutgv8R7rfV8gDnFGJHnoBJUZzUQFUWPQkCgGOEssuTKNS4GE_cxigpKSGWq935y2ZmIAY/s640/edit-vm-setting.png" width="640" /></a></div>
<br />
Increase the memory to at least 2 GB(Recommended ~8GB) and enable bridge network setting. <br />
6)Start the image<br />
<div class="separator" style="clear: both; text-align: center;">
</div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjnOSPTngDcT6D7x8zvN9GoiM569FtJAjLoNCgFQrbcJpCVD8uBSzER1EsHs0tIuU_r6Iy1QmD_uwAehtCOKTSuEtA-uombfWNTMBbvbXcRo-5Irl7sGiKS3XG2pcqTgSPEI-gejDRYrCs/s1600/start-vm-1.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjnOSPTngDcT6D7x8zvN9GoiM569FtJAjLoNCgFQrbcJpCVD8uBSzER1EsHs0tIuU_r6Iy1QmD_uwAehtCOKTSuEtA-uombfWNTMBbvbXcRo-5Irl7sGiKS3XG2pcqTgSPEI-gejDRYrCs/s640/start-vm-1.png" width="640" /> </a></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjtTIGAaQOWHmHjONv9L20744L1COhoPzdcWQNAlilqaHPgZ-fndPju7XI7eDTkEw-xWbYxX0WvPYdlGaiQT2UsmyXRf01xPLRG0Jrt3dQefMOs1zi31KYwN406SAK5TUN66x3oysvr4AA/s1600/start-vm-2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="339" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjtTIGAaQOWHmHjONv9L20744L1COhoPzdcWQNAlilqaHPgZ-fndPju7XI7eDTkEw-xWbYxX0WvPYdlGaiQT2UsmyXRf01xPLRG0Jrt3dQefMOs1zi31KYwN406SAK5TUN66x3oysvr4AA/s640/start-vm-2.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<br />
use following credentials to login to the image.<br />
User-name: appfactory<br />
Password: appfactory<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguoDBegAsIwskzpvTxknOAXol0T9PGXPjwINO5Ublnpby4R1fuT7bG-ym8foTGS69JuSI6lTNXHGVGFVSjTc489oIWVi0ctzMGYZxbb1XGQ97yr5NswcHiF97yXuERMClK_lKQMdk2yb0/s1600/login-vm-1.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="339" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguoDBegAsIwskzpvTxknOAXol0T9PGXPjwINO5Ublnpby4R1fuT7bG-ym8foTGS69JuSI6lTNXHGVGFVSjTc489oIWVi0ctzMGYZxbb1XGQ97yr5NswcHiF97yXuERMClK_lKQMdk2yb0/s640/login-vm-1.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<br />
Note:<br />
1.Change the /etc/hosts entry of vm.svn.appfactory.wso2.com to<br />
0.0.0.0 vm.svn.appfactory.wso2.com<br />
2.Change keystore location of scm manager.<br />
Open the carbon-auth.xml that can be found in /home/appfactory/final-zip/scm-server/repository/config.<br />
Change
the keystore location to
/home/appfactory/final-zip/appfactory/wso2appfactory-1.0.0-SNAPSHOT/repository/resources/security/wso2carbon.jks<br />
<br />
7)Start all the servers as back-end process.<br />
Start Appfactory<br />
cd /home/appfactory/final-zip/appfactory/wso2appfactory-1.0.0-SNAPSHOT/bin<br />
nohup ./wso2server.sh & <br />
Start Stratos Manager<br />
cd /home/appfactory/final-zip/cloud-manager/wso2stratos-manager-2.0.0-SNAPSHOT/bin<br />
nohup ./wso2server.sh & <br />
Start Dev cloud Application server<br />
cd /home/appfactory/final-zip/dev-cloud/wso2as-5.0.0-SNAPSHOT/bin <br />
nohup ./wso2server.sh & <br />
Start Live cloud Application server<br />
cd /home/appfactory/final-zip/live-cloud/wso2as-5.0.0-SNAPSHOT/bin <br />
nohup ./wso2server.sh & <br />
Start SCM Manager<br />
cd /home/appfactory/final-zip/scm-server/bin <br />
./scm-server start<br />
8) Get IP address of the VM and enter following to /etc/hosts of the host.<br />
In VM issue sudo ifconfig and get the IP.<br />
<br />
172.16.9.130 vm.appfactory.wso2.com<br />
172.16.9.130 vm.cloudmanager.appfactory.wso2.com<br />
172.16.9.130 vm.dev-cloud.appserver.wso2.com<br />
172.16.9.130 vm.live-cloud.appserver.wso2.com<br />
172.16.9.130 vm.svn.appfactory.wso2.com<br />
<br />
Add above entries to /etc/hosts of host machine.Here change the IP address as you got in previous step.<br />
Wait for some time to start all the servers success fully then you can access the servers using following link in <b><u>host machine browser</u></b>. <br />
Access Appfactory<a href="https://vm.appfactory.wso2.com:9443/appmgt/"> https://vm.appfactory.wso2.com:9443/appmgt/</a><br />
Access Dev cloud Application server <a href="https://vm.appfactory.wso2.com:9443/appmgt/">https://vm.dev-cloud.appserver.wso2.com:9445/</a><br />
Access Live cloud Application server <a href="https://vm.appfactory.wso2.com:9443/appmgt/">https://vm.live-cloud.appserver.wso2.com:9446/</a><br />
<h3 style="text-align: left;">
Getting started with Appfactory</h3>
Now it is the time to create a application and deploy it to cloud.<br />
1.Register a new user<br />
1.Access <a href="https://vm.appfactory.wso2.com:9443/appmgt/">https://vm.appfactory.wso2.com:9443/appmgt/</a><br />
2.Register a user by clicking sign up button at left top of the sign in page as follow.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZzKPi1uqD5-yPaF3uUFC-qjA6m8gsovdavupB5pwhJJswOezsycZoL04B-Pes1Z9db_wJKrg5c7ChjfHAwnPA-4huatSy33M43NEnttl6wd90IG1NTLOTVwF-ksG3EtHYwftYOo-HAPw/s1600/sign-up.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="105" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZzKPi1uqD5-yPaF3uUFC-qjA6m8gsovdavupB5pwhJJswOezsycZoL04B-Pes1Z9db_wJKrg5c7ChjfHAwnPA-4huatSy33M43NEnttl6wd90IG1NTLOTVwF-ksG3EtHYwftYOo-HAPw/s640/sign-up.jpg" width="640" /> </a></div>
<div class="separator" style="clear: both; text-align: left;">
Fill the sign up form </div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgk5WoV3EGuHna3iugHgPmy2mU3CcLCCzGrBn70_DxzpQcsH2AOuRSUrDnWqkPrX65eigOMoak5AtDQjrTVWBvIPF2yfSaRhaZEV2iWKNPAW13YqC7maSm4lLGZdztQrnyD7ndpKJkh1WU/s1600/sign-up-user.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgk5WoV3EGuHna3iugHgPmy2mU3CcLCCzGrBn70_DxzpQcsH2AOuRSUrDnWqkPrX65eigOMoak5AtDQjrTVWBvIPF2yfSaRhaZEV2iWKNPAW13YqC7maSm4lLGZdztQrnyD7ndpKJkh1WU/s640/sign-up-user.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<br />
Check your mail and click the link sent by mail to validate the email address. <br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjj1DiWwPM-mgkqAgaZb34AWh2rMQ9SEbeHBD0CVCSGcHzXc1hdXl_O6eyd79hr3-3cc5VLkCg6UmRWjRKbsjI-hSVcOWQvt0DkAJMv4dllGwMiV1AmAmbSULR5lWxpwPn3nw4FUjP1SPw/s1600/sign-up-mail-validate.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="108" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjj1DiWwPM-mgkqAgaZb34AWh2rMQ9SEbeHBD0CVCSGcHzXc1hdXl_O6eyd79hr3-3cc5VLkCg6UmRWjRKbsjI-hSVcOWQvt0DkAJMv4dllGwMiV1AmAmbSULR5lWxpwPn3nw4FUjP1SPw/s640/sign-up-mail-validate.jpg" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<br />
<br />
2.Create an App<br />
Login as created user<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjiyW03sgx1pkbLl-987NyrkcMW_1A2nFO7PYo4TSsQZ-joRSTYDsGCgXx3i51USlp_5RC2tZKMkEy_Po8-a5M-OTRltdWv6Q1eUUNbKxP9tURyunZm3bQPMySLsjcgSajDYBDd0LfPhKQ/s1600/sign-in.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjiyW03sgx1pkbLl-987NyrkcMW_1A2nFO7PYo4TSsQZ-joRSTYDsGCgXx3i51USlp_5RC2tZKMkEy_Po8-a5M-OTRltdWv6Q1eUUNbKxP9tURyunZm3bQPMySLsjcgSajDYBDd0LfPhKQ/s640/sign-in.png" width="640" /> </a></div>
<div class="separator" style="clear: both; text-align: left;">
By clicking add apps create new app</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibanLUsQF-2AuYJndeGyc7ZSh2fGksG8pxwT7CZccCBgnNsxw2uUeANApQ6GnUH4oMJ26TijOAzxPESLnLdTLH4rH0U4eRkO2Yn7Bxqher0HAdE4bSM0nCNAZtHAifvRVEelB0M8D8fjA/s1600/create-app.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibanLUsQF-2AuYJndeGyc7ZSh2fGksG8pxwT7CZccCBgnNsxw2uUeANApQ6GnUH4oMJ26TijOAzxPESLnLdTLH4rH0U4eRkO2Yn7Bxqher0HAdE4bSM0nCNAZtHAifvRVEelB0M8D8fjA/s640/create-app.png" width="640" /> </a></div>
<div class="separator" style="clear: both; text-align: left;">
After successful creation of application it will display the created SVN url. </div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-PHZ24fKoPD9ex2mEKUaS8MrncALoNfinHXjX6PsG7cOBLLo4iFO0KvhqG85rfMw3qhm9MA8cbgaMc0-3UWHZ40EDF85xtf4CSKVMKCRt6idIgQLu0YpZWbp9TvYqEwKyrM3KMmjzTic/s1600/create-app-success.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-PHZ24fKoPD9ex2mEKUaS8MrncALoNfinHXjX6PsG7cOBLLo4iFO0KvhqG85rfMw3qhm9MA8cbgaMc0-3UWHZ40EDF85xtf4CSKVMKCRt6idIgQLu0YpZWbp9TvYqEwKyrM3KMmjzTic/s640/create-app-success.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
When ever user login he always see the list of applications with short details</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJNs6yRgcFMjkS1FzYyNrRRcfqLvF7qcvzcEXAfE2uDB5EiMlF4NKYenef9oQ1CIT7AkkG0RvCdcj9HFPLQCTe1sP4q8TQyf8BU_OBrtww1su2yi1wFQZGphho0L-eULehwjKRZWMPWKY/s1600/app-list.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJNs6yRgcFMjkS1FzYyNrRRcfqLvF7qcvzcEXAfE2uDB5EiMlF4NKYenef9oQ1CIT7AkkG0RvCdcj9HFPLQCTe1sP4q8TQyf8BU_OBrtww1su2yi1wFQZGphho0L-eULehwjKRZWMPWKY/s640/app-list.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
When the user click on a app depending on the role of the user he will see different dashboards.</div>
<div class="separator" style="clear: both; text-align: left;">
All the member can view the dev-view as follow.</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjnJxn9d7_5_PgNIdNeBoJ354jyG5JucIRtCWbgHGSxPnvUbffC6yhUXyEDhyphenhyphen3Rt3IekJ0Qrbln6s_lZxrgJyNKVqXVKTVMx-BmC-0oRCAosU5DFPFpjngNC0J2SWN9Y1Iek8ekBTlbwSI/s1600/dev-view.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjnJxn9d7_5_PgNIdNeBoJ354jyG5JucIRtCWbgHGSxPnvUbffC6yhUXyEDhyphenhyphen3Rt3IekJ0Qrbln6s_lZxrgJyNKVqXVKTVMx-BmC-0oRCAosU5DFPFpjngNC0J2SWN9Y1Iek8ekBTlbwSI/s640/dev-view.png" width="640" /> </a></div>
<div class="separator" style="clear: both; text-align: left;">
The users in admin role can view admin view.The admin user can invite already registered users to application.</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiDG0TdU-dQYoMQZ971NQ3zGMLO52Yz3qWH_HuSHvEE91H2flaYB9f2RtZM4D0n9yAsnuMAng8zdxZDhi7KbS_2T_oQqQX3qArgajmKJIkIrSDTX8bDi869UKNdwnGrvDkUd9rHrP6cObE/s1600/admin-view.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiDG0TdU-dQYoMQZ971NQ3zGMLO52Yz3qWH_HuSHvEE91H2flaYB9f2RtZM4D0n9yAsnuMAng8zdxZDhi7KbS_2T_oQqQX3qArgajmKJIkIrSDTX8bDi869UKNdwnGrvDkUd9rHrP6cObE/s640/admin-view.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: left;">
The user in devOps role can view devOps view.Here he can deploy the application to stages(dev or live).</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYdEihc-ZYUjgjJ3vSBNr_o7GYDaJgL5xVKom2mmmOnwpMrcx4QGbZIgNHp1dt2jiXcKRTY2V_AqxKUn0YDzNAl_cfoUQKAv0ubsPmbW2MVTkZcbsepQ6lPOF9jmtB22QBHLHBL9FvEkU/s1600/dev-ops-view.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="340" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYdEihc-ZYUjgjJ3vSBNr_o7GYDaJgL5xVKom2mmmOnwpMrcx4QGbZIgNHp1dt2jiXcKRTY2V_AqxKUn0YDzNAl_cfoUQKAv0ubsPmbW2MVTkZcbsepQ6lPOF9jmtB22QBHLHBL9FvEkU/s640/dev-ops-view.png" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<br />
3.Invite a user as a developer<br />
Register a new user.<br />
Invite him as a developer to created project.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiNLItjQZeiy-lwKINwQa6R2T3CbXE7NgdJJwvxz8zSZNc7xHZ_wHpMfk5SGgeWJC6qouoZxRWd4Vs87Eu4AoDEaMtAlaBMXFbOGexUzudx8c2h2_t7AorcOd6dUMC1M-J8H_wVT2evADc/s1600/invite-user.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="339" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiNLItjQZeiy-lwKINwQa6R2T3CbXE7NgdJJwvxz8zSZNc7xHZ_wHpMfk5SGgeWJC6qouoZxRWd4Vs87Eu4AoDEaMtAlaBMXFbOGexUzudx8c2h2_t7AorcOd6dUMC1M-J8H_wVT2evADc/s640/invite-user.png" width="640" /></a></div>
<br />
4.Invite a user as devOps<br />
Same way invite another user to devOps role. <br />
5.Commit a CAR project into svn as developer<br />
Check out the svn repository displayed on dev-view as developer.<br />
<div class="separator" style="clear: both; text-align: left;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisxEVLi6oxuDy1PIFfY4qgyytaWH4rLl7xeci7hyphenhyphenPp-aBKZI1ojvMyq9UEnyEZwEbnkOylOEC0dnksv84rD-Y0hbskJiKVhEt_ci5DjfmmoiKuYAOvglwsJeoPyK92Fv6-UjOUy86L6Ls/s1600/checkout-edited.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="88" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisxEVLi6oxuDy1PIFfY4qgyytaWH4rLl7xeci7hyphenhyphenPp-aBKZI1ojvMyq9UEnyEZwEbnkOylOEC0dnksv84rD-Y0hbskJiKVhEt_ci5DjfmmoiKuYAOvglwsJeoPyK92Fv6-UjOUy86L6Ls/s640/checkout-edited.jpg" width="640" /> </a>Add a car project to the checkout directory(use following <a href="https://svn.wso2.org/repos/wso2/people/ajanthan/AppFactoryTestProject/">car project</a>) </div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhrrbMkncrfUOcRWalSahAdSpR0Rz0pKX45_91U-wx6Qm6WQ0jCCqpPCTaeqAnyUB-ec_NK-lGhd0EUkZlk67FPdtEj5ih5thlOBSaNBUw2wyTLyxIxTC5WFdQSqW8c-7DNaNVhb0SQOHo/s1600/add--car.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="392" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhrrbMkncrfUOcRWalSahAdSpR0Rz0pKX45_91U-wx6Qm6WQ0jCCqpPCTaeqAnyUB-ec_NK-lGhd0EUkZlk67FPdtEj5ih5thlOBSaNBUw2wyTLyxIxTC5WFdQSqW8c-7DNaNVhb0SQOHo/s640/add--car.jpg" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
Commit the project</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhgFTJxmtyPAB_SR5x2LXdBtI7uiQSCdz-arAMyDLXmrUCjVVOiiZ8dIdyznJHyq7mCDeqzcFaV_4_zH5SKu510XfNASW0sUDhjgzAvhyXCIuHgqHlElbLJ_54s1JtTpM3R2tR6L7pcbjA/s1600/commit-edited.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="385" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhgFTJxmtyPAB_SR5x2LXdBtI7uiQSCdz-arAMyDLXmrUCjVVOiiZ8dIdyznJHyq7mCDeqzcFaV_4_zH5SKu510XfNASW0sUDhjgzAvhyXCIuHgqHlElbLJ_54s1JtTpM3R2tR6L7pcbjA/s640/commit-edited.jpg" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<br />
6.Login as devOps and you can<br />
-deploy to dev<br />
-deploy to live in dev-ops view.<br />
<br />
7.Then finally you can check the relevant application server in cloud for the deployed application.<br />
Login to https://vm.appfactory.wso2.com:9443/appmgt/<br />
as the user who created application using user name as {user-name}@{application-id} and check the deployed car applications.<br />
<br />
<br />
<div style="text-align: left;">
Thats all for milestone one release.I hope wso2 appfactory will come with more functionality with less distribution size in future releases.</div>
</div>B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com2tag:blogger.com,1999:blog-7441265778508843993.post-56772255967529695272011-08-01T08:14:00.000-07:002011-08-01T08:14:48.876-07:00GSOC2011 In Action<div dir="ltr" style="text-align: left;" trbidi="on"><div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.youtube.com/embed/iYhV8Ysv638?feature=player_embedded' frameborder='0'></iframe></div><br />
</div>B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com0tag:blogger.com,1999:blog-7441265778508843993.post-32145302812743152712011-05-08T08:50:00.000-07:002011-05-08T08:52:05.053-07:00GSOC 2011:Weekly Report(May-01 to May-08)<div dir="ltr" style="text-align: left;" trbidi="on"><div style="text-align: justify;">Last week as i planned before i spent on time designing UI mock-ups and database tables.The good thing is that the designing process was a collaborative work of my both mentors and myself.They have given constructive feedback on the design and finally helped me to come up with the final design.I have updated my design details on wiki <a href="https://wiki.openmrs.org/display/projects/Enabling+SMART+Apps+in+OpenMRS">page</a>.While designing i am able to realize some insight into theories of database design as well as UI design.</div><br />
<b><u><span style="font-size: large;">UI Design</span></u></b><br />
I identified that there are four sets of UI should be designed.<br />
<br />
<u><b><span style="font-size: small;">Main UI:</span></b></u><br />
<div style="text-align: justify;"><span style="font-size: small;">This is the place where the list of available apps are displayed on the side bar and the user is allowed to launch the app within a HTML iframe by clicking on the icon of the app.This is an usual UI every SMART container may contain.Here my job was to identify the best place to put this UI in the OpenMRS.The place should be appropriate to display patient level health data because every SMART UI app is a patient level application.With the help of my mentor i decided to put this UI at patient dashboard where the access to the dashboard is allowed only after selecting a patient.There the patient object can be received which is necessary to create a record in SMART container helper methods.</span></div><table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjC_FJyNGt1WJgm3wKr5q843uKrJH9dbDL-90f_2EFgzeyfmuhPuA_1gZRDSkTeH9SMTAsZgm8fFPa4N4g3u5aBOsPPCbOT-1whCE8jKfzZX97q-zlIrRdc4qU4OhTuF-C4wkU2GfgXWj4/s1600/mockup_main-ui.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" height="289" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjC_FJyNGt1WJgm3wKr5q843uKrJH9dbDL-90f_2EFgzeyfmuhPuA_1gZRDSkTeH9SMTAsZgm8fFPa4N4g3u5aBOsPPCbOT-1whCE8jKfzZX97q-zlIrRdc4qU4OhTuF-C4wkU2GfgXWj4/s640/mockup_main-ui.png" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Main UI</td></tr>
</tbody></table><br />
<u><b><span style="font-size: small;"><br />
</span></b></u><br />
<u><b>Manage Apps at user level UI:</b></u><br />
<div style="text-align: justify;"><span style="font-size: small;">In medical world there are range of peoples who need different types of applications.For example the doctor uses application that related to diagnosis process but this type of applications are not relevant to a patient.So it is better to provide a UI for user to customize the available application at main UI.It is usual to put all the user level setting under My Profile in OpenMRS.According to the normal convention i decided to put the UI for managing SMART apps at user level in a vertical tab under the My Profile page.</span></div><table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiWWBU1yS4XzQguvD-IqMYc7QWm8C-5Bv2PeydwZmUlNWevtPIdCyix5DbDd9nnYZpdyh-yMb-h-dy5uKMoo1Pfcuf05ZDWcThWJ-uydXHBSJrfDYpt2VC0b7GdXe3CKftsqBYVq4jkBxA/s1600/mockup_manage_ui%25281%2529.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" height="323" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiWWBU1yS4XzQguvD-IqMYc7QWm8C-5Bv2PeydwZmUlNWevtPIdCyix5DbDd9nnYZpdyh-yMb-h-dy5uKMoo1Pfcuf05ZDWcThWJ-uydXHBSJrfDYpt2VC0b7GdXe3CKftsqBYVq4jkBxA/s640/mockup_manage_ui%25281%2529.png" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Manage Apps at user level</td></tr>
</tbody></table><br />
<b><u>manage Apps at seystem level(system wide settings) UI: </u></b><br />
<div style="text-align: justify;"><span style="font-size: small;">Normally it is a convention to allow only administrator to install new modules in OpenMRS.This rule is appropriate for SMART apps also.As SMART mentor Josh said i decided to put the add or remove SMART app UI at admin page.</span></div><table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiooDExdA8mLca1vXiXrwLMygNLlwbV1nPuu19D82ODmzS1mmzyojX7odal3a6e86lUGYJynkx4eRvq5v6daH1DCJmFdh9LpP70kwhszwH_pBf2j_KQ8j_l0wLVLEvx_FpyTrV1VesnWCw/s1600/mockup_system-wide-apps-manage-UI.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" height="360" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiooDExdA8mLca1vXiXrwLMygNLlwbV1nPuu19D82ODmzS1mmzyojX7odal3a6e86lUGYJynkx4eRvq5v6daH1DCJmFdh9LpP70kwhszwH_pBf2j_KQ8j_l0wLVLEvx_FpyTrV1VesnWCw/s640/mockup_system-wide-apps-manage-UI.png" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Manage app (add/remove)</td></tr>
</tbody></table><br />
<u><b>UI for installing the Apps:</b></u><br />
<span style="font-size: small;">When the user clicks on the add button on the manage app at admin page, a pop up widow will be displayed.This window will allow user to upload a SMART app manifest or to provide a link to the manifest file. </span><br />
<table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjY260ZUTZRiSjdgyQTXEV7VIPhJ5_i5dyTcnxTe7pXGpQDNG4EtS38MbZXRpzuIOsP8Ejp6EsLveE0KKIW27zUqOTAHnx3AFSMyPMA5Q8vyeLldz_mTImTxlBucyLh1PBpx2GLwk5oLs8/s1600/mockup_upload_ui.png" imageanchor="1" style="clear: left; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img border="0" height="306" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjY260ZUTZRiSjdgyQTXEV7VIPhJ5_i5dyTcnxTe7pXGpQDNG4EtS38MbZXRpzuIOsP8Ejp6EsLveE0KKIW27zUqOTAHnx3AFSMyPMA5Q8vyeLldz_mTImTxlBucyLh1PBpx2GLwk5oLs8/s640/mockup_upload_ui.png" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Add App UI</td></tr>
</tbody></table><u><b><span style="font-size: large;">Database Design</span></b></u><br />
<div style="text-align: justify;"><span style="font-size: small;">Here the primary data are information about users and the SMART apps.OpenMRS alredy has a user table.The new table should be created for modeling SMART apps.SMART app uses a manifest file to save the information about itself.It is straight forward that there are one to one relationship between app database table and the manifest file.In other words database table is used to save informations in the manifest file.I directly modeled database table using manifest file as a guide and created obvious relationships.</span></div><table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: left; margin-right: 1em; text-align: left;"><tbody>
<tr><td style="text-align: center;"><img border="0" height="242" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg0vgqm9rPCA5A9NIhA5zdZhDQdskagSYnr4hANbQ7rbZl-rS3rovubiHBgwvjTAu4lkSPXY_gI7gzUerWIsAydanGabkMouHNKqGVsyS5yj-iCtreEHbeRj9OieQ1ZXe_jHaW7BB5BS-Q/s640/datbase.png" style="margin-left: auto; margin-right: auto;" width="640" /></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Final Database Table(the user table should contains more field,it can be found <a href="http://wiki.openmrs.org/download/attachments/589829/Openmrs_data_model_1.6.png">here</a>)</td></tr>
</tbody></table><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg0vgqm9rPCA5A9NIhA5zdZhDQdskagSYnr4hANbQ7rbZl-rS3rovubiHBgwvjTAu4lkSPXY_gI7gzUerWIsAydanGabkMouHNKqGVsyS5yj-iCtreEHbeRj9OieQ1ZXe_jHaW7BB5BS-Q/s1600/datbase.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"> </a> </div><br />
</div>B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com1tag:blogger.com,1999:blog-7441265778508843993.post-49091579949274562832011-05-01T20:27:00.000-07:002011-05-01T20:27:55.813-07:00Google Summer Code 2011<div dir="ltr" style="text-align: left;" trbidi="on"><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhlr8FVOA_0qMIUkTj4RI8Gaa8TIRWj5VEyRAYwdVoq6QZAk6lNppJsHrdNnQq1UzaDk6R3NM50xLuqbK9r9d5gZ26feswCi0iw8G4UBWUMuifOkuj_KHZb66FIxsiT45AIEx-fquFHNXc/s1600/GSOC2011.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhlr8FVOA_0qMIUkTj4RI8Gaa8TIRWj5VEyRAYwdVoq6QZAk6lNppJsHrdNnQq1UzaDk6R3NM50xLuqbK9r9d5gZ26feswCi0iw8G4UBWUMuifOkuj_KHZb66FIxsiT45AIEx-fquFHNXc/s1600/GSOC2011.jpg" /></a></div><br />
<div class="separator" style="clear: both; text-align: center;"></div><br />
I got selected<a href="http://code.google.com/soc/"> Google Summer Code 2011</a> this time.I am very proud to be one of the thousand students who are selected this time for this project.I submitted only one proposal to <a href="http://openmrs.org/about/">OpenMRS</a> early as possible and i got good response from the mentors.So i got confident and avoid to submit any more proposals.<br />
<span class="Apple-style-span" style="font-size: large;"><b><u><br />
</u></b></span><br />
<span class="Apple-style-span" style="font-size: large;"><b><u>OpenMRS</u></b></span><br />
<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhKKDuSnfW2YDjIyiphn-XDM5aMF-rbQLZmmlx8jghJaIO3XCI3UnImrSvvT-472u1l6IlsYsR2Y9KDrM4qyYDrjwUXBibBSEAJte8SPGZY-aADvna-LDFPpt2SX2WEUfyyG3TY5jWVpao/s1600/openmrs.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="79" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhKKDuSnfW2YDjIyiphn-XDM5aMF-rbQLZmmlx8jghJaIO3XCI3UnImrSvvT-472u1l6IlsYsR2Y9KDrM4qyYDrjwUXBibBSEAJte8SPGZY-aADvna-LDFPpt2SX2WEUfyyG3TY5jWVpao/s320/openmrs.jpg" width="320" /></a></div><span class="Apple-style-span" style="font-size: large;"><b><u><br />
</u></b></span><br />
OpenMRS is a web based open source enterprise medical recording system completely written using J2EE technology.It is used all over the world specially in developing world where the healthcare is facing resource constraints.<br />
While i was searching on how can i improve my coding skill i realized that contributing an open source project is the best way.I selected couple of organizations including OpenMRS.As time goes i was very comfortable with OpenMRS because they are very active community throughout the year and they have very good system to assist new comers.After joining the community i solved couple of tickets and developed a module called<a href="http://wiki.openmrs.org/display/docs/Cleaning+Voided+Module"> CleaningVoided</a>.During this time my learning curve was very sharply rising.<br />
As Google announced the GSOC program ,i decided to participate in the program and prepared a good proposal for idea "<a href="http://wiki.openmrs.org/display/projects/Enabling+SMART+Apps+in+OpenMRS">Enabling Smart Apps in OpenMRS</a> ".Finaly i got<a href="http://openmrs.org/blog/2011/04/25/meet-our-summer-of-code-2011-students/"> selected </a>and got a chance to contribute community further.Now i specially thanking the community for their valuable help they provided me to achive this.By the way this is only staring point ,in my view the success of this program is achieved at the end of the program when the people are using my code.<br />
The proposal i submitted can be found <a href="http://www.google-melange.com/gsoc/proposal/review/google/gsoc2011/aja/1">here</a>.<br />
"<span class="Apple-style-span" style="font-family: Arial, 'Helvetica Neue', Helvetica, sans-serif; line-height: 18px;"><strong style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 16px; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;">Write Code. Save Lives"</strong></span><br />
</div>B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com1tag:blogger.com,1999:blog-7441265778508843993.post-81450269648442354032011-01-26T04:12:00.000-08:002011-01-26T04:26:28.354-08:00Maven: Easy Build Tool Part I<div dir="ltr" style="text-align: left;" trbidi="on"><blockquote><div style="text-align: center;"><div style="text-align: center;">Here I am going to post series of small posts about maven.</div></div></blockquote><div class="separator" style="clear: both; text-align: center;"><a href="http://t1.gstatic.com/images?q=tbn:ANd9GcQf_vueVLULv9NbfSUHhG1nuKxrwqANS22V43qdsTZFYb6MDLwh" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://t1.gstatic.com/images?q=tbn:ANd9GcQf_vueVLULv9NbfSUHhG1nuKxrwqANS22V43qdsTZFYb6MDLwh" /></a></div><br />
<b><u><span class="Apple-style-span" style="font-size: large;">Introduction</span></u></b><br />
<div style="text-align: justify;"><a href="http://maven.apache.org/index.html">Maven</a> is a project of Apache foundation which ease the software building process.Now this is the famous project management software widely adapted across the software world.The understanding of the philosophy of the maven and familiarity with this software is essential requirement for programmers.If i tell what is maven in one sentence,maven consists of project object model (pom) ,set of standard template ,project life cycle ,a dependency management system and a logic for executing plugin goals during desired phase of the life cycle .The above feature are constructed as a module on the top of core software this is why each lifestyle event can be customized by plugins.</div><span class="Apple-style-span" style="font-size: large;"><b><u>Project Object Model(pom.xml)</u></b></span><br />
<div style="text-align: justify;">This is a XML file representing project setting.When we run the maven in a particular directory the maven scans the directory for this file and do the set up according this file.So it is mandatory for every maven project.Here the overview of the pom.xml file.</div><blockquote><span class="Apple-style-span" style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 14px;"></span><br />
<pre style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><span class="Apple-style-span" style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 14px;"><project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<!-- The Basics -->
<groupId>...</groupId>
<artifactId>...</artifactId>
<version>...</version>
<packaging>...</packaging>
<dependencies>...</dependencies>
<parent>...</parent>
<dependencyManagement>...</dependencyManagement>
<modules>...</modules>
<properties>...</properties>
<!-- Build Settings -->
<build>...</build>
<reporting>...</reporting>
<!-- More Project Information -->
<name>...</name>
<description>...</description>
<url>...</url>
<inceptionYear>...</inceptionYear>
<licenses>...</licenses>
<organization>...</organization>
<developers>...</developers>
<contributors>...</contributors>
<!-- Environment Settings -->
<issueManagement>...</issueManagement>
<ciManagement>...</ciManagement>
<mailingLists>...</mailingLists>
<scm>...</scm>
<prerequisites>...</prerequisites>
<repositories>...</repositories>
<pluginRepositories>...</pluginRepositories>
<distributionManagement>...</distributionManagement>
<profiles>...</profiles>
</project></span></pre></blockquote><span class="Apple-style-span" style="font-size: large;"><u><b>Maven Coordinates</b></u></span><br />
<div style="text-align: justify;">Maven Coordinates is an identifier of the maven project which uniquely represents a maven project.This is used to locate the project artifact when the maven search for the project dependency in local repository.</div><div><blockquote><div id="codewrap5" style="font-family: Arial, Helvetica, sans-serif; font-size: 12px; line-height: 20px;"><pre style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><code style="font-size: small; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"><project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.aja.javaexamples</groupId>
<artifactId>springIOCExample</artifactId>
<packaging>war</packaging>
<version>1.0-SNAPSHOT</version>
<name>Spring IOC Example</name>
</project></code>
</pre><div><br />
</div></div></blockquote><div style="text-align: left;">project descried by above minimal POM is located as <span class="Apple-style-span" style="font-family: monospace; font-size: 12px;">$M2_REPO/com/aja</span><span class="Apple-style-span" style="font-family: monospace; font-size: x-small; line-height: 20px; white-space: pre;">javaexamples</span><span class="Apple-style-span" style="font-family: monospace; font-size: x-small; line-height: 20px; white-space: pre;">/</span><span class="Apple-style-span" style="font-family: monospace; font-size: x-small; line-height: 20px; white-space: pre;">springIOCExampl</span></div><div style="text-align: justify;"><span class="Apple-style-span">Usually the groubId represent the company for which the project belongs to and the artifactId uniquely represent the project with in the company .Version is a series number dictate the progress of the project.The package indicates the for example weather it is jar or war project.</span></div><div style="text-align: center;">Rest of the things will be covered in next post.</div>References:<br />
<br />
<ol style="text-align: left;"><li><a href="http://www.javaworld.com/javaworld/jw-12-2005/jw-1205-maven.html?page=1">http://www.javaworld.com/javaworld/jw-12-2005/jw-1205-maven.html?page=1</a></li>
<li><a href="http://maven.apache.org/pom.html">http://maven.apache.org/pom.html</a></li>
</ol><br />
<span class="Apple-style-span" style="font-size: large;"><b><u><br />
</u></b></span><br />
<br />
<span class="Apple-style-span" style="font-size: large;"><b><u><br />
</u></b></span></div></div>B.Ajanthanhttp://www.blogger.com/profile/06316182728422132991noreply@blogger.com0