A cognitive description of Java interview knowledge

Source: Internet
Author: User
Tags connection pooling throw exception

Connection pooling: Simultaneously operate the connection database, create a connection pool, create 10,000 database links in the pool. Close the link according to the system operation. Peak links reach Max Max to queue up, and the expiration time for the link being used. There are several: Tomcat request server (Servers.xml/context.xml configuration), DBCP (Database connection poor), C3p0,java connection pool.

Index: Data lookup, but deletion modification efficiency is reduced

Table Update

Primary FOREIGN Key

where

Iterators: Map iterators, collection traversal loop output values, Iterator,items,var, are sequence object points. Come out (use Remove () before using. Next () or error)

Reference passing, value passing: value passing is a copy of the value, reference passing

Abstract class: After integration can not implement his abstract method, he is also draw blood, can only single inheritance, can not inherit more. When you want something else, and you can't integrate it, the new one

Deadlock: Database and Java deadlock: When executing a piece of resources, to assign a value, the thread does one thing 1. Implement interface runable,2. Inherit Thread,start start. 3. Use Executorservice, callable, and future to implement multithreading with return results. 1. Manually remove a deadlock thread,

Recursive thought: Fibonacci sequence, calling itself

Iterative Key,value: Provinces and cities corresponding to Put,get, voting with linklist, do class management with ArrayList

The difference between HashMap and Hashtable

Several sorts, quick sort: dichotomy, insert sort, quick sort (choose a benchmark that will be compared to the large number on one side and the smaller number on the other side.) The two sides of this number are recursively recursive to the above method)

Queue stacks: Queues-sequential queueing, FIFO. Stack: Advanced back out.

Sorting algorithms

Multi-threaded access to shared resources, synchronizing

Abstract methods

Inter-thread access

Null is the same as null: null value is no, NULL is a value, value is null

Regular expressions, how to match numbers: \^[1-9]\d*$

A char of 2 bytes

Common data structures, heap characteristics

Java garbage collection mechanism: gc,finalize System.GC Call

For example, the polymorphic fish new goldfish, carp out of the different, more than is not necessarily the interface may be the parent class

Those exceptions, the way of handling: try () catch handling, throw exception throw, throws declares the type of exception that a method may occur

Be proactive in your interview, prepare ahead of time, and not be smart

A cognitive description of Java interview knowledge

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.