The basic purpose of this page is to cover question (and only questions) on all the core concepts and key areas, which all Java/J2EE developers, designers and architects should be conversant with to perform well in their current jobs and to launch a successful career by doing well at interviews. The interviewer can also use this book to make sure that they hire the right candidate depending on their requirements.
Multi-Threading
- What language features are available to allow shared access to data in a multi-threading environment? (Hint: Synchronized block,Synchronized method,wait, notify)
- What is the difference between synchronized method and synchronized block? (Hint:Block on subset of data. Smaller code segment).
- What Java language features would you use to implement a producer (one thread) and a consumer (another thread) passing data via a stack? (Hint: wait, notify)
Java language
- What Java classes are provided for date manipulation? (Hint:Calendar, Date)
- What is the difference between String and StringBuffer? (Hint: mutable, efficient)
- How do you ensure a class is Serializable? (Hint:Implement Serializable)
- What is the difference between static and instance field of a class? (Hint:Per class vs. Per Object)
- What methods do you need to implement to store a class in Hashtable or HashMap? (Hint: hashCode(), equals()) .
- How do you exclude a field of a class from serialization? (Hint: transient)
Inheritance
- What is the difference between an Interface and an abstract base class? (Hint: interface inheritance, implementation inheritance.)
- What does overriding a method mean? (Hint: Inheritance)
- What about overloading? (Hint: different signature)
Memory
- What is the Java heap, and what is the stack? (Hint: dynamic, program thread execution.)
- Why does garbage collection occur and when can it occur? (Hint: To recover memory, as heap gets full.)
- If I have a circular reference of objects, but I no longer reference any of them from any executing thread, will these cause garbage collection problems? (Hint: no)
Exceptions
- What is the problem or benefits of catching or throwing type “java.lang.Exception”? (Hint: Hides all subsequent exceptions.)
- What is the difference between a runtime exception and a checked exception? (Hint: Must catch or throw checked exceptions.)
JSP
- What is the best practice regarding the use of scriptlets in JSP pages? Why? (Hint: Avoid)How can you avoid scriptlet code? (Hint:custom tags, Java beans)
- What do you understand by the term JSP compilation? (Hint: compiles to servlet code)
Servlets
- What does Servlet API provide to store user data between requests? (Hint: HttpSession)
- What is the difference between forwarding a request and redirecting? (Hint: redirect return to browser )
- What object do you use to forward a request? (Hint: RequestDispatcher)
- What do you need to be concerned about with storing data in a servlet instance fields? (Hint: Multi-threaded.)
- What’s the requirement on data stored in HttpSession in a clustered (distributable) environment? (Hint: Serializable)
- If I store an object in session, then change its state, is the state replicated to distributed Session? (Hint: No, only on setAttribute() call.)
- How does URL-pattern for servlet work in the web.xml? (Hint: /ddd/* or *.jsp)
- What is a filter, and how does it work? (Hint: Before/after request, chain.)
JDBC
- What form of statement would you use to include user-supplied values? (Hint: PreparedStatement)
- Why might a preparedStatement be more efficient than a statement? (Hint: Execution plan cache.)
- How would you prevent an SQL injection attack in JDBC? (Hint: PreparsedStatement )
- What is the performance impact of testing against NULL in WHERE clause on Oracle? (Hint: Full table scan. )
- List advantages and disadvantages in using stored procedures? (Hint: Pro: integration with existing dbase, reduced network trafficCon: not portable, mutliple language knowledge required )
- What is the difference between sql.Date, sql.Time, and sql.Timestamp? (Hint: Date only, time only, date and time )
- If you had a missing int value how do you indicate this to PreparedStatement? (Hint: setNull(pos, TYPE))
- How can I perform multiple inserts in one database interaction? (Hint: executeBatch)Given this problem: Program reads 100,000 rows, converts to Java class in list, then converts list to XML file using reflection. Runs out of program memory. How would you fix? (Hint: Read one row at time, limit select, allocate more heap (result set = cursor) )
- How might you model object inheritance in database tables? (Hint: Table per hierarchy, table per class, table per concrete class)
JNDI
- What are typical uses for the JNDI API within an enterprise application? (Hint: Resource management, LDAP access)
- Explain the difference between a lookup of these “java:comp/env/ejb/MyBean” and “ejb/MyBean”? (Hint: logical mapping performed for java:comp/env )
- What is the difference between new InitialContext() from servlet or from an EJB? (Hint: Different JNDI environments initialized EJB controller by ejb-jar.xml, servlet by web.xml.)
- What is an LDAP server used for in an enterprise environment? (Hint: authentication, authorization)
- What is authentication, and authorization? (Hint: Confirming identity, confirming access rights )
EJB
- What is the difference between Stateless and Stateful session beans (used?) (Hint: Stateful holds per client state )
- What is the difference between Session bean and Entity bean (when used?) (Hint: Entity used for persistence )
- With Stateless Session bean pooling, when would a container typically take a instance from the pool and when would it return it? (Hint: for each business method )
- What is the difference between “Required”, “Supports”, “RequiresNew” “NotSupported”, “Mandatory”, “Never”? (Hint: Needs transaction, existing OK but doesn’t need, must start new one, suspends transaction, must already be started, error if transaction)
- What is “pass-by-reference” and “pass-by-value”, and how does it affect J2EE applications? (Hint: Reference to actual object versus copy of object. RMI pass by value.)
- What EJB patterns, best practices are you aware of? Describe at least two? (Hint: Façade, delegate, value list, DAO, value object).
- Describe some issues/concerns you have with the J2EE specification? (Hint: Get their general opinion of J2EE)
- What do you understand by the term “offline optimistic locking” or long-lived business transaction? How might you implement this using EJB? (Hint: version number, date, field comparisons.)
- Explain performance difference between getting a list of summary information (e.g. customer list) via finder using a BMP entity vs. Session using DAO? (Hint: BMP: n+1 database reads, n RMI calls.)
- What is meant by a coarse-grained and a fine-grained interface? (Hint: Amount of data transferred per method call)
XML/XSLT
- What is the difference between a DOM parser and a SAX parser? (Hint: DOM: reads entire model, SAX: event published during parsing.)
- What is the difference between DTD and XML Schema? (Hint: level of detail, Schema is in XML.)
- What does the JAXP API do for you? (Hint: Parser independence. )What is XSLT and how can it be used? (Hint: XML transformation. )
- What would be the XPath to select any element called table with the class attribute of info? (Hint: Table[@class=’info’])
JMS
- How can asynchronous events be managed in J2EE? (Hint: JMS)
- How do transactions affect the onMessage() handling of a MDB? (Hint: Taking off queue. )
- If you send a JMS message from an EJB, and transaction rollback, will message be sent? (Hint: yes)
- How do you indicate what topic or queue MDB should react to? (Hint: deployment descriptor )
- What is the difference between a topic and a queue? (Hint: broadcast, single)
SOAP
- What is a Web service, and how does it relate to SOAP? (Hint: SOAP is the protocol.)
- What is a common transport for SOAP messages? (Hint: HTTP )
- What is WSDL? How would you use a WSDL file? (Hint: XML description of Web Service: interface and how to bind to it. )
- With new J2EE SOAP support what is: JAXR, JAX-RPC, and SAAJ? (Hint: registry, rpc, attachments)
Security
- Where can container level security be applied in J2EE application? (Hint: Web Uri’s, EJB methods)
- How can the current user be obtained in a J2EE application (Web and Enterprise)? (Hint: getUserPrincipal, getCallerPrincipal )
- How can you perform role checks in a J2EE application (Web and enterprise)? (Hint: IsUserInRole(), IsCallerInRole() )
Design
- Name some types of UML diagrams? (Hint: class, sequence, activity, use case)
- Describe some types of relationships can you show on class diagrams? (Hint: generalization, aggregation, uses)
- What is the difference between association, aggregation, and generalization? (Hint: Relationship, ownership, inheritance)
- What is a sequence diagram used to display? ( Hint: Object instance interactions via operations/signals)What design patterns do you use. Describe one you have used (not singleton)? (Hint: e.g. Builder, Factory, Visitor, Chain of Command )
- Describe the observer pattern and an example of how it would be used (Hint: e.g. event notification when model changes to view )
- What are Use Cases? (Hint: Define interaction between actors and the system )What is your understanding of encapsulation? (Hint: Encapsulate data and behavior within class )
- What is your understanding of polymorphism? (Hint: Class hierarchy, runtime determine instance )
Process
- Have you heard of or used test-driven development? (Hint: e.g. XP process )
- What development processes have you followed in the past? (Hint: Rational, XP, waterfall )
- How do you approach capturing client requirements? (Hint: Numbered requirements, use cases )
- What process steps would you include between the capture of requirements and when coding begins? (Hint: Architecture, Design, UML modeling, etc )
- How would you go about solving performance issue in an application? (Hint: Set goals, establish bench, profile application, make changes one at a time )
- What developer based testing are you familiar with (before system testing?) (Hint: Unit test discussion )
- How might you test a business system exposed via a Web interface? (Hint: Automated script emulating browser)
- What is your experience with iterative development? (Hint: Multiple iteration before release)
Distributed Application
- Explain a typical architecture of a business system exposed via Web interface? (Hint: Explain tiers (presentation, enterprise, resource) Java technology used in each tiers, hardware distribution of Web servers, application server, database server )
- Describe what tiers you might use in a typical large scale (> 200 concurrent users) application and the responsibilities of each tier (where would validation, presentation, business logic, persistence occur). (Hint: Another way of asking same question as above if their answer wasn’t specific enough)
- Describe what you understand by being able to “scale” an application? How does a J2EE environment aid scaling? (Hint: Vertical and Horizontal scaling. Thread management, clustering, split tiers )
- What are some security issues in Internet based applications? (Hint: authentication, authorization, data encryption, denial service, xss attacks, SQL injection attacks )
General
- What configuration management are you familiar with? (Hint: e.g. CVS, ClearCase )
- What issue/tracking process have you followed? (Hint: Want details on bug recording and resolution process).
- What are some key factors to working well within a team? (Hint: Gets a view on how you would work within interviewer’s environment.)
- What attributes do you assess when considering a new job? (what makes it a good one)? (Hint: Insight into what motivates you.)
- What was the last computing magazine you read? Last computing book?
- What is a regular online magazine/reference you use? (Hint: Understand how up to date you keep yourself.)
I simply wanted to write down a quick word to say thanks to you for those wonderful tips and hints you are showing on this site.
ReplyDeleteJava Training in Bangalore|
• I simply wanted to thank you so much again. I am not sure the things that I might have gone through without the type of hints revealed by you regarding that situation"Devops Training in Bangalore"
ReplyDeletehttp://app.cocolog-nifty.com
ReplyDeleteTry your luck with BGAOC and get your winnings. excellent gambling machines Challenge and win.
ReplyDeleteGood Blog!!! The way you have conveyed your blog is more impressive...
ReplyDeleteJAVA Training in Chennai
Java training institute in chennai
Java classes in chennai
Best JAVA Training institute in Chennai
Java Training
JAVA Training in Velachery
java training in Adyar
Python Training in Chennai
Software testing training in chennai
Selenium Training in Chennai
Nice blog!! I hope you will share more info like this. I will use this for my studies and research.
ReplyDeleteDevOps Training in Chennai
DevOps foundation certification
DevOps certification
AWS Training in Chennai
Cloud Computing Training in Chennai
Data Science Training in Chennai
DevOps Training in Anna Nagar
DevOps Training in Vadapalani
DevOps Training in Guindy
DevOps Training in Thiruvanmiyur
Nice post. Thanks for sharing this post with us.
ReplyDeleteSpoken English Classes in Chennai
Best Spoken English Classes in Chennai
IELTS Coaching in Chennai
IELTS Coaching Centre in Chennai
English Speaking Classes in Mumbai
English Speaking Course in Mumbai
IELTS Classes in Mumbai
IELTS Coaching in Mumbai
IELTS Coaching in Anna Nagar
Spoken English Class in Anna Nagar
Innovative blog thanks for sharing this inforamation.
ReplyDeleteBlockchain Training in Chennai
Blockchain courses in Chennai
french classes
German language training in chennai
TOEFL Coaching Centres in Chennai
Ionic Training in Chennai
Blockchain Training in Tambaram
Blockchain Training in Adyar
I am very happy to visit your blog. This is definitely helpful, eagerly waiting for more updates.
ReplyDeleteccna course in Chennai
ccna Training in Chennai
ccna Training institute in Chennai
AngularJS Training in Chennai
Ethical Hacking course in Chennai
PHP Training in Chennai
ccna Training in Tambaram
ccna Training in Velachery
CCNA course in Anna Nagar
Very valuable post...! This information shared is helpful to improve my knowledge skill. Thank you...!
ReplyDeleteOracle Training in Chennai
Oracle course in Chennai
Tableau Training in Chennai
Spark Training in Chennai
advanced Excel Training in Chennai
Primavera Training in Chennai
Appium Training in Chennai
Power BI Training in Chennai
Pega Training in Chennai
Oracle Training in T Nagar
Oracle Training in Porur
I have to agree with everything in this post. Thanks for useful sharing information.
ReplyDeletePHP Training in Chennai
PHP Training in bangalore
php training in coimbatore
PHP Course in Chennai
php Course in madurai
PHP Training Institute in Chennai
Best php training institute in chennai
salesforce course in bangalore
Great blog thanks for sharing Looking for the best creative agency to fuel new brand ideas? Adhuntt Media is not just a digital marketing company in chennai. We specialize in revamping your brand identity to drive in best traffic that converts.
ReplyDeletedigital marketing company in chennai
seo service in chennai
web designing company in chennai
social media marketing company in chennai
Nice blog thanks for sharing Wondering where to buy healthy garden plants in Chennai for your home? Karuna Nursery Gardens offers you with tons of variety and organic choices suitable for our tropical climate. Make your garden fabulous with Karuna Nursery.
ReplyDeleteplant nursery in chennai
rental plants in chennai
corporate gardening service in chennai
This is the first & best article to make me satisfied by presenting good content. I feel so happy and delighted. Thank you so much for this article.
ReplyDeleteLearn Best Digital Marketing Course in Chennai
Digital Marketing Course Training with Placement in Chennai
Best Big Data Course Training with Placement in Chennai
Big Data Analytics and Hadoop Course Training in Chennai
Best Data Science Course Training with Placement in Chennai
Data Science Online Certification Course Training in Chennai
Learn Best Android Development Course Training Institute in Chennai
Android Application Development Programming Course Training in Chennai
Learn Best AngularJS 4 Course Online Training and Placement Institute in Chennai
Learn Digital Marketing Course Training in Chennai
Digital Marketing Training with Placement Institute in Chennai
Learn Seo Course Training Institute in Chennai
Learn Social Media Marketing Training with Placement Institute in Chennai
Excellent blog the way of delivering the message of the blog is so good..
ReplyDeleteAWS Training in Chennai
AWS Training in Bangalore
AWS Training in Coimbatore
AWS Training in Hyderabad
AWS Training in BTM
AWS Training in Marathahalli
Best AWS Training in Marathahalli
AWS Course in Bangalore
DOT NET Training in Bangalore
PHP Training in Bangalore
I have been reading for the past two days about your blogs and topics, still on fetching! Wondering about your words on each line was massively effective.
ReplyDeletephp online training in chennai
php programming center in chennai
php class in chennnai
php certification course
php developer training institution chennai
php training in chennnai
php mysql course in chennai
php institute in chennnai
php course in chennnai
php training with placement in chennnai
php developer course
ReplyDeleteThis blog is really awesome. I learned lots of informations in your blog. Keep posting like this.
Selenium Training in Chennai
Selenium Training in Bangalore
Selenium Training in Coimbatore
Best Selenium Training in Bangalore
Selenium Training Institute in Bangalore
Selenium Classes in Bangalore
selenium training in marathahalli
Selenium training in Btm
Ielts coaching in bangalore
German classes in bangalore
This Blog is really informative!! keep update more about this...
ReplyDeleteAviation Academy in Chennai
Air Hostess Training in Chennai
Airport Management Courses in Chennai
Best Aviation Academy in Chennai
Ground Staff Training in Chennai
Air Hostess Academy in Chennai
Airport Management Training in Chennai
Airport Ground Staff Training Courses in Chennai
Great Article.In india day by day Unemployment is increasing fastly and everyone is now seeking for Govt Jobs . To know More About FreeJobAlert visit Sarkari Result website
ReplyDelete
ReplyDeleteGet the most advanced Hadoop Course by Professional expert. Just attend a FREE Demo session. good job
Ai & Artificial Intelligence Course in Chennai
PHP Training in Chennai
Ethical Hacking Course in Chennai Blue Prism Training in Chennai
UiPath Training in Chennai
very nice blogs!!! i have to learning for lot of information for this sites...Sharing for wonderful information.Thanks for sharing this valuable information to our vision. You have posted a trust worthy blog keep sharing.
ReplyDeleteWeb Designing Course Training in Chennai | Web Designing Course Training in annanagar | Web Designing Course Training in omr | Web Designing Course Training in porur | Web Designing Course Training in tambaram | Web Designing Course Training in velachery
I appreciate that you produced this wonderful article to help us get more knowledge about this topic.
ReplyDeleteI know, it is not an easy task to write such a big article in one day, I've tried that and I've failed. But, here you are, trying the big task and finishing it off and getting good comments and ratings.
IELTS Coaching in chennai
German Classes in Chennai
GRE Coaching Classes in Chennai
TOEFL Coaching in Chennai
spoken english classes in chennai | Communication training
I am glad to post a worthy article about the German Language Course and IELTS Coaching from KCR consultants, this may change your career growth and language skill.
ReplyDeleteKCR CONSULTANTS
KCR CONSULTANTS
I am browsing this website daily and get good facts from here all the time. Aw, this was a really nice post. kenya visa requirements read online & fill Kenyans can apply for their eVisa in about 15 minutes by filling and submitting the visa application form.
ReplyDeleteIt's very nice what you're sharing with your audience. I have read your article and I think it's very nice. You can apply for an Indian visa by clicking the link we just provided. Thanks for adding value to the post.
ReplyDeletesmm panel
ReplyDeletesmm panel
faturalı hatta kredi
faturalı hatta kredi
instagram takipçi satın al
binance komisyon indirimi
binance indirim kodu
instagram takipçi satın al
tiktok jeton hilesi
I love what you guys do too. Keep up the great work guys.. After 2 years, India resumes regular International flights, India resumes regular International flights , you can read all info through India e visa website.
ReplyDeleteMuch obliged for sharing this brilliant substance. its extremely fascinating. Numerous web journals I see these days don't actually give whatever pulls in others however the manner in which you have plainly clarified everything it's truly awesome. There are loads of posts But your method of Writing is so Good and Knowledgeable. continue to post such helpful data and view my site too...
ReplyDeletehow to make a paper airplane eagle | how to make a boomerang airplane | the eagle paper airplane | best paper airplane design for distance and accuracy | best paper airplanes for distance and speed | what is the best paper airplane design for distance | paper airplane that flies far and straight | nakamura lock paper airplane instructions | paper airplane templates for distance | science behind paper airplanes
bitcoin nasıl alınır
ReplyDeletetiktok jeton hilesi
youtube abone satın al
gate io güvenilir mi
referans kimliği nedir
tiktok takipçi satın al
bitcoin nasıl alınır
mobil ödeme bozdurma
mobil ödeme bozdurma
Hello sir, this is a very good blog.. Many people ask, How can I apply for an emergency visa to India? You can apply for your emergency India visa online, Online visa process secure & fast.
ReplyDeleteMMORPG
ReplyDeleteinstagram takipçi satın al
Tiktok jeton hilesi
tiktok jeton hilesi
antalya saç ekimi
INSTAGRAM TAKİPCİ
İNSTAGRAM TAKİPÇİ SATIN AL
metin2 pvp serverlar
instagram takipçi satın al
smm panel
ReplyDeletesmm panel
https://isilanlariblog.com/
İnstagram takipçi satın al
hirdavatciburada.com
beyazesyateknikservisi.com.tr
servis
tiktok jeton hilesi
It might maintain to come into the dispensation into it and prepare the music to run. It gives you full convenience for data from one records site. Rekordbox Dj License Key Generator
ReplyDeleteThe Internet has known us huge opportunities for being more organized, for socializing easily. This priceless threat data give us unbelievable insight into what’s occurrence at the present. Crack Malwarebytes
ReplyDeleteIt was a pleasure reading your article which is so useful and easy to grasp. Thanks for sharing this with us.Passengers seeking a e visa of Turkey can visit the Turkish visa website for more information.
ReplyDeleteHello reader, I hope you are well and good. I want to grab travelers' attention who wish to visit Turkey. Applying for an electronic visa Turkey is very easy with the help of an online process. You don’t need to go to the embassy. Online evisa process have save time and money.
ReplyDelete