Posts

Showing posts from December, 2013

Using JackRabbit with Web App

Problem: U R using tomcat and you need to store content(may be images). You do not want heavy lifting using liferay, hippo etc Solution: 1. prepare web app. 2  use Tomcat as web server 3. use apache Jack rabbit as content repository Configuration steps: 1.     Install Tomcat     download jack rabbit war file 2. Let port be 8080 for tomcat 3. Goto tomcatuser-xml file and make following entries <role rolename="manager-gui"/> <role rolename="manager-script"/> <role rolename="manager-jmx "/> <role rolename="manager-status "/> <role rolename="manager"/> <role rolename="admin"/> <user username="admin" password="admin" roles="admin,manager,manager-gui,manager-script,manager-jmx,manager-status"/> 4. Start Server & Go to tomcat home screen 5. Go to Manage app option 6. Enter credentials as #3 7. Deploy jack rabbit web ap

Web application Security mechanism

Hi, Authentication is prime and important part/phase of any web application. Decision has to be made based on the type you want. Three mechanism available to do so. 1. Agent base 2. Container based 3. Application based #1 you can use JAAS based mechanism to add agent based authentication in your web app. #2 Form based authentication is the famous container based authentication. remembered j_security_check action we use to write in action attribute of <form> tag. #3 This one is the pragmatic approach (as compare to #2 which is declarative), where developer starts getting the data from form and starts security mechanism i.e. custom. NOTE: You can try all the above with simple tomcat web server.

ORM framework learning - JPA

Tiered of using pure sql in your web app. here is the ORM framework which you can implement and ease your DB development. This blog is for JPA learning. What do u need? Eclipse (Kepler) Eclipse Link (Kepler) Any DB may be MySQL + mySQL driver at app side  #1 is the famous IDE #2 is the JPA implementation which does all the required ORM work steps: Create & design DB Use Eclipse to create JPA project Use DB explorer of eclipse to connect to DB Right Click on JPA proj to generate entities. Use client to test your entities and JPAQ. Integrate this JPA project into your Web App. as dependency