Ankur Srivastav

Ranch Hand
+ Follow
since Aug 31, 2009
Ankur likes ...
Eclipse IDE PHP Java
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Ankur Srivastav

Welcome S G Ganesh & Tushar Sharma,

I got this book last week and have started preparing for the certification. So far I liked your approach of providing FAQ's. Will post my reviews and questions as I make progress ..
Thanks Avinash, sorry for my late response. Frankly I had Head First for version 5 and that was primary reason for giving this exam. Will try to aim for version 7 next, hope by the time i decide to take that Head First arrives ..
7 years ago
I was able to pass this exam today and scored 85%. I thought of sharing the experience with those interested in taking the exam.

Why did I chose to give this exam

I had passed the SCJP 1.4 back in 2005 and since then lot has changed in Java. I was interested in revising all the concepts I had learned during that exam as well as start preparing for Java 7 certification. Certifications are challenging and help to get better grasp of fundamentals as well as to stay up to date. For Java 7 I dint wanted to go via the update route. So I decided to give OCA first.

Preparation

I referred to the study guide by Oracle (Edward Finegan and Robert Liguori). The book is not so great but it will help with the exam. I also referred to Herbert Schildt.

To get a good grasp of fundamentals you can refer to Head First Java for the topics required for this exam. Java 7 adds few additional topics like try with resources, multi catch etc. but they are few in numbers.

I took some practice test in last few days from Enthuware. Din't score that great in those tests but they can be helpful.

I am now looking to prepare for Java SE 7 programmer ii. Any suggestions will help.

All the best with your preparations.
7 years ago
Hi Kalin,

If you want to understand how web applications work and how you can create one using Servlets and JSP's I will recommend you to read Head First Servlets. Having said that let me try to answer your questions.

First of all if you plan to use Java technology to create your web application then you will need a good understanding of Servlet technology. A web application indeed does the tasks you rightly mentioned i.e. handle user requests, process it (which can involve database also ) and then provide response in the form of an HTML page. But then there are patterns also which help you to create a maintainable and scalable application.

Most of the features you are talking about are easily available out of the box by using a Portal solution like Liferay. Features like blogs, Wikis and Calendars for creating events are available out of box.

Give it a try at www.liferay.com Just download the CE version and run it.
7 years ago
Thanks Joey.

Yes now with Oracle, I had to pay again. They are not offering any packages.
8 years ago
I was able to pass the Java Enterprise Edition 5 Web Component Developer exam today. Just wanted to share my experience and some suggestions.

I would like to mention that I had taken this exam earlier also, couple of weeks back, but I dint pass at that time. So don't worry if you don't crack it. It will always help you in understanding the fundamentals better.

For those of you who want to know the benefits of taking this exam, here are a few which might help:

1. The preparation gives you a good knowledge about Servlets, JSP's, Filters and Patterns (pretty obvious .. ! ).
Most of us, including myself, just try to google the concepts whenever we are in the middle of a project and stuck with a problem.
With this you can still google but with a better understanding. If you are into Java and doing web application development you should consider taking this exam.
2. Servlets and JSP's form the basis of any web application development. Its quite important to have a good knowledge of these concepts. That helps you to pickup any MVC framework in no time. You get the knowledge of Tag Libs, Filters, Listeners to name a few.
3. I feel more confident in dealing with Tag Libraries and Expression Language syntax now. Something which I was never quite confortable with.
4. Take this even if you just want to test how much you know.

Now for preparation:

Head First Servlets and JSP's is the most awsome book you can find for preparation. I read and re read this book quite a few times.
I wish they come up soon with the EJB 3 one also.
And the mock exam at the end is pretty good. I dint score well in that. But don't worry in the exam you will know how many answers to choose.
I will also suggest that you try out the examples. I used to code everything from Servlet mappings to JSP tags. That will solidify what you learn.

That's all I did. The exam gives you plenty of time.

Also please share the next step you guys take once you pass this one. I am thinking about SCBCD.
8 years ago
From what I know applicationContext needs to be defined if you want to use Spring MVC. I am not quite sure what is the JavaConfig file which you have mentioned.
8 years ago
I have the following web.xml

--

<servlet-mapping>
<servlet-name>MainServlet</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>

<security-constraint>
<web-resource-collection>
<web-resource-name>Book</web-resource-name>
<url-pattern>/</url-pattern>
<!-- <http-method>GET</http-method> -->
</web-resource-collection>
<auth-constraint>
<role-name>AppAdmin</role-name>
<role-name>HRAdmin</role-name>
</auth-constraint>
</security-constraint>

<login-config>
<auth-method>FORM</auth-method>
<form-login-config>
<form-login-page>/WEB-INF/jsp/formlogin.jsp</form-login-page>
<form-error-page>/WEB-INF/jsp/formerror.jsp</form-error-page>
</form-login-config>
</login-config>

What I am trying to achieve is: For any request to this App like http://localhost:8083/servletbookapp/ the user should get authenticated. But that is not happening unless I specify some specific pattern like
<url-pattern>/test</url-pattern>

Kindly suggest if I should make any changes ...
8 years ago
I am just trying an example.. its not a real use case.
8 years ago
Yes it will.
8 years ago
Yes I am trying a single controller example and want everything routed via that servlet. Problem is it goes to that servlet without authenticating.
8 years ago
I have the following web.xml

--

<servlet-mapping>
<servlet-name>MainServlet</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>

<security-constraint>
<web-resource-collection>
<web-resource-name>Book</web-resource-name>
<url-pattern>/</url-pattern>
<!-- <http-method>GET</http-method> -->
</web-resource-collection>
<auth-constraint>
<role-name>AppAdmin</role-name>
<role-name>HRAdmin</role-name>
</auth-constraint>
</security-constraint>

<login-config>
<auth-method>FORM</auth-method>
<form-login-config>
<form-login-page>/WEB-INF/jsp/formlogin.jsp</form-login-page>
<form-error-page>/WEB-INF/jsp/formerror.jsp</form-error-page>
</form-login-config>
</login-config>

What I am trying to do is for any URL request to this App like http://localhost:8083/servletbookapp/ the user should get authenticated. But that is not happening unless I specify some specific pattern like
<url-pattern>/test</url-pattern>

Kindly suggest if I should make any changes ...
8 years ago
Has anyone been able to use the struts 286dispatcher Portlet class to handle events. Kindly share any specific configuration that you did.

When I try to process an event in a struts 2 application the namespace is coming as blank and the application throws an exception.
9 years ago
Are you still facing issue ? Can you put Exception trace ?
9 years ago
One simple observation by looking at the code, just want to make sure you have the if block

if(myResultSet.next())
myDataField1 = myResultSet.getString("acctno");
myDataField2 = myResultSet.getString("fname");
myDataField3 = myResultSet.getString("lname");
System.out.println(myDataField1+" "+myDataField2+" "+myDataField3);
System.out.print("TEST");

I dont see the braces in there ..
9 years ago