Java face question ($)
1. Describe the banking business you are familiar with, the more detailed the better
Banking Experience: Mobile banking Online Banking Experience How to pay Transfer understand the basic business
2, understand the control of workflow, approval process and accounting processing?
How to implement workflow, approval process in Java, How does Java implement report function?
3, Java development Web has several development models? Which one do you know best?
A total of 23 development models:
In general, design patterns fall into three broad categories:
Create five types of models: Factory method mode, abstract Factory mode, singleton mode, builder mode, prototype mode.
Structure mode, a total of seven kinds: Adapter mode, adorner mode, proxy mode, appearance mode, bridging mode, combined mode, enjoy the meta-mode.
There are 11 types of behavioral Patterns: Strategy mode, template method mode, observer mode, iteration sub-mode, responsibility chain mode, Command mode, Memo mode, state mode, visitor mode, mediator mode, interpreter mode.
In fact, there are two types: concurrency mode and thread pool mode.
Most familiar: single-instance mode
Singleton Object ( Singleton) is a common design pattern. In Java applications, singleton objects guarantee that only one instance of the object exists in a JVM.
4. Describe some special functions what package do you think you should implement?
Java.util is the Java Utility Toolkit, which contains some use of tool classes, such as defining system features, using functions related to date calendars, and so on.
Java.lang is the language core language pack for Java, such as String, Math, Integer, System, Thread, which provides common functionality. The special point is that you do not need to import, it is the default import package.
Java.awt is Java's Abstractwindow Toolkit, an Abstraction window toolkit that contains multiple classes that make up the abstract window, which are used to build and manage the graphical user (GUI) of the application.
Java.applet is the necessary package for creating applets, and contains some of the classes required by the applet runtime.
Java.net is a Java-related network operation package.
Java.io is a package of Java input and output streams.
java.sql is a Java database operation package.
Javax.swing is the new bounded bread.
Java.applet supporting the structure of small applications
java.awt ability to provide graphical user interfaces
Java.awt.color supports color space and form factor
Java.awt.datatransfer exchanging data with the system's clipboard
JAVA.AWT.DND supports drag and pull operations
Java.awt.event Handling Events
Java.awt.font describe multiple font types
Java.awt.geom allows you to use geometric shapes
Java.awt.im allows you to edit the input of Japanese, Chinese, and Korean in the component
JAVA.AWT.IM.SPI supports two selected input devices (added in Java 2, v1.3) java.awt.image processing images
Java.awt.image.renderable supports standalone display of images
Java.awt.print support for general printing functions
Java.beans allows you to build software components
Java.beans.beancontext provides an executable environment for beans
java.io Input/Output data
Java.lang provides core functionality
Java.lang.ref enable to interact with garbage collection
Java.lang.reflect run-Time profiling code
Java.math processing large integers and decimal numbers
java.net Support Network functions
Java.rmi supports remote method invocation
Java.rmi.activation activating a Permanent object
JAVA.RMI.DGC managing distributed garbage collection
Java.rmi.registry mapping names to remote object references
Java.rmi.server supports remote method invocation
Java.security processing certificates, keys, abstracts, signatures and other security features
Java.security.acl managing access Control lists
Java.security.cert Analysis and management certificates
Java.security.interfaces defining interfaces for DSA (digital Signature algorithm)
Java.security.spec setting key and algorithm parameters
java.sql interacting with SQL (Structured Query language) databases
Java.text formatting, querying, and processing text
Java.util contains general tools
Java.util.jar generating and opening jar files
Java.util.zip read/write compressed or uncompressed files
5, General how to debug Java program?
(1) system.out.print () Output statement debugging
(2) Use Myeclipse/eclipse program debug debugging, set breakpoints, run the program, observe the invariant changes;
6, familiar with several publishing tools? How to publish all kinds?
Tomcat
Deployment method:
(1) Copy the Web project files directly into the WebApps directory
Tomcat's WebApps directory is the default app directory for Tomcat and will load all applications in this directory when the server is started. So the JSP program can be packaged into a war package placed in the directory, the server will automatically solve the war package, and in this directory to generate a folder with the same name. A war package is a jar package with an attribute format that compresses all the contents of a Web program.
WebApps This default application directory can also be changed. Open the Server.xml file under Tomcat's Conf directory to find the following:
Unpackwars= "true"
Xmlvalidation= "false" Xmlnamespaceaware= "false" >
the appbase can be modified.
(2) Specify in Server.xml
in the In the Tomcat configuration file, a Web application is a specific context that can be deployed by deploying a JSP application in a new context in Server.xml. Open the Server.xml file and create a context within the host tag as follows:
Path is a virtual path;
DocBase is the physical path of the application;
Workdir is the working directory of the application that stores the files generated by the runtime associated with this application;
Debug is set to debug level, 0 means to provide the least information, 9 to provide the most information
Privileged is set to true to allow Tomcat Web apps to use the servlet within the container
Reloadable if True, Tomcat automatically detects changes in the application's/web-inf/lib and/web-inf/classes directories, automatically mounts new applications, and can change applications without having to restart Tomcat for hot deployment
Antiresourcelocking and Antijarlocking thermal deployments are parameters that need to be configured, false by default to avoid updating a webapp, and sometimes Tomcat does not remove the old webapp completely, usually leaving web-inf/ A jar package under Lib must be turned off before Tomcat can be deleted, which results in automatic deployment failure. Set to True,tomcat when the corresponding WebApp is run, the corresponding source files and jar files are copied to a temporary directory.
(3) Create a context file
in the Conf directory, create a new Catalina\localhost directory, create a new XML file in the directory, the name can not be arbitrarily taken, and the name after the path is the same, according to the configuration of the path below, The XML name should be Hello (hello.xml), the content of the XML file is:
Examples of Tomcat comes in as follows:
Privileged= "true" antiresourcelocking= "false" antijarlocking= "false" >
7. control in Easyui the DataGrid will have two requests for background data when loading data,
What's the reason?
The HTML code uses class to declare the DataGrid, causing Easyui to parse the DataGrid in the class declaration when parsing the class code, so that the component requests a URL, and then invokes the JS initialization code to request the URL once. This results in a duplicate load, and the workaround is to declare the Easyui component with only one initialization method to avoid duplicate commit requests, either by deleting the class declaration (class= "Easyui-datagrid") in the HTML or by delaying the load initialization:
Init ();
function init () {
$ (' #dic '). DataGrid ({});
Delayed load, otherwise page request two times
SetTimeout (refreshdic, 100);
}
function Refreshdic () {
$ (' #dic '). DataGrid ({
Queryparams: {
Dictname
}
through settimeout Implementation delay request, resolute not request twice
for those 100 milliseconds the page is not rendered too ugly, first initialize a simple DataGrid.
the number of milliseconds delayed has been tried a lot, the minimum is about 95 milliseconds, can not be smaller, or request two times.
8. What are the symbolic links for strings in Oracle? How is Oracle paged?
the connection symbol is:| |
Paging:
SELECT * FROM
(Select A.*,rownum row_num from
(SELECT * FROM MyTable t ORDER by t.id DESC) A
) b
where B.row_num between StartIndex and EndIndex
9. What is the performance comparison of Where condition queries and sorting in Oracle?
10. explain what deadlocks are and how to resolve deadlocks in Oracle.
Deadlock: While the program is running, only one process is running, other processes are waiting, and clicking on the process's OK and save button, the program does not respond, but also does not error, among the phenomenon is called deadlock.
Workaround:
1) Execute the following statement with the DBA user
Here is the code snippet:
Select Username,lockwait,status,machine,program from v$session where SID in
(select session_id from V$locked_object)
If there is a result of the output, then there is a deadlock, and the machine that can see the deadlock is which one. Field Description:
Username: The database user used by the deadlock statement;
Lockwait: The state of the deadlock if there is a content representation being deadlocked.
Status: State, active indicates deadlock
Machine: The device where the deadlock statement resides.
Program: The main application that generated the deadlock statement.
2) You can view the deadlock statement by executing the following statement with the DBA user.
Select Sql_text from V$sql where Hash_value in
(select Sql_hash_value from v$session where SID in
(select session_id from V$locked_object))
A. Kill the deadlock process:
Alter system kill session ' sid,serial# '; (where sid=l.session_id)
B. If it doesn't work: (Linux)
Select Pro.spid from v$session ses, v$process Pro where ses.sid=xx and ses.paddr=pro.addr;
where SID is replaced with a dead-lock SID:
Exit
Ps-ef|grep spid
where spid is the process number of this process, kill the Oracle process.
11, how to create a view, the benefits of the view, the view can control permissions?
creating a View statement:Create or replace view Teacher_view
As
Select Tname,sal from teacher
Create a view to have View permissions, otherwise you cannot create it.
12. What is the difference between ForWord () and redirect () in the Servlet API ?
Forward: The forwarding---is the server-side behavior, carrying the request data, the client's URL display does not change, and the client only sends the request once
Redirect: Redirect----is the client behavior, does not carry the request data, the client's URL display changes, and the client sends at least two requests
13. How do I view the EJBthat has been published in WebLogic?
You can use the administration console in its All published EJBs can be viewed in deployment.
The difference between persistent and non-persisten when developing a message bean in WebLogic: The persistent way of MDB guarantees the reliability of the message delivery, That is, if there is a problem with the EJB container and the JMS server will still send the message when this MDB is available, the non-persistent message will be discarded.
14. How to configure the delegation scheme in Spring + Hibernate?
<bean id= "DataSource" class= "Org.apache.commons.dbcp.BasicDataSource" >
<property name= "Driverclassname" value= "${jdbc.driverclassname}"/>
<property name= "url" value= "${jdbc.url}"/>
<property name= "username" value= "${jdbc.username}"/>
<property name= "Password" value= "${jdbc.password}"/>
</bean>
<!--configuring Session factory Sessionfactory--
<bean id= "Sessionfactory"
class= "Org.springframework.orm.hibernate3.LocalSessionFactoryBean" >
<property name= "DataSource" ref= "DataSource" ></property>
<!--Configure the Hibernate mapping file and the parameters of the Hiberbnate configuration file--
<!--<property name= "configlocation" value= "Classpath:hibernate.cfg.xml" ></property>-
<property name= "mappingdirectorylocations" value= "Classpath:com/news/pojo" ></property>
<property name= "Hibernateproperties" >
<props>
<prop key= "Hibernate.show_sql" >true</prop>
<prop key= "Hibernate.format_sql" >true</prop>
<prop key= "Hibernate.connection.autocommit" >true</prop>
<prop key= "Hibernate.hbm2ddl.auto" >update</prop>
<prop key= "Hibernate.dialect" >org.hibernate.dialect.Oracle9Dialect</prop>
<!--Configure the session of the current transaction--
<prop key= "Hibernate.current_session_context_class" > Org.springframework.orm.hibernate3.springsessioncontext</prop>
<prop key= "Hibernate.javax.persistence.validation.mode" >none</prop>
</props>
</property>
</bean>
15, ask Xiao Wang in the year to sell to Beijing Haidian District Customer financial software total units? Design a table, table-to-table relationship, and write SQL statements.
Table I:User (Employee table)
field:UID (employee ID, primary key) uname (employee name) Utel (Employee contact information)
Table two District Area table:
field:did (Region did, primary key) region name (dname)
Table III:SAL table
field:sid (Sales label, primary key) Syear (time) scount (quantity) Sdid (exported to region, foreign key associated district primary key did) Suid (salesperson, associated foreign key user's primary key UID)
Select COUNT (0) ' sales volume ', uname ' sales staff '
From (Sal S left join District D on Sdid =did)
Left JOIN user u on Suid=uid
where D.dname= ' Haidian ' and U.uname= ' Xiao Wang ' and s.syear= "2017";
16, write a program, to achieve the news to add and change, News includes: news title, type, content, attachments, different types according to different tab display , click the tab must display the corresponding type of news list, click on the list, Pop-up page, show news item content, attachments can be downloaded.
17. What do you think of overtime work? Can I travel?
18, the current Beijing project requirements are high, do you intend to go to Binhai New area development?
Java Face question 04