Você está na página 1de 125

1)How do I provide user credentials for starting a server?

When you create a domain, the Configuration Wizard prompts you to provide the username and password for an initial administrative user. If you create the domain in development mode, the wizard saves the username and encrypted password in a boot identity file. A WebLogic Server instance can refer to a boot identity file during its startup process. If a server instance does not find such a file, it prompts you to enter credentials. If you create a domain in production mode, or if you want to change user credentials in an existing boot identity file, you can create a new boot identity file. 2)Can I start a Managed Server if the Administration Server is unavailable?

By default, if a Managed Server is unable to connect to the specified Administration Server during startup, it can retrieve its configuration by reading a configuration file and other files directly. You cannot change the server's configuration until the Administration Server is available. A Managed Server that starts in this way is running in Managed Server Independence mode. 3)What is the function of T3 in WebLogic Server? T3 provides a framework for WebLogic Server messages that support for enhancements. These enhancements include abbreviations and features, such as object replacement, that work in the context of WebLogic Server clusters and HTTP and other product tunneling. T3 predates Java Object Serialization and RMI, while closely tracking and leveraging these specifications. T3 is a superset of Java Object. Serialization or RMI; anything you can do in Java Object Serialization and RMI can be done over T3. T3 is mandated between WebLogic Servers and between programmatic clients and a WebLogic Server cluster. HTTP and IIOP are optional protocols that can be used to communicate between other processes and WebLogic Server. It depends on what you want to do. For example, when you want to communicate between a browser and WebLogic Server-use HTTP, or an ORB and WebLogic Server-IIOP. 4)How do you set the classpath?

WebLogic Server installs the following script that you can use to set the classpath that a server requires: WL_HOME\server\bin\setWLSEnv.cmd (on Windows) WL_HOME/server/bin/setWLSEnv.sh (on UNIX) 5) How do stubs work in a WebLogic Server cluster? Clients that connect to a WebLogic Server cluster and look up a clustered object obtain a replica-aware stub for the object. This stub contains the list of available server instances that host implementations of the object. The stub also contains the load balancing logic for distributing the load among its host servers. What happens when a failure occurs and the stub cannot connect to a WebLogic Server instance? When the failure occurs, the stub removes the failed server instance from its list. If there are no servers left in its list, the stubb uses DNS again to find a running server and obtain a current list of running instances. Also, the stub periodically refreshes its list of available server instances in the cluster; this allows the stub to take advantage of new servers as they are added to the cluster. 6)How does a server know when another server is unavailable?

WebLogic Server uses two mechanisms to determine if a given server instance is unavailable. Each WebLogic Server instance in a cluster uses multicast to broadcast regular "heartbeat" messages that advertise its availability. By monitoring heartbeat messages, server instances in a cluster determine when a server instance has failed. The other server instances will drop a server instance from the cluster, if they do not receive three consecutive heartbeats from that server instance WebLogic Server also monitors socket errors to determine the availability of a server instance. For example, if server instance A has an open socket to server instance B, and the socket unexpectedly closes, server A assumes that server B is offline. 7)How are notifications made when a server is added to a cluster? The WebLogic Server cluster broadcasts the availability of a new server instance each time a new instance joins the cluster. Cluster-aware stubs also periodically update their list of available server instances. 8)How do clients handle DNS requests to failed servers?

If a server fails and DNS continues to send requests to the unavailable machine, this can waste bandwidth. For a Java client application, this problem occurs only during startup. WebLogic Server caches the DNS entries and removes the unavailable ones, to prevent the client from accessing a failed server twice. Failed servers can be more of a problem for browser-based clients, because they always use DNS. To avoid unnecessary DNS requests with browser-based clients, use a third-party loadbalancer such as Resonate, BigIP, Alteon, and LocalDirector. These products mask multiple DNS addresses as a single address. They also provide more sophisticated load-balancing options than round-robin, and they keep track of failed servers to avoid routing unnecessary requests. 9)How many WebLogic Servers can I have on a multi-cpu machine?

There are many possible configurations and each has its own advantages and disadvantages. BEA WebLogic Server has no built-in limit for the number of server instances that can reside in a cluster. Large, multi-processor servers such as Sun Microsystems, Inc. Sun Enterprise 10000, therefore, can host very large clusters or multiple clusters. In most cases, WebLogic Server clusters scale best when deployed with one WebLogic Server instance for every two CPUs. However, as with all capacity planning, you should test the actual deployment with your target web applications to determine the optimal number and distribution of server instances. 10)How can I set deployment order for applications? WebLogic Server allows you to select the load order for applications. WebLogic Server deploys server-level resources (first JDBC and then JMS) before deploying applications. Applications are deployed in this order: connectors, then EJBs, then Web Applications. If the application is an EAR, the individual components are loaded in the order in which they are declared in the application.xml deployment descriptor.

What is difference between welogic server and WebSphere?


WebLogic is one of the leading J2EE application servers in todays marketplace. Monitoring WebLogic for its performance and availability becomes inevitable. Applications Manager, a tool for monitoring the performance and availability of applications and servers, helps in BEA WebLogic Management. WebSphere is IBM's powerful J2EE application server that enables businesses and organizations to build robust, Web-based applications. WebSphere, a transaction-oriented web server, allows you to develop, launch, and integrate powerful e-business applicationscustomer management systems, transaction processing, infrastructure adjustment, and many others. This high-performance server provides solutions for connecting people, systems, and applications with your internal and external resources. In cluster , the load balancing that simply redirect the client request to any available server in weblogic server cluster. Suppose assume we have 4 managed servers and one admin server. can we trace that request is going to which managed server in the cluster? is it possible to tell that request is going to which ipaddr/managed server? whenever the request gets routed from any Load balancer or Web-server to any application server, the routed request contains a header part which includes information of the server like Port, Listen address etc based on which it routes to its appropriate server hosting application. And we can trace this information in web-server log file. Diff b/w managed server and non managed server? can u briefly explain? Managed servers are the servers which have one and only one separate Admin server. Admin server manages all the configurations and resources for managed servers. No managed server could only be Admin server. what is digital certificate? For the purposes of digital signing of documents, verification of digital signatures, and handling digital certificates in the Java platform, the Java Cryptography Architecture (JCA) is used. JCA is a specification that gives the programmers a standard way to access cryptographic services, digital signatures, and digital certificates. The Most Important Classes in JCA java.security.KeyStore java.security.PublicKey java.security.PrivateKey java.security.Cert.Certificate

Digital certifiacte is an electronic document which uses a digital signature to bind together a public key with an identity information such as the name of a person or an organization, their address, and so forth. The certificate can be used to verify that a public key belongs to an individual. what is core dump? diff b/w core dump and c dump?

Core dump consists of the recorded state of the working memory of a computer program at a specific time, generally when the program has terminated abnormally.A copy of the data stored in the core memory of a computer, usually used for debugging purposes. What is advantage if silent mode installation ? for this sailent mode of installation you need to specify the log file and xml file. The difference between command and sailent mode is command -mode=console i.e here step by step are visible but in sailent mode every thing is configured. The biggest advantage of silent mode installation is that it is non-interactive and hence your intervention is not required during installation. All the parameters to be used during installation are defined in xml file (usually silent.xml) eg:./filename.bin -mode=silent -silent_xml=silent.xml What is Connection Pool ? Answer 1 Pool: Maintain equal instance of objects is called Pool Connection Pool : the connection objects maintain in the form pool is called connection pool. Advantages of Connection Pool: the Connection is very precies . application need connections getting connections from db and close connection's it's normal process. if we use connection pool no need hit every time db , get from server(in con pool) , in the middle server will get the some amount connections that give the connections . server will take physical connection to db , server will give to logical connection to application if need more connections server will increase connections are maintained que process. Answer 2 Pool: Maintain equal instance of objects is called Pool Connection Pool : the connection objects maintain in the form pool is called connection pool. Adv Con Pool: the Connection is very precies . application need connections getting connections from db and close. What is the difference between Connection Pool and data source? The Connection pool means equals instance of connections and it refereed Data Source object.

What does 'stub' mean in weblogic server? clients that connect to a WLS instances and look like a single clustered object obtain a replica-aware-stub of the object. The stub contains the list of all the available server instancesof the object.It also has a load balancing logic to distribute the load across the multiple hosts. What is managed server ? Any WebLogic Server instance apart from Administration Server is called as Managed Servers. This is weblogic server where you deploy your application (Though you can deploy your application in Administration server as well but it is not recommended in production/UAT instance). A weblogic server instance is called managed server.An administration have no of manager servers. How to find the heap memory of managedServer? 1. For weblogic 8 you can get the details from /weblogic81/common/bin/startManagedWebLogic.sh Here there is a parameter set in the script with memory details. 2. you can varify it from out file of that server by searching Xms and Xms keyword. in ant cersion of WLS. 3. use the below command .ps -auwwwx | grep .In the output you will find parameters Xms and Xmx for heap size. in which file/script we need to change the heap size?.What is the variable name to search to change the heap size ? In start up script,we can change ms and mx value.we can change the heap size in Javaw.exe file, which is located in bin folder. what is WLS T3 protocol? Answer 1. Weblogic's implementationof the RMI specification uses a proprietary wireprotocol known as T3. javasoft's reference implementation of RMI uses a proprietary protocol called JRMP. weblogic developed T3 because they needed a scalable,efficient protocol for building enterprise-class destributed object systems with java. Answer 2. T3 provides a framework for WebLogic Server messages that support for enhancements. These enhancements include abbreviations and features, such as object replacement, that work in the context of WebLogic Server clusters and HTTP and other product tunneling. T3 predates Java Object Serialization and RMI, while closely tracking and leveraging these specifications. T3 is a superset of Java Object. Serialization or RMI; anything you can do in Java Object Serialization and RMI can be done over T3. T3 is mandated between WebLogic Servers and between

programmatic clients and a WebLogic Server cluster. HTTP and IIOP are optional protocols that can be used to communicate between other processes and WebLogic Server. It depends on what you want to do. For example, when you want to communicate between a browser and WebLogic Server-use HTTP, or an ORB and WebLogic Server-IIOP. Answer 3. T3 protocal is used to communicate betwen the EJB's in the wl serevr instances. Answer 4. T3 is an optimized protocol used to transport data between WebLogic Server and other Java programs,including clients and other WebLogic Servers. WebLogic Server keeps track of every Java Virtual Machine (JVM) with which it connects, and creates a single T3 connection to carry all traffic for a JVM.For example, if a Java client accesses an enterprise bean and a JDBC connection pool on WebLogic Server, a single network connection is established between the WebLogic Server JVM and the client JVM. The EJB and JDBC services can be written as if they had sole use of a dedicated network connection because the T3 protocol invisibly multiplexes packets on the single connection. T3 is an efficient protocol for Java-to-Java applications because it avoids unnecessary network connection events and uses fewer OS resources. The protocol also has internal enhancements that minimize packet sizes What happens when database down in weblogic ? Answer 1 : Connection pool staus changes to suspended.it tries to poll the connection. It depends on the configuration of connection pool .I will log an error if application tires to use the connection pool. Answer 2 : using connection pool we can retrive the value in the database. Answer # 3 : in app server u will diffine that connect to which data base according to that connection will be establised and u can get data from data base.if the data base is not working then u will get a error page(related to database).if u want to give 100% availability for clint then u can use failover concept and place the data in to different databases and give instructions for u r application that if one data base is fail to serve the data after partucular time the request will rediirect to another database where data is present. Answer # 4 : in WLSS 9.2 When DB is down the connection pool/Data source will go to SUSPENDED state waiting to re-establish the connection with DB. when DB is up it will automaticaly re-connect with DB . but in the middle if you re-cycle the server. the server will go to ADMIN mode.

Answer # 5 : Impact only particular application which is using failure database. Mean while we need to untarget the failure database to aviod erros in logs. Once DB back needs to target the same. How to set Connection Pool size in Weblogic Server ? we can set connection pool size in weblogic server through admin console.At first you have to login to the adminserver and after putting username and password you will see connectionpool within service configuration,then you have to go through the connectionpool and there will be two tab one is configuration and another will be monitoring.From monitoring tab you can view maxcapasity and highconnection of connectionpool(jdbc).From that you can customize the value . What is multicast Address? an address that can be used to send the messages to the same host addresses but in different network addresses.that addresses can be referred as multicast address.The multicast addresses are in the range 224.0.0.0 to 239.255.255.255. how can we handle if server is hang? and how to handle out of memory in weblogic? When a Server is hanging, we can ping the server using java weblogic.Admin t3://server:port PING. If the server can respond to the ping, it may be that the application is hanging and not the server itself. We can use -verbose gc flag to check whether the server is doing the proper garbage collection or not. Also we can analyze the thread dumps to check out which thread are actually stucking. where can we set classpath, which will reflect to whole domain ? right click on my computer icon->advanced->environment variables.here you will find to panels 1.path and 2.classpth. 1. go to path click on add a)name: name of the path variable. b)value: Absolute path of your bin folder or your application path. what is the differencees between work manager and executequeue? 1.Unlike execute queues, all WorkManagers share a common thread pool and a priority-based queue. 2. The size of the thread pool is determined automatically by the kernel and resized as needed.

3.WorkManagers become very lightweight, and customers can create WorkManagers without worrying about the size of the thread pool. 4.Thread dumps look much cleaner with fewer threads. In the new model, it is possible to specify different service-level agreements (SLAs) such as fair shares or response-time goals for the same servlet invocation depending on the user associated with the invocation. 5.In earlier releases, each servlet or RMI request was associated with a dispatch policy that mapped to an execute queue.Requests without an explicit dispatch policy use the server-wide default execute queue. In WebLogic Server 9.0, requests are still associated with a dispatch policy but are mapped to a WorkManager instead of to an execute queue. 6.Execute queues are always global whereas WorkManagers are always application scoped. Even WorkManagers defined globally in the console are application scoped during runtime. This means that each application gets into own runtime instance that is distinct from others, but all of them share the same characteristics like fair-share goals. 7. Another advantage is Thread Count Self-tuning. One of the major differences between execute queues and the new thread scheduling model is that the thread count does not need to be set. In earlier releases, customers defined new thread pools and configured their size to avoid deadlocks and provide differentiated service. It is quite difficult to determine the exact number of threads needed in production to achieve optimal throughput and avoid deadlocks. WebLogic Server 9.0 is self-tuned, dynamically adjusting the number of threads to avoid deadlocks and achieve optimal throughput subject to concurrency constraints. It also meets objectives for differentiated service. These objectives are stated as fair shares and response-time goals as explained in the next section. 8. Execute Queue concepts used till 8.1+ weblogic releases. Work Manager came from Weblogic 9+. dIFFERNCE BETWEEN VERSIONS 8.X,9.X,10.X ? There are various differences ranging from 8.X,9.X,10.X 1. Changes made in console UI. 2. The node Manager uses the port no 5555 in 8.x and in 10.x it uses 5556. 3. Every functionality should be done only after hitting LOCK AND EDIT option in the version of 10x, Where as it is not needed in the version of 8.x. 4. There is no need of creating Connection pools in 10.x . Datasource itself directs requests where as Connection pools should be created in the version 8.x. 8.x-----------------------------------------9.x and 10.x

1)In 8 no loc& edit option--------1)In 9 lock & edit option 2)here Execute ques are there-----2)here work managers 3)here you can use in node manager portno:-5556--3)5557 What is config.xml.booted file ? Config.xml.booted file is a replica of config.xml file. It is stored inside the root file of the admin server.When your msi-config.xml is not running on independent mode and your config.xml file is destroyed or currupted for any cause,then you can start your managed server by taking the configuration from this file. What is config.xml? it is heart of the weblogic server and its maintains the all the info about managed and admin server details like Ipadd,portno...etc, and whenever you update the admin console that info is updated in config.xml and while restart the server,server will get details from config.xml only and using we can deploy the application nothing but hard deployment. What is DataSource ?how can its associated with connection pools ? DataSoource is an Interface that is an alternative to Driver manager.It has methods : getConnection() getConnection(username,pwd) ...and many more.. Through JNDI it connects with database.Or It takes from Connection pool.
What is BEA Weblogic?
BEA WebLogic is a J2EE application server and also an HTTP web server by BEA Systems of San Jose, California, for Unix, Linux, Microsoft Windows, and other platforms. WebLogic supports Oracle, DB2, Microsoft SQL Server, and other JDBCcompliant databases. WebLogic Server supports WS-Security and is compliant with J2EE 1.3. BEA WebLogic Server is part of the BEA WebLogic Platform. The other parts of WebLogic Platform are: * Portal, which includes Commerce Server and Personalization Server (which is built on a BEA-produced Rete rules engine), * WebLogic Integration, * WebLogic Workshop, an IDE for Java, and * JRockit, a JVM for Intel CPUs. WebLogic Server includes .NET interoperability and supports the following native integration capabilities: * Native enterprise-grade JMS messaging * J2EE Connector Architecture * WebLogic/Tuxedo Connector * COM+ Connectivity * CORBA connectivity * IBM WebSphere MQ connectivity BEA WebLogic Server Process Edition also includes Business Process Management and Data Mapping functionality. WebLogic supports security policies managed by Security Administrators. The BEA WebLogic Server Security Model includes:

* Separate application business logic from security code * Complete scope of security coverage for all J2EE and non-J2EE components
Which of the following statements are true regarding MDBs (Message Driven Beans) on version 6.0 of WebLogic App Server?

a. MDBs support concurrent processing for both Topics and Queues. b. MDBs support concurrent processing for only Topics. c. MDBs support concurrent processing for only Queues. d. MDBs support concurrent processing neither Topics nor Queues. Choice A is correct. MDBs support concurrent processing for both Topics and Queues. Previously, only concurrent processing for Queues was supported. To ensure concurrency, change the weblogic-ejb-jar.xml deployment descriptor maxbeans-in-free-pool setting to >1. If this element is set to more than one, the container will spawn as many threads as specified. WebLogic Server maintains a free pool of EJBs for every stateless session bean and message driven bean class. The max-beans-in-free-pool element defines the size of this pool. By default, maxbeans-in-free-pool has no limit; the maximum number of beans in the free pool is limited only by the available memory.
Can I use a "native" two-tier driver for a browser applet?

No. Within an unsigned applet, you cannot load native libraries over the wire, access the local file system, or connect to any host except the host from which you loaded the applet. The applet security manager enforces these restrictions on applets as protection against applets being able to do unsavory things to unsuspecting users. If you are trying to use jDriver for Oracle from an applet, then you are violating the first restriction. Your applet will fail when it attempts to load the native (non-Java layer) library that allows jDriver for Oracle to make calls into the non-Java Oracle client libraries. If you look at the exception that is generated, you will see that your applet fails in java.lang.System.loadLibrary, because the security manager determined that you were attempting to load a local library and halted the applet. You can, however, use the WebLogic JTS or Pool driver for JDBC connectivity in applets. When you use one of these WebLogic multitier JDBC drivers, you need one copy of WebLogic jDriver for Oracle (or any other two-tier JDBC driver) for the connection between the WebLogic Server and the DBMS.

I'm using a WebLogic multitier driver in an applet as an interface to a DBMS. If I run the class using the Sun Appletviewer on my local machine, I have no problems. But when I try to run the applet in a Netscape browser, it will not connect.
If Appletviewer works and Netscape does not, it is an indication that you are violating a Netscape security restriction. In this case, the violation is that an applet cannot open a socket to a machine other than the one from which it loaded the applet. To solve this problem, you will have to serve your applet code from the same machine that hosts the DBMS. In addition, the IP naming format you use in the applet CODEBASE and the constructor for the T3Client must match. That is, you can't use dot-notation in one place and a domain name in the other.
I tried to run two of the applets in the examples directory of the distribution. I installed the WebLogic classes on my local machine (NT server) and on another machine (a Windows 95 client). I am not using any browsers, just trying to run the applets with Appletviewer. The applets work fine when I run Appletviewer from the NT server, but do not work at all from the Windows 95 client.

There are two possible problems: Either the CODEBASE tag is not properly set in the applet HTML file, or the class files are not properly loaded on the HTTP server. The applet works on the NT server because you installed the WebLogic distribution on your NT server. Even if the applet cannot successfully load the necessary classes from the HTTP server, it does find them in your local CLASSPATH. But when you try to run

it from the Windows 95 client, the applet must load the classes over the wire from the HTTP server, and if you haven't installed them correctly, it will fail.
The two primary cluster services provided by WebLogic Server are?

a. Http Session State Clustering b. File Service Clustering c. Time Service Clustering d. Object Clustering e. Event Clustering

Choices A and D are correct. A WebLogic Server cluster is a group of servers that work together to provide a more scalable and reliable application platform than a single server. A clustered service is an API or interface that is available on multiple servers in the cluster. HTTP session state clustering and object clustering are the two primary cluster services that WebLogic Server provides. WebLogic Server also provides cluster support for JMS destinations and JDBC connections. WebLogic Server provides clustering support for servlets and JSPs by replicating the HTTP session state of clients that access clustered servlets and JSPs. To benefit from HTTP session state clustering, you must ensure that the session state is persistent, either by configure in-memory replication, file system persistence, or JDBC persistence. If an object is clustered, instances of the object are deployed on all WebLogic Servers in the cluster. The client has a choice about which instance of the object to call. This is Object Clustering. The APIs and internal services that cannot be clustered in WebLogic Server version6.0 are File services, Time services, WebLogic Events, Workspaces and ZAC.
How do stubs work in a WebLogic Server cluster?

Clients that connect to a WebLogic Server cluster and look up a clustered object obtain a replica-aware stub for the object. This stub contains the list of available server instances that host implementations of the object. The stub also contains the load balancing logic for distributing the load among its host servers.
What happens when a failure occurs and the stub cannot connect to a WebLogic Server instance?

When the failure occurs, the stub removes the failed server instance from its list. If there are no servers left in its list, the stub uses DNS again to find a running server and obtain a current list of running instances. Also, the stub periodically refreshes its list of available server instances in the cluster; this allows the stub to take advantage of new servers as they are added to the cluster.
Why did my JDBC code throw a rollback SQLException?

Your JDBC code may throw the following exception: "The coordinator has rolled back the transaction. No further JDBC access is allowed within this transaction."

The WebLogic JTS JDBC driver throws this exception when the current JDBC connection transaction rolls back prior to or during the JDBC call. This exception indicates that the transaction in which the JDBC connection was participating was rolled back at some point prior to or during the JDBC call. The rollback may have happened in an earlier EJB invoke that was part of the transaction, or the rollback may have occurred because the transaction timed out. In either case, the transaction will be rolled back, the connection returned to the pool and the database resources released. In order to proceed, the JTS JDBC connection must be closed and reopened in a new transaction.
Must my bean-managed persistence mechanism use the WebLogic JTS driver?

Use the TxDataSource for bean-managed persistence.


Why is there no polymorphic-type response from a create() or find() method?

The EJB Specification prohibits this behavior, and the weblogic.ejbc compiler checks for this behavior and prohibits any polymorphic type of response from a create() or find() method. The reason the create() and find() methods are not polymorphic is similar to the reason

constructors are not polymorphic in Java. The derived classes generally do not know or cannot initialize the base class properly.
Must EJBs be homogeneously deployed across a cluster? Why?

Yes. Beginning with WebLogic Server version 6.0, EJBs must be homogeneously deployed across a cluster for the following reasons: * To keep clustering EJBs simple * To avoid cross server calls which results in more efficiency. If EJBs are not deployed on all servers, cross server calls are much more likely. * To ensure that every EJB is available locally * To ensure that all classes are loaded in an undeployable way * Every server must have access to each EJB's classes so that it can be bound into the local JNDI tree. If only a subset of the servers deploys the bean, the other servers will have to load the bean's classes in their respective system classpaths which makes it impossible to undeploy the beans.

Which of the following are recommended practices to be performed in the ejbPassivate() method of a stateful session bean?
a. Close any open resources, like database connections b. All non-transient, non-serializable fields(except some special types) should be set to null. c. All transient fields should be set to null d. Make all database connection reference fields transient e. All primitive type fields should be set to null Choices A, B and D are correct. When a bean is about to be passivated, its ejbPassivate() method is invoked, alerting the bean instance that it is about to enter the Passivated state. At this time, the bean instance should close any open resources and set all non transient, non serializable fields to null. This will prevent problems from occurring when the bean is serialized. Transient fields will simply be ignored.Serializable fields will be saved. Open resources such as sockets or JDBC connections must be closed whenever the bean is passivated. In stateful session beans, open resources will not be maintained for the life of the bean instance. When a stateful session bean is passivated, any open resource can cause problems with the activation mechanism. A bean's conversational state may consist of only primitive values, objects that are serializable, and the following special types-SessionContext, EJBhome, EJBObject, UserTransaction and Context (only when it references the JNDI ENC) . The types in this list (and their subtypes) are handled specially by the passivation mechanism. They don't need to be serializable; they will be maintained through passivation and restored automatically to the bean instance when it is activated

While packaging the Web Application DefaultWebApp for deployment into the WebLogic server, the home and remote interfaces of the enterprise beans used by the servlets should reside in which directory?
a. DefaultWebApp/META_INF/classes b. DefaultWebApp/META_INF/lib c. DefaultWebApp/WEB_INF/lib d. DefaultWebApp/WEB_INF/classes e. DefaultWebApp/classes

Choice D is correct. When packaging a web application create META-INF and WEB-INF subdirectories in the application directory to hold deployment descriptors and compiled Java classes. All servlet classes and helper classes should reside in the WEBINF/classes subdirectory. The home and remote interface classes for enterprise beans used by the servlets into the WEB-INF/classes subdirectory. All the HTML files, JSP files, images, and any other files that these Web pages reference should exist in the application directory, maintaining the directory structure for referenced files. The META_INF directory contains the deployment descriptors for the enterprise beans, but not the classes.
How do I set up my CLASSPATH?

Setting up your CLASSPATH correctly depends on what you are trying to do. The most common tasks are described below: * Starting WebLogic Server. See Setting the Classpath Option in the Starting and

Stopping WebLogic Servers section of the Administration Guide. In addition, your WebLogic distribution includes shell scripts that you can use to start the server. These scripts, which are located in the domain directories under the config directory of your WebLogic Server distribution, automatically set up the CLASSPATH variable in the shell before starting the server.
Why do I get the following exception when viewing the JNDI tree?
isSerializable(class.javax.naming.Binding) java.io.NotSerializableException: java.io.PrintWriter at java.io.ObjectOutputStream.OutputObject

The Weblogic Server JNDI implementation requires objects to be serializable, not referencable. A PrintWriter cannot be serialized and therefore should be declared transient.

When deploying a resource adapter (.rar) to WebLogic Server, are its classes placed in the WebLogic classpath? For instance, I am deploying an EJB and a resource adapter (.rar), the EJB has no dependencies on the .rar because the EJB is writing to the common client interface (CCI). The EJB client application has sends/marshals as parameter classes that are defined in the .rar. For some reason the EJB's class loader hierarchy cannot find the definition of this .rar-specific class, even though the .rar is deploying successfully. I receive the following error on the EJB client: java.rmi.UnmarshalException: error unmarshalling arguments; nested
exception is: java.lang.ClassNotFoundException: com.mycompany.InteractionSpecImpl

When you pass an instance of com.myclientcompany.server.eai.InteractionSpecImpl as an argument to your EJB, the appServer needs to de-serialize (unmarshal) the object under the EJB context, and it needs the required class for unmarshalling, inside the ejb-jar(raTester.jar). So if you include the interactionspecimpl class in your ejb-jar file, then you do not need to include those classes in your server's classpath.
How is security handled in the WebLogic J2EE Connector Architecture?

Due to the fact that the current configuration and packaging requirements for resource adapters in WebLogic Server require the hand-editing of the weblogic-ra.xml file, any new passwords specified in the security-principal-map entries are done in clear-text. BEA understands the importance of protecting security passwords. Hence, we provide a Converter Tool that allows for the encryption of all passwords present in the weblogicra.xml file. The Converter Tool is shipped in the standard weblogic.jar file.
Can I enable requests to a JDBC connection pool for a database connection to wait until a connection is available?

No, there's no way to allow a request to wait for a pool connection, and from the system point of view there should not be. Each requests that waits for a connection ties up one of the fixed number of execute threads in the server, which could otherwise be running another server task. Too many waiting requests could tie up all of the execute threads and freeze the server.

How do I use multibyte character sets with WebLogic jDriver for Informix?
Currently, multibyte character sets are not supported for the WebLogic jDriver for Informix driver.
How do I connect to an SQL Server instance that is running on a machine with multiple instances of SQL Server 2000?

Each instance of MS SQL Server must be listening on a different port. So, you can use the port number in the properties that you pass to the getConnection() method or, in case of connection pools, you can specify the port property in the following properties: server=machineName port=instancePort

To find the port number where each MS SQL Server instance is running, run the server network utility (in the Microsoft SQL Server program group), select the server instance, select TCP/IP, and click the properties button.
Why does FOR UPDATE in Oracle 8 cause an ORA-01002 error?

The Oracle 8 server generates an ORA-01002:fetch out of sequence error message when you use a FOR UPDATE statement with AUTOCOMMIT turned on (which is the default state when using JDBC). This is known to happen on Oracle 8.0 and 8.1 on Solaris and on Oracle 8.1 on Windows NT. If you turn AUTOCOMMIT off, you will not receive this error. Because this problem is due to a change in the Oracle 8 server, you should contact Oracle support for more information.
What causes an OCIW32.dll error?

You may receive the following error message when using your JDBC driver for Oracle: "The ordinal 40 could not be loaded in the dynamic link library OCIW32.dll." This problem is caused by an out-of-date version of OCIW32.DLL in your system directory. Some programs install this file in the system directory in order to run. If you remove this file from the system directory you should no longer receive this error.
What transaction isolation levels does the WebLogic jDriver for Oracle support?

Your servlet application may use Oracle Thin Drivers to access a database that includes BLOB fields. If you install and try to use WebLogic jDriver for Oracle and the same code fails and produces an exception similar to the following: com.roguewave.jdbtools.v2_0.LoginFailureException: TRANSACTION_READ_UNCOMMITTED isolation level not allowed The Stack Trace: com.roguewave.jdbtools.v2_0.LoginFailureException: TRANSACTION_READ_UNCOMMITTED isolation level not allowed at com.roguewave.jdbtools.v2_0.jdbc.JDBCServer.createConnection (JDBCServer.java :46) at com.roguewave.jdbtools.v2_0.ConnectionPool.getConnection_ (ConnectionPool.jav a:412) at com.roguewave.jdbtools.v2_0.ConnectionPool.getConnection (ConnectionPool.java :109) Setting the Isolation_level to 1 in the code that calls the RogueWave JDBCServer class works with the Oracle thin driver but fails with WebLogic jDriver for Oracle. WebLogic jDriver for Oracle supports the following transaction isolation levels: SET TRANSACTION ISOLATION LEVEL READ COMMITTED SET TRANSACTION ISOLATION LEVEL SERIALIZABLE According to the Oracle documentation, the Oracle DBMS only supports these two isolation levels. Unlike other JDBC drivers, WebLogic's drivers throw an exception if you try to use an isolation level that is unsupported. Some drivers silently ignore attempts to set an unsupported isolation level. WebLogic suggests testing whether the Oracle thin driver is not just ignoring settings for unsupported isolation events.

How do I use OS Authentication with WebLogic jDriver for Oracle and Connection Pools?
Using OS authentication in connection pools essentially means that you are using the UserId of the user who started WebLogic Server. OS authentication is available on NT and UNIX, but not on Solaris. This means that database security will rely strictly on the security of WebLogic; that is, if you are allowed to make a client connection to the WebLogic Server and access the pool, then you can get to the database.

You can do this with WebLogic jDriver for Oracle because Oracle uses the process owner to determine who is attempting the connection. In the case of WebLogic JDBC, this is always the user that started the WebLogic Server. To set up your Oracle instance to use this feature, your DBA needs to follow these basic steps. The full procedure is described in more detail in your Oracle documentation. 1. Add the following line to the INIT[sid].ORA file: OS_AUTHENT_PREFIX = OPS$ Note that the string "OPS$" is arbitrary and up to the DBA. 2. Log in to the Oracle server as SYSTEM. 3. Create a user named OPS$userid, where userid is some operating system login ID. This user should be granted the standard privileges (for example, CONNECT and RESOURCE). 4. Once the userid is set up, you can connect with WebLogic jDriver for Oracle by specifying "/" as the username property and "" as the password property. Here is an example for testing this connection with the dbping utility: $ java utils.dbping ORACLE "/" "" myserver Here is a code example for WebLogic jDriver for Oracle: Properties props = new Properties(); props.put("user", "/"); props.put("password", ""); props.put("server", "myserver"); Class.forName("weblogic.jdbc.oci.Driver").newInstance(); Connection conn = myDriver.connect("jdbc:weblogic:oracle", props); 1. Use the Administration Console to set the attribute for your connection pool. The following code is an example of a JDBC connection pool configuration using the WebLogic jDriver for Oracle: <JDBCConnectionPool Name="myPool" Targets="myserver,server1" DriverName="weblogic.jdbc.oci.Driver" InitialCapacity="1" MaxCapacity="10" CapacityIncrement="2" Properties="databaseName=myOracleDB"
What type of object is returned by ResultSet.getObject()?

WebLogic jDriver for Oracle always returns a Java object that preserves the precision of the data retrieved. WebLogic jDriver for Oracle returns the following from the getObject() method: * For columns of types NUMBER(n) and NUMBER(m,n): a Double is returned if the defined precision of the column can be represented by a Double; otherwise BigDecimal is returned. * For columns of type NUMBER: Because there is no explicit precision, the Java type to return is determined based on the actual value in each row, and this may vary from row to row. An Integer is returned if the value has a zero-valued fractional component and the value can be represented by an integer. For example, 1.0000 will be an integer. A long is returned for a value such as 123456789123.00000. If a value has a non-zero fractional component, a Double is returned if the precision of the value can be represented by a Double; otherwise a BigDecimal is returned.

How do I limit the number of Oracle database connections generated by WebLogic Server?

You can use connection pools to limit the number of Oracle database connections generated by WebLogic Server in response to client requests. Connection pools allow T3 applications to share a fixed number of database connections. For information on how to set up connection pools,

How do I call Oracle stored procedures that take no parameters?


Here is what we use that works: CallableStatement cstmt = conn.prepareCall("Begin procName; END;"); cstmt.execute(); where procName is the name of an Oracle stored procedure. This is standard Oracle SQL syntax that works with any Oracle DBMS. You might also use the following syntax: CallableStatement cstmt = conn.prepareCall("{call procName};"); cstmt.execute(); This code, which conforms to the Java Extended SQL spec, will work with any DBMS, not just Oracle.
Why do I get unexpected characters from 8-bit character sets in WebLogic jDriver for Oracle?

If you are using an Oracle database with an 8-bit character set on Solaris, make sure you set NLS_LANG to the proper value on the client. If NLS_LANG is unset, it defaults to a 7-bit ASCII character set, and tries to map characters greater than ASCII 128 to a reasonable approximation (for example, , , would all map to a). Other characters are mapped to a question mark (?).
How do I learn what codesets are available in Oracle?

To find out what codesets you currently have available in Oracle, execute the following SQL query from SQLPlus at the command line: SQL> SELECT value FROM v$nls_valid_values WHERE parameter='CHARACTERSET'; The response lists of all codesets currently installed on your system. This listing will look something like the following shortened list: VALUE --------------US7ASCII WE8DEC WE8HP US8PC437 WE8EBCDIC37 WE8EBCDIC500 WE8EBCDIC285 ... If you want to constrain the value in the query to a specific codeset you are searching for, you might use a SQL query like the following: SQL> SELECT value FROM v$nls_valid_values WHERE parameter='CHARACTERSET' and VALUE='AL24UTFFSS'; This would produce the following response if the codeset is installed: VALUE ------------------AL24UTFFSS You can use Oracle's installation tools to install additional codesets. Contact Oracle for more information.

How many deployment descriptor files does a CMP entity bean deployed on the WebLogic Server have?

a. One J2EE specific deployment descriptor and two WebLogic specific deployment descriptors b. One J2EE specific deployment descriptor and one WebLogic specific deployment descriptors c. One J2EE specific deployment descriptor only d. One WebLogic specific deployment descriptor only Choice A is correct. Deployment descriptors are text documents formatted with XML tags. The J2EE specifications define standard, portable deployment descriptors for J2EE components and applications. BEA defines additional WebLogic-specific deployment descriptors required to deploy a component or application in the WebLogic Server environment. When packaging an enterprise bean, we need to create an ejb-jar.xml deployment descriptor in the META-INF subdirectory and add entries for the bean. We also need to create a weblogic-ejb-jar.xml deployment descriptor in the META-INF subdirectory and add entries for the bean. If the bean is an entity bean with container-managed persistence, first we create a weblogic-rdbms-cmp-jar-bean_name.xml deployment descriptor in the META-INF directory with entries for the bean. Then we map the bean to this CMP deployment descriptor with a attribute in the weblogic-ejb-jar.xml file.

Why do I get an error while trying to retrieve the text for ORA-12705?
This error occurs when you have not set the ORACLE_home environment variable properly a common mistake. In order to use WebLogic jDriver for Oracle, the Oracle client software needs to be installed and ORACLE_home must be set. You may also see this error message if you try to use WebLogic jDriver for Oracle's internationalization capabilities with a language/codeset combination that is not installed on your system. If you get the ORA-12705 error with the correct error text, then either you have set NLS_LANG improperly, or you do not have the right codesets installed on your system.
Why do I run out of resources during updates with Oracle's database link?

When you use Oracle's database link to update your database, you may get error "maximum number of temporary table locks exceeded" even if you close your result sets and statements when you finish. The database link is an object in the local database that allows you to access tables, views, and such in a remote database. The database link is controlled by the Oracle server, so the driver has no control over its use of resources. The link appears to perform the commit (since other processes could see the records that were being created), but it doesn't free any resources until the connection is closed. The solution is to remove the database link and use the JDBC driver to do your selects, inserts, and updates.
How do I prevent errors when running t3dbping?

When you are testing your Oracle database connections under UNIX, you can run SQL*PLUS and can successfully ping the database using utils.dbping. However, when you use the multitier utils.t3dbping utility, you receive an ORA-12154 error message. First, make sure that your ORACLE_home environment variable is correctly set to point to your Oracle installation. This variable must be set in the environment where the WebLogic server is running. In the C-shell issue the following command: $ setenv ORACLE_home path where path is the path to your Oracle installation. In the Bourne shell, issue the following commands: $ ORACLE_home=path $ export ORACLE_home

Where path is the path to your Oracle installation. When you ping your database using the two-tier utils.dbping utility, the JDBC driver loads the database client library and establishes the connection to the database. When you use the multitier utils.t3dbping utility, the WebLogic Server loads a twotier driver and uses it to establish a database connection. In both cases, the same method is used to connect to the database. SQL*PLUS works because it doesn't require ORACLE_home to find the client libraries.

If you are still experiencing problems, try this: 1. Open a command shell. 2. Run the two-tier version of utils.dbping in this shell. 3. Start WebLogic in this shell from the command line: $ java -ms32m -mx32m weblogic.server 4. Open a second command shell. 5. Run the utils.t3dbping in the second shell against the server running in the first command shell. If this procedure doesn't work, please send the output from these commands to WebLogic technical support.

Why does executing the PreparedStatement class cause a "TRUNC fails: ORA00932: inconsistent datatypes" error?
According to Oracle Metalink Bug Database Doc ID: 144784.1, in the absence of explicit data typecasting, OCI assumes that a bind variable is a CHAR data type. If the SQL statement intends to use the bind variable as a DATE data type, but OCI thought it was a CHAR, the SQL parser will have a conflict in data types. The fix is to explicitly use data conversion functions to convert the bind variables in the problem queries. For example, a select string of String st = "select count(*) from simple_table where TRUNC(mydate) = TRUNC(?)"; should be changed to: String st = "select count(*) from simple_table where TRUNC(mydate) = TRUNC(TO_DATE(?))";
Why am I getting an "ORA-01000: maximum open cursors exceeded" error, even though I closed all ResultSet, Statement, and Connection objects?

This is an Oracle issue. According to Oracle's documentation, dynamic cursors can remain open from run to run in a session and are not closeable when a procedure closes. To work around this issue, you can increase the number of open cursors allowed in the database or you can reset the connection pool (close and reopen database connections in the connection pool). To reset the connection pool, you can untarget and retarget the connection pool using the Administration Console. You can also use the reset() method through the JMX API or the RESET_POOL command on the WebLogic Server command line interface.
An instance of stateful session EJB when accessed simultaneously from more than one clients on same VM results in RemoteException or EJBException. In case the client is a Servlet thread, which of the following techniques can be used to avoid RemoteException/EJBException?

a. Not possible. b. Store the reference to the EJB instance as an instance variable of Servlet class. c. Store the reference to the EJB instance as a local variable of Servlet class. d. Make the Servlet client to be remote instead of internal to WebLogic server. Choice C is the correct choice. An instance of a stateful session EJB can be accessed from only one client virtual machine at a time. Multiple client threads from the same virtual machine can access the same instance of a stateful session EJB, but they must do so in a serial fashion. If a client-invoked business method is in progress on an instance when another client-invoked call, from the same or different client, arrives at the same instance of a stateful session bean class, the container may throw the java.rmi.RemoteException to the second client , if the client is a remote client, or the

javax.ejb.EJBException, if the client is a local client. Thus choice D is incorrect. To avoid any exception, each Servlet should store a reference to a particular EJB instance in a local variable of the Servlet's service() method. Please note that variables local to methods like service(), doGet(), doPost() are not shared between different requests and are automatically thread safe. Thus choice C is correct. An instance variable unlike local variable is shared. Thus Choice B is incorrect. An implication of this rule is that an application cannot make loop back calls to a session bean instance. This restriction does not apply to a stateless session bean because the container routes each request to a different instance of the session bean class.
Are there C/C++ interfaces to WLS JMS?

No, this is not supported. * Write your own interfaces using JNI. * Setup a Servlet that your C/C++ client calls to generate a JMS message. You should spawn multiple threads in C++ and use multiple posts to pass messages via http.
How do I start WLS and configure JMS?

On Windows, start WLS 6.X by selecting Start -< Programs -< BEA WebLogic EBusiness Platform -< WebLogic Server 6.X -< Start Default Server and enter the administrator password. On Windows, to configure JMS, start the console by selecting Start -< Programs -< BEA WebLogic E-Business Platform -< WebLogic Server 6.X -< Start Default Console. 1. In the console tree view on the left, select JMS. 2. If you want persistent messages, first create a Store - Select Stores. In the window on the right, Select Create a new JMSFile Store for a file store, give it a name, give it a directory, select create. If you want a JDBCStore, you first need to create a JDBC connection pool by selecting JDBC in the tree view, Connection Pools, create a new JDBC Connection Pool. Select Targets, select a Target server, select the arrow that points to the right and select Apply. Then go back to Stores, Create a new JMSJDBCStore. 3. If you want to use a template, first create a Template - Select Templates. You need a template to create temporary queues. Select Create a new JMS Template, give it a name, select create, then you can move to the Thresholds &Quotas tab or the Override tab. Select Apply when done with your changes. 4. Select Servers. Select Create a new JMSServer, give it a name, select a Store if you created one, select a template if you created one, Select Create. Now you can move to the other tabs, make changes, select Apply. In particular, you must select Targets, select a Target server, select the arrow that points to the right, and select Apply. This is the server on which JMS will boot. 5. Create Destinations - from the tree view in the left panel, select the + in front of JMS, select the + in front of Servers, select the + in front of your server, select Destinations, Select Create a new JMSQueue or Create a new JMSTopic, fill in the first page and Select Create, then you can select, fill in, and Apply other tabs. 6. Create Connection Factories - on left tree view, open JMS. Select Connection Factory. Select Create a new JMS Connection Factory on the right panel. Type in the name and JNDI name. Select Create (lower right hand corner). Select the Targets tab. Select the name of the server on which you want to deploy the connection factory. Select the arrow pointing to the right - the server moves to chosen. Then select Apply (lower right hand corner).

How do I configure JMS security?


The correct way to set up security for JMS is to go to the console, select ACLs in the tree view, then create some access control lists. 1. Set the ACL name which should be weblogic.jms.queue.QUEUENAME or weblogic.jms.topic.TOPICNAME.

2. Select Create. 3. Enter the New Permission of send or receive. 4. Select Create. 5. Enter a comma separated list of users or groups. 6. Select Grant Permission. 7. Select "saved to the realm implementation" to save your changes. 8. Select Yes. This will update the fileRealm.properties file with lines that look like the following: acl.send.weblogic.jms.queue.TestQueue1=user1 acl.receive.weblogic.jms.queue.TestQueue1=user1 If you don't have an ACL for a queue or topic, security is wide open. There are also ACL's for accessing the JNDI context; the JNDI context is a requirement for initially accessing JMS. See the JNDI documentation.

Can I still use the default connection factories supported in WebLogic Release 5.1?
Yes. The following two names for the default connection factories have been deprecated: javax.jms.QueueConnectionFactory javax.jms.TopicConnectionFactory. However, these connection factories are still defined and usable in this release for backwards compatibility. WebLogic JMS 6.1 defines one connection factory, by default: weblogic.jms.ConnectionFactory You have to Enable the JMS default connection factories. Go to the console->your server->tuning->click on the check box Enable Default JMS Connection Factories. You can also specify user-defined connection factories using the Administration Console.
Why does JMSSession.createTopic or JMSSession.createQueue fail to create a destination in WLS JMS 6.1 (it worked in 5.1)?

In WLS 5.1 createTopic() or createQueue() creates the destination permanently in the database if it doesn't already exist, but does not modify the weblogic.properties file. According to the JavaSoft JMS specification version 1.0.2 regarding createQueue() and createTopic(), they are not for creating destinations dynamically. They are used to retrieve the destination referenced by using a string name instead of using JNDI lookup. The destination has to be in your config.xml file first. This change is documented in WLS 6.0 since it behaves differently than the previous release. You can use the WLS JMS helper class (weblogic.jms.extensions.JMSHelper) or the console to create destinations at the run time (note that there was a bug in 6.0 that caused a problem when the server restarted; this is fixed in Service Pack 1). These mechanisms create the destination and also modify the configuration file. For more information on the JMSHelper classes, see the subsection called Creating Destinations Dynamically in Programming WebLogic JMS. The following program creates a Topic. import import import import import java.io.*; java.util.Hashtable; javax.jms.*; javax.naming.*; weblogic.jms.extensions.JMSHelper;

class t { public final static String JNDI_FACTORY="weblogic.jndi.WLInitialContextFactory"; public final static String JMS_SERVER_NAME="TestJMSServer"; public final static String DEST_JNDI_PREFIX="javax.destination."; static public void main(String [] args) throws Exception {

try { Hashtable env = new Hashtable(); env.put(Context.INITIAL_CONTEXT_FACTORY, JNDI_FACTORY); env.put(Context.PROVIDER_URL, "t3://localhost:7001"); Context ctx = new InitialContext(env); String topicName = "JMSHelperTestQueue01"; String topicJNDI = DEST_JNDI_PREFIX + topicName; System.out.println("topic name=" + topicName + ", jndi=" + topicJNDI); JMSHelper.createPermanentTopicAsync(ctx, JMS_SERVER_NAME, topicName, topicJNDI); } catch (JMSException e) { e.printStackTrace(); } } } How do I programmatically get a list of Queues or Topics? The following program uses Mbeans: import weblogic.management.*; import weblogic.management.configuration.*; InitialContext ic = new InitialContext(); MBeanhome home = (MBeanhome)ic.lookup(MBeanhome.ADMIN_JNDI_NAME); for(Iterator i = o.getMBeansByType("JMSTopic").iterator(); i.hasNext(); ){ WebLogicMBean wmb = (WebLogicMBean)i.next(); System.out.println("topic name found: " + wmb.getName()); } for(Iterator i = o.getMBeansByType("JMSQueue").iterator(); i.hasNext(); ){ WebLogicMBean wmb = (WebLogicMBean)i.next(); System.out.println("queue name found: " + wmb.getName()); }
How do I use a temporary destination?

You must create a template on every JMSServer where you want to be able to create temporary destinations. You can specify multiple JMSServer entries to support TemporaryTemplate and the system will load balance among those JMS servers to setup the temporary destination. See How do I start WLS and configure JMS? for a description about how to configure JMS. The resulting template definition looks something like the following: <JMSTemplate Name="MyTemplate"/> The JMSServer is defined something like:

After the template name, you can set any queue/topic attribute you want in the template (not including a JNDI name or topic multicast settings). The template is at the outer most level; that is, it should not be nested in your . Temporary destinations can only be consumed by the creating connection. Using topics, you create your temporary topic and subscribe to that temporary topic. If you want someone to publish to that temporary topic, you need to tell that someone what your topic is. You can send them a message and include your temporary topic in the

JMSReplyTo field. The creator of the TemporaryTopic and the subscriber must be one in the same. import javax.jms.TopicSession; TemporaryTopic myTopic = mySession.createTemporaryTopic(); TopicSubscriber = mySession.createSubscriber(myTopic); Temporary topics do not get names and cannot be subscribed to by other connections. When you create a temporary topic, the JMS provider returns a javax.jms.Topic. You then need to advertise that topic to other parties (those who want to publish to the topic), putting it in your JMSReplyTo field so that they can respond. In general, no one else can subscribe to the topic. You advertise the topic any way you want. Topics are serializable (or, in our case, externalizable), which allows you to pass them around in RMI calls, through a file, binding it to a name in JNDI, etc. In short, create the topic at the subscriber side and advertise so that others can publish. You can get multiple subscribers on the same connection and get concurrent processing using multiple sessions.
Can two JMS servers share the same persistent store?

No. Each JMS server must have its own unique persistent store. Two file-based JMS persistent stores may share the same directory, but their messages will be stored in different files. In this case, the filenames will contain different prefixes. Two JDBC-based JMS persistent stores may share the same database, but they must be configured to use a different Prefix Name which will be prepended to the database tables. For more information on configuring the JDBC Prefix Name, see "JMS JDBC Stores" in the Administration Console Online Help. If they are configured with the same Prefix Name, persistent messages will be corrupted and/or lost.

Which types of JDBC databases does WebLogic JMS support?


The JMS database can be any database that is accessible through a JDBC driver. WebLogic supports and provides JDBC drivers for the following databases: * Cloudscape * Informix * Microsoft SQL (MSSQL) Server (Versions 6.5 and 7) * Oracle (Version 8.1.6) * Sybase (Version 12)

How do I use a third-party JDBC driver with JMS?


If your JDBC driver is not included in the list of drivers in the question about JDBC databases supported by WebLogic JMS, then the tables required by JMS must be created manually. Note: WebLogic Server only guarantees support for the JDBC drivers included in the previous list. Support for any other JDBC driver is not guaranteed. The .ddl files located in the weblogic/jms/ddl directory of the weblogic.jar file may be used as templates. Use the jar utility supplied with the JDK to extract them to the weblogic/jms/ddl directory using the following command: jar xf weblogic.jar weblogic/jms/ddl Note: If you omit the second parameter (weblogic/jms/ddl), the entire jar file is extracted. Follow the procedures in JDBC Database Utility in Programming WebLogic JMS to manually create the database tables for the JDBC store. Another option is to consider using a file store instead of a JDBC store. File stores are easier to configure and may provide significantly better performance.
The Multicast TTL setting for a cluster in the WebLogic Admin console sets which of the following values?

a. Maximum time taken for multicast messages to reach their final destination b. The number of routers a multicast message can pass through before the packet can be discarded

c. The multicast address to be used by the messages sent from the cluster d. Minimum time taken for broadcasting a multicast message from the cluster Choice B is correct. The Multicast TTL(TTL-Time to Live) setting specifies the number of routers a multicast message can pass through before the packet can be discarded. To configure the multicast TTL for a cluster, you should change the Multicast TTL value in the WebLogic Server administration console. This sets the number of network hops a multicast message makes before the packet can be discarded. If you choose to distribute a cluster over a WAN (or across multiple subnets), you must plan and configure your network topology to ensure that multicast messages are reliably transmitted to all servers in the cluster. One of the requirements to be met by the network is that the multicast Time To Live (TTL) value must be high enough to ensure that routers do not discard multicast packets before they reach their final destination.
Which of the following algorithms is used by the WebLogic Server as the default load balancing strategy for clustered object stubs when no algorithm is specified ?

a. Round-robin b. Weight-based c. Random d. None of the above 8. Choice A is correct. The basic idea behind load balancing is that by distributing the load proportionally among all the servers in the cluster, the servers can each run at full capacity. WebLogic Server clusters support several algorithms for load balancing clustered objects. The particular algorithm you choose is maintained within the replicaaware stub obtained for the clustered object. Configurable algorithms for load balancing clustered objects are: Round-robin, Weight-based and Random. WebLogic Server uses the round-robin algorithm as the default load balancing strategy for clustered object stubs when no algorithm is specified. Round-robin is the only load balancing strategy used by WebLogic proxy plug-ins for HTTP session state clustering. The round-robin algorithm cycles through a list of WebLogic Server instances in order. For clustered objects, the server list consists of WebLogic Server instances that host the clustered object. For proxy plug-ins, the list consists of all WebLogic Servers that host the clustered servlet or JSP.
How do I use persistence?

Use the following guidelines: 1. Make sure the JMSServer you are using has a store configured. The JMSServer configuration entry in the config.xml file should contain a line of the form Store="" Note that if JMS boots without a store configured, it is assumed the customer did not want one, and persistent messages are silently downgraded to non-persistent (as specified for JMS 1.0.2). 2. Make sure you are not using "Message.setJMSDeliveryMode". This is overwritten, as it is a vendor-only method. 3. Make sure you are calling either: QueueSender.send(msg, deliveryMode, ...) -- or -QueueSender.setDeliveryMode(deliveryMode) -- or -set the DefaultDeliveryMode mode on connection factory in the config.xml file to persistent (the QueueSender.setDeliver/send overrides this value). Similarly, for topics, you would set this via the TopicPublisher.

4. Make sure you don't have "DeliveryModeOverride" set to Non-Persistent on the Destination in the config.xml file. 5. If you are using pub/sub, only durable subscriptions persist messages. Non-durable subscriptions have no need to persist messages, as by definition they only exist for the life of the server. 6. If you are using JDBC, the JDBC tables, JMSSTATE and JMSSTORE, are created automatically when the JMS server boots. The DDL files used to create the tables are stored in weblogic.jar in weblogic/jms/ddl. The example configuration below shows a JDBC store for Oracle (client version 8.1.7 or later is needed to run with WLS 6.1 on JDK 1.3). To manually create the tables (also deleting any existing tables), run java utils.Schema as described in the previous question. See the question, "How do I start WLS and configure JMS?" for a description of how to configure JMS. Here is a sample config.xml file resulting from configuring JMS. It should look similar to yours. If you want JMS to use a file store instead of a database, just change JDBCStore to FileStore in the JMSServer section. ListenPort="7001" DefaultProtocol="t3" ThreadPoolSize="8" > GuestDisabled="false" /> FileRealm="defaultFileRealm" /> <FileRealm Name="defaultFileRealm" /> TemporaryTemplate="TestTemplate1" Targets="myserver" Store="JDBCStore"> JNDIName="jms.queue.TestQueue1" Template="TestTemplate1" /> <JMSTemplate Name="TestTemplate1" /> <JMSFileStore Name="FileStore" Directory="myfilestore" JMSServer="TestJMSServer" /> ConnectionPool="testpool2" JMSServer="TestJMSServer" /> <JDBCConnectionPool Name="testpool2" Targets="myserver" URL="jdbc:weblogic:oracle" DriverName="weblogic.jdbc.oci.Driver" InitialCapacity="0" MaxCapacity="1" CapacityIncrement="1" Properties="user=SCOTT;password=tiger;server=bay816" /> The following is a sample class that sends a Topic message on construction: import javax.naming.*;

import javax.jms.*; import java.util.Hashtable; public class t { public final static String DESTINATION="jms.topic.TestTopic1"; private private private private private private TopicConnectionFactory connectionFactory; TopicConnection connection; TopicSession session; TopicPublisher producer; TextMessage message; Topic destination;

public t() { try { Hashtable env = new Hashtable(); env.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory"); env.put(Context.PROVIDER_URL, "t3://localhost:7001"); InitialContext ctx = new InitialContext(env); destination = (Topic) ctx.lookup(DESTINATION); connectionFactory = (TopicConnectionFactory) ctx.lookup("javax.jms.TopicConnectionFactory"); connection = (TopicConnection) connectionFactory.createTopicConnection(); session = (TopicSession) connection.createTopicSession(false, Session.AUTO_ACKNOWLEDGE); producer = (TopicPublisher) session.createPublisher(destination); producer.setDeliveryMode(DeliveryMode.PERSISTENT); message = (TextMessage) session.createTextMessage(); message.setText("hello world"); producer.publish(message); } catch (Exception e) { } } }

How does a file store compare with a JDBC store?


The following are some similarities and differences between file stores and JDBC stores: * Both have the same transaction semantics, including rolling back transactions (e.g., received messages are put back on the queue). * Both have the same application interface (no difference in application code). * The file store should be much faster. * JDBC may make it easier to handle failure recovery since the JDBC interface can access the database from any client machine; with the file store, the disk must be shared or migrated. * File store reliability is limited to reliability of disk and O/S; run it on Veritas or a RAID 5 system. Database reliability may be higher. * File stores will require more memory, but perhaps not significantly more; it depends on how fragmented the file store gets, if the application works roughly * FIFO it shouldn't get very fragmented at all. * File stores generate no additional network traffic, database stores do if the database server is on a different JVM or machine.
How do the WLS JMS 6.1 server/destination message maximum and threshold values work?

The byte and message maximum values are quotas - not flow control. Message quotas prevent a WebLogic JMS server from filling up with messages and possibly running out of memory, causing unexpected results. When you reach your quota, JMS prevents further sends with a ResourceAllocationException (rather than blocking). You can set quotas on individual destinations or on a server as a whole. The thresholds are also not flow control - though they would be better suited to that application than the quotas. The thresholds are simply settings that when exceeded cause a message to be logged to the console to let you know that you are falling behind. Note that the messages maximum setting on a connection factory is not a quota. This specifies the maximum numbers of outstanding messages that can exist after they have been pushed from the server but before an asynchronous consumer has seen them; it defaults to a value of 10.
How do I configure JDBC so that the JMS JDBC Store recovers automatically?

Several customers have reported a problem where they are using a JDBC store, the DBMS goes down and back up, but JMS can no longer use the store until WLS is shutdown and restarted. You can get around this problem by configuring the following attributes on the JDBC Connection Pool associated with the JMSJDBCStore: TestConnectionsOnReserve="true"\ TestTableName="[[[catalog.]schema.]prefix]JMSState" If they are not set, then if the JDBC resource goes down and comes back up, JMS cannot re-use the connection pool until WLS is shutdown and restarted. This has been tested against WLS 6.0 SP02 and WLS 6.1.
Does WebLogic JMS support clustering?

WebLogic JMS supports cluster-wide, transparent access to destinations from any server in the cluster. A system administrator can establish cluster-wide, transparent access to destinations from any server in the cluster by configuring multiple connection factories and using targets to assign them to WebLogic Servers. Each connection factory can be deployed on multiple WebLogic Servers. The application uses the Java Naming and Directory Interface (JNDI) to look up a connection factory and create a connection to establish communication with a JMS server. Each JMS server handles requests for a set of destinations. Requests for destinations not handled by a JMS server are forwarded to the appropriate server. You can configure multiple JMS servers on the various nodes in the cluster as long as you give them different names. You can assign destinations to the various JMS servers. One problem to be aware of is the propagation delay in replicating entries in JNDI. If you have an MDB deployed on one node but reference a destination on another node, the deployment may fail with a javax.naming.NamingException exception. The problem occurs because the server is not synced up to the JNDI from the remote server (JMS server) yet, so the JNDI lookup of destination as part of MDB deployment will fail. One workaround is for each MDB to reference a local destination. Another approach is deploy the MDBs after the server boots (plus a delay for JNDI propagation). To get around losing messages before the MDB is deployed, use durable subscribers. This problem is fixed for MDBs in WLS 6.1, where the MDB will be deployed and reconnection will be retried until the destination is available. Note that this is still a problem for EJBs in general that try to reference a non-local JMS destination.
How do I do HTTP tunneling?

If you want to use HTTP tunneling (wrap every message in HTTP to get through a firewall), you need to add TunnelingEnabled="true" into your &lr;ver> definition in the config.xml file or check the appropriate box on the console. Then use a URL like http://localhost:7001 instead of t3://localhost:7001 for Context.PROVIDER_URL when getting your InitialContext. If you want HTTP tunneling with SSL, use https://localhost:7002 (where https uses HTTP tunneling with SSL and 7002 is the

secure port that you configured). You will pay a performance penalty for doing this, so only use tunneling it if you really need to (i.e., need to go through a firewall).
Which of the following statements are true regarding the identity of two EJBs?

a. Two stateful session beans are identical if their data attributes are identical. b. Two stateful session beans are identical if their session contexts are equal. c. Two stateless session beans are identical if they are of the same type. d. Two stateless session beans are identical if their session contexts are equal. e. Two entity beans are identical if they have same primary key but different home interface. f. Two entity beans are identical if they have different primary key but same home interface. B and C are correct. Since the stateful session beans maintain the conversational state of the clients, they are identical when their session contexts are equal. Two stateful session beans may have identical data attributes, but if the session contexts are different they are not identical. Thus choice A is incorrect and B is correct. Since stateless beans do not retain the conversational state, they are considered identical if they are of the same type. Thus choice C is correct. If two entity objects have the same home interface and primary key, they are considered identical. The EJB specification does not mention object equality based on the = = operator. Also, if you compare two object references using the Java API, Object.equals(Object obj), the result is unspecified. The only way to compare object equality is through the isIdentical (EJBObject) API. Thus choice E and F are incorrect.
Why is my JMS work not part of a user transaction (i.e., called within a transaction but not rolled back appropriately)? How do I track down transaction problems?

Usually this problem is caused by explicitly using a transacted session which ignores the external, global transaction by design (JMS spec requirement). A transacted JMS session always has its own inner transaction. It is not affected by any transaction context that the caller may have. It may also be caused by using a connection factory that is configured with "UserTransactionsEnabled" set to false. 1. You can check if the current thread is in a transaction by adding these two import lines: import javax.transaction.* import weblogic.transaction.*; and adding the following lines (i.e., just after the begin and just before every operation). Transaction tran = TxHelper.getTransaction(); System.out.println(tran); System.out.println(TxHelper.status2String(tran.getStatus())); This should give a clear idea of when new transactions are starting and when infection is occurring. 2. Ensure that the thread sending the JMS message is infected with a transaction. Check that the code is not using a transacted session by setting the first parameter of createQueueSession or createTopicSession to false. Note that creating the connection and/or session is orthogonal to the transaction. You can begin your transaction before or after. You need only start the transaction before you send or receive messages. 3. Check that the UserTransactionsEnabled flag is explicitly set to true for the connection factory in the config.xml file since the default for user-configured connection factories for this value is false. If you are using one of the pre-configured connection factories they are set as follows: weblogic.jms.ConnectionFactory disables user transactions so don't use this one for the case where user transactions are desired;

javax.jms.QueueConnectionFactory and javax.jms.TopicConnectionFactory enable user transactions. 4. You can trace JTA operations by starting the server with this additional property: -Dweblogic.Debug.DebugJMSXA=true You should see trace statements like these in the log: XA ! XA(3163720,487900) This can be used to ensure that JMS is infected with the transaction.

In the WebLogic server, if stateless session bean instances are getting frequently created and removed, performance can improved by setting a high value for which of the following?
a. max-beans-in-free-pool b. max-beans-in-cache c. max-beans-in-memory d. max-stateless-beans-in-cache Choice A is correct. WebLogic Server maintains a free pool of EJBs for every stateless session bean class. The max-beans-in-free-pool element defines the size of this pool. By default, max-beans-in-free-pool has no limit; the maximum number of beans in the free pool is limited only by the available memory. When EJBs are created, the session bean instance is created and given an identity. When the client removes a bean, the bean instance is placed in the free pool. When you create a subsequent bean, you can avoid object allocation by reusing the previous instance that is in the free pool. So the max-beans-in-free-pool element can improve performance if EJBs are frequently created and removed. Keeping this parameter too high uses extra memory and keeping it too low causes unnecessary object creation. WebLogic Server allows you to configure the number of active beans that are present in the EJB cache (the in-memory space where beans exist). The max-beans-in-cache element specifies the maximum number of objects of this class that are allowed in memory. When max-bean-in-cache is reached, WebLogic Server passivates some EJBs that have not been recently used by a client. Choices C and D are not valid properties.
How can an application do a JMS operation and have it succeed, independent of the result of the transaction?

Basically, the JMS operation must be done using a transacted session or the transaction must be suspended/disabled as follows (pick one or more of the following). 1. Suspend the current transaction prior to making the JMS call and resume it after completing it. The code looks something like this: import javax.transaction.Transaction; import javax.transaction.TransactionManager; TransactionManager tranManager= TxHelper.getTransactionManager(); Transaction saveTx = null; try { saveTx = tranManager.suspend(); ... do JMS work, it will not participate in transaction } finally { // must always resume suspended transactions! if (saveTx != null) tranManager.resume(saveTx); } 2. Use a transacted session by specifying true for the first parameter to createQueueSession or createTopicSession. 3. Use a connection factory with user transactions disabled. That is, check that the UserTransactionsEnabled flag is explicitly set to false for the connection factory in the config.xml file or use the default for a user-configured connection factory for this value

which is false. The pre-configured connection factory weblogic.jms.ConnectionFactory disables user transactions. A transacted JMS session always has its own inner transaction. It is not affected by any transaction context that the caller may have. A non-transacted JMS session is more complicated. If you use the WLS 6.1 default factory weblogic.jms.ConnectionFactory, the session does not participate in a user transaction because the UserTransactionsEnabled flag is set to "False". If you use the deprecated default factory javax.jms.QueueConnectionFactory or javax.jms.TopicConnectionFactory or you define your own factory and set the UserTransactionsEnabled flag to "True", the JMS session participates in the outer transaction, if one exists and the JMS session is not transacted.
What happens if acknowledge() is called within a transaction?

As per the JMS specification, when you are in a transaction, the acknowledgeMode is ignored. If acknowledge() is called within a transaction, it is ignored.
Is it possible to set aside a message and acknowledge it later?

There are no special primitives for doing this. Here are two possible solutions. One approach is to use multiple sessions as in the following: while (true) { Create a session, subscribe to one message on durable subscription Close session Save session reference in memory To acknowledge the message, find the session reference and call acknowledge() on it. } Another solution is to use transactions and suspend the work as follows: start transaction while(true) { message = receive(); if (message is one that I can handle) process the message commit } else { suspend transaction put transaction aside with message start transaction } } To "acknowledge" the message: resume user transaction commit To "recover" the message: resume user transaction rollback Each time you suspend, you need to push the transaction onto a stack or list possibly with the message so you can process it or roll it back later. This solution is high overhead in that there can be a large build up of outstanding transactions. Note that transactions have timeouts and it may rollback on its own, which means you can get the message again (in a different transaction). Note also that there are some practical limits on the number of transactions you should leave outstanding. The default limit is something like 10000. Eventually you want to go back to your stack/list and commit/rollback the transactions. Note that transaction references (javax.transaction.Transaction) are not Serializable.

How should I use sorted queues?

Destination keys are used to define the sort order for a specific destination. Destination keys can be message header or property fields. For a list of valid message header and property fields, refer to the Programming WebLogic JMS. Queues can be sorted in ascending or descending order based on the destination key. A destination is considered to be first-in-first-out if a destination key is defined as ascending for the JMSMessageID message header field, and last-in-first-out if defined as descending. The key defined for the JMSMessageID header field, if specified, must be the last key defined in the list of keys. You can define multiple destination keys to sort a destination.

Which of the following attributes in the Monitoring tab for a JDBC connection pool in the Administrative console tell us how many clients are currently waiting for a connection?
a. Waiters high b. Waiters c. Connections high d. Clients e. Wait seconds high Choice B is correct. JDBC subsystem resources can also be monitored via the Administration Console. The Monitoring tab for a JDBC connection pool allows you to access a table listing statistics for the instances of that pool. These attributes provide important information for managing client database access. The Waiters High field indicates the highest number of clients waiting for a connection at one time. The Waiters field tells you how many clients are currently waiting for a connection. The Connections High field indicates the highest number of connections that have occurred at one time. The Wait Seconds High field tells you the longest duration a client has had to wait for a database connection. These attributes allow you to gauge the effectiveness of the current configuration in responding to client requests.
The MaxPostTimeSecs attribute set in the Administration console under Servers or virtual hosts section corresponds to which of the following?

a. The amount of time that WebLogic Server waits between receiving chunks of data in an HTTP POST. b. The total amount of time that WebLogic Server spends receiving HTTP POST data. c. The time spent by WebLogic server to post data to other servers in the cluster. d. The number of bytes of data received in a POST from a single request. Choice B is correct. Web servers may face denial-of-service attacks, which is usually carried out by sending huge amounts of data in an HTTP POST method. You can set three attributes in WebLogic Server that help prevent this type of attack. These attributes are set in the console, under Servers or virtual hosts. You can limit the amount of time that WebLogic Server waits between receiving chunks of data in an HTTP POST by setting the attribute PostTimeoutSecs. The MaxPostTimeSecs attribute limits the total amount of time that WebLogic Server spends receiving post data. If this limit is triggered, a PostTimeoutException is thrown and a message is sent to the server log. MaxPostSize attribute limits the number of bytes of data received in a POST from a single request. If this limit is triggered, a MaxPostSizeExceeded exception is thrown and a message is sent to the server log.
How does sorting on message priority work?

First, you need to add a key to the destination (by default, they are not sorted), choosing JMSPriority as the key. If you want 0 to be your highest priority, make the key ascending. If you want 9 to be the highest priority, make the key descending. Second, the priority must be set using either the producer or on the send, not the message. Third, the priority sorting only comes into play if there are multiple messages waiting on the queue. If the receiver is always caught up with the sender, then the messages will be processed in the order in which they come in.

How do I get a thread dump to help track down a problem?

Ways to get a thread dump: * Try running this from the command line (after running the setEnv script in /bea/wlserver6.1/config/mydomain/): java weblogic.Admin -url t3://localhost:7001 THREAD_DUMP * On Windows, from the console window, enter Ctrl+Break. * On UNIX, signal the server using kill -3.
How do I manage a queue to view and delete specific messages?

Write a program that uses a QueueBrowser. Then delete specific messages by using a selector with the message identifier as in the following example: String selector = "JMSMessageID = '" + message.getMessageID() + "'"; Keep in mind that the queue browser is a not a "live" view of the queue. It is a snapshot.
Why do I get an exception when trying to find a connection factory?

The exception is usually something like java.io.InvalidClassException or java.lang.NoClassDefFoundError. Make sure weblogic.jar is in the CLASSPATH of the client. Also make sure you have the correct Java run-time jar files included (i.e., you might need rt.jar).
What precautions should I take when I use blocking receive() calls?

If your application design requires messages to be received synchronously, we recommend using one of the following methods listed in order of preference: * Pass a timeout value as an argument to the receive() method and set it to the minimum value greater than zero, that is allowed by the application to avoid consuming threads that are waiting for a response from the server. * Use the receiveNoWait() method which returns the next message or a null value if no message is currently available. In this case, the call does not block. The servlet should provide a way to return to or reschedule the request, without calling wait(). Note: Use of this option should be minimized, as it may deadlock a busy server. * Ensure that more threads are configured than the number of possible simultaneous blocking receive() calls.
What is the NO_ACKNOWLEDGE acknowledge mode used for?

The NO_ACKNOWLEDGE acknowledge mode indicates that received messages do not need to be specifically acknowledged which improves performance, but risks that messages are lost. This mode is supported for applications that do not require the quality of service provided by session acknowledge and that do not want to incur the associated overhead. v Messages sent to a NO_ACKNOWLEDGE session are immediately deleted from the server. Messages received in this mode are not recovered and, as a result, messages may be lost and/or duplicate message may be delivered if an initial attempt to deliver a message fails. Note: You should avoid using this mode if your application cannot handle lost or duplicate messages. Duplicate messages may be sent if an initial attempt to deliver a message fails. In addition, we do not recommend that this acknowledge mode be used with persistent messaging, as it implies a quality of service that may be too low for persistent messaging to be useful.
When should I use multicast subscribers?

Multicasting enables the delivery of messages to a select group of hosts that subsequently forwards the messages to multicast subscribers. The benefits of multicasting include: * Near real-time delivery of messages to host group. * High scalability due to the reduction in the amount of resources required by the JMS server to deliver messages to multicast subscribers. Note: Multicasting is only supported for the Pub/sub messaging model.

For an example of when multicasting might be useful, consider a stock ticker. When accessing stock quotes, timely delivery is more important than reliability. When accessing the stock information in real-time, if all, or a portion, of the contents is not delivered, the client can simply request the information be resent. Clients would not want to have the information recovered in this case because by the time it is redelivered it would be out-of-date. Multicast messages are not guaranteed to be delivered to all members of the host group. For messages requiring reliable delivery and recovery, you should not use multicasting.
When should I use server session pools and connection consumers?

WebLogic JMS implements an optional JMS facility for defining a server-managed pool of server sessions. This facility enables an application to process messages concurrently. A ConnectionConsumer object uses a server session to process received messages. If message traffic is heavy, the connection consumer can load each server session with multiple messages to minimize thread context switching. Multiple connection consumers can share server sessions in a server session pool. To learn how to use the connection consumers within an application, see the section Processing Messages Concurrently in Programming WebLogic JMS, or the javax.jms.ConnectionConsumer javadoc. Note: Server session pools can also be implemented using Message Driven Beans. Using MDBs is preferable to using server session pools - see the answer to the question, "How do server session pools and Message Driven Beans compare?" For information on using message driven beans to implement server session pools, see Programming WebLogic Enterprise JavaBeans.

How do I issue the close() method within an onMessage() method call and what are the semantics of the close() method?
If you wish to issue the close() method within an onMessage() method call, the system administrator must select the Allow Close In OnMessage check box when configuring the connection factory. For more information, see JMS Connection Factories in the Administration Console Online Help. If this check box is not selected and you issue the close() method within an onMessage() method call, the call will hang. The close() method performs the following steps to execute an orderly shutdown: * Terminates the receipt of all pending messages. Applications may return a message or null if a message was not available at the time of the close. * Waits until all message listeners that are currently processing messages have completed (except for the message listener from which the close() method is being called). * Rolls back in-process transactions on its transacted sessions (unless such transactions are part of an external JTA user transaction). * Does not force an acknowledge of client-acknowledged sessions. By not forcing an acknowledge, no messages are lost for queues and durable subscriptions that require reliable processing. When you close a connection, all associated objects are also closed. You can continue to use the message objects created or received via the connection, except the received message's acknowledge() method. Closing a closed connection has no effect. Note: Attempting to acknowledge a received message from a closed connection's session throws an IllegalStateException. When you close a session, all associated producers and consumers are also closed. For more information about the impact of the close() method for each object, see the appropriate javax.jms javadoc.
How do I publish an XML message?

Follow these steps: 1. Generate XML from the DOM document tree.

2. Serialize the generated DOM document to a StringWriter. 3. Call toString on the StringWriter and pass it into message.setText. 4. Publish the message.
A client wants to preserve the reference to the EJBhome object of an enterprise bean instance and use it later. Which of the following can be serialized for this purpose ?

a. home b. Handle c. homeHandle d. EJBhomeHandle e. homeObject Choice C is correct. Once a client has obtained the EJBhome object for an EJB instance, it can create a reference to the home object by calling gethomeHandle(). gethomeHandle() returns a homeHandle object, which can be used to obtain the home interface to the same EJB instance at a later time. A client can pass the homeHandle object as arguments to another client, and the receiving client can use the handle to obtain a reference to the same EJBhome object. Clients can also serialize the homeHandle and store it in a file for later use. The homeHandle interface has only one method getEJBhome(), which returns the EJBhome reference.
Is it possible to send or receive a message from within a message listener?

Yes. You can send to or receive from any queue or topic from within in a message listener. If it's not an MDB, you can use the same Connection or Session that the onMessage() is part of to do this. When you create your message listener, you pass in a session in your constructor. Then you have access to the session in your onMessage method and you would be able to make synchronous, not asynchronous, calls from within the onMessage method. Do not use another Session that is servicing another onMessage() because that would multi-thread that Session and Sessions don't support multithreading. When things are done non-transactionally, there can be duplicates or lost messages (assuming your onMessage() code is attempting to forward messages): 1. If you call acknowledge after the publish() and the acknowledge fails for whatever reason (network/server failure), then you will see the message again and will end up publishing twice (possible duplicate semantics). You can try to keep track of sequence numbers to detect duplicates but this is not easy. 2. If you call acknowledge before the publish(), you get at-most-once semantics. If the publish() fails, you don't know if the failure occurred before or after the message reached the server. If you want exactly once, transactional semantics using onMessage, you must use transactional MDBs. The onMessage() for a transactional MDB starts the transaction, includes the WebLogic Server JMS message received within that transaction and the publish() would also be in the same transaction. The following code sends a response to each message that it receives. It creates the connection, etc. in the ejbCreate method so that it doesn't need to create it every time onMessage is called. The QueueSender is anonymous (null Queue) since we don't know to whom we will have to reply. The ejbRemove method cleans up by closing the connection. This same approach can be used to create a receiver, subscriber or publisher. import javax.ejb.CreateException; import javax.ejb.EJBContext; import javax.naming.*; import javax.naming.directory.*; import java.util.Hashtable; import javax.ejb.MessageDrivenBean; import javax.ejb.MessageDrivenContext; import javax.jms.*; public class MDB implements MessageDrivenBean, MessageListener { public static final String WLSqcf = "javax.jms.QueueConnectionFactory";

public static final String WLSqname = "jms.queue.TestQueue1"; public static final String WLSurl = "t3://localhost:7001"; public static final String WLSJNDIfactory = "weblogic.jndi.WLInitialContextFactory"; private MessageDrivenContext context; private QueueSession session; private QueueConnection connection = null; private QueueConnectionFactory factory; private InitialContext ctx; private QueueSender QueueSender; // Required - public constructor with no argument public MDB() {} // Required - ejbActivate public void ejbActivate() {} // Required - ejbRemove public void ejbRemove() { context = null; if (connection != null) { try { connection.close(); } catch(Exception e) {} connection = null; } } // Required - ejbPassivate public void ejbPassivate() {} public void setMessageDrivenContext( MessageDrivenContext mycontext) { context = mycontext; } // Required - ejbCreate() with no arguments public void ejbCreate () throws CreateException { try { // Get the initial context Hashtable env = new Hashtable(); env.put(Context.INITIAL_CONTEXT_FACTORY, WLSJNDIfactory); env.put(Context.PROVIDER_URL, WLSurl); env.put(Context.REFERRAL, "throw"); ctx = new InitialContext(env); factory = (QueueConnectionFactory)ctx.lookup(WLSqcf); // Create a QueueConnection, QueueSession, QueueSender connection = factory.createQueueConnection(); session = connection.createQueueSession(false, Session.AUTO_ACKNOWLEDGE); queueSender = session.createSender(null); connection.start(); } catch (Exception e) { throw(new CreateException(e.toString())); } } // Implementation of MessageListener // Throws no exceptions public void onMessage(Message msg) { try {

System.out.println("MDB: " + ((TextMessage)msg).getText()); msg.clearBody(); ((TextMessage)msg).setText("reply message"); queueSender.send((Queue)msg.getJMSReplyTo(), msg); } catch(Exception e) { // Catch any exception e.printStackTrace(); } } } This approach creates a connection per EJB/MDB instance, so you might want to create a producer pool that is shared by the EJB instances. This is done by writing a class that populates a static pool with producers (see the next question for a sample producer pool). The onMessage call grabs a producer when needed. Since Sessions must be single threaded, make sure there is only one producer per session within the producer pool.

How do I create a producer pool?


The following is some pseudo-code for a producer class. class ProducerPool { static Hashmap pSets = new Hashtable(); static Hashmap inUse = new Hashtable(); QueueSender get(String contextURL, String connectionFactoryName, String destinationName) { String lookup = contextURL+"; "+connectionFactName+";"+destName; synchronized(pSets) { producer set = pSets.get(lookup); if (set != null && set not empty) qs = set.removeFirst(); } if (producer == null) { create ctx get connect factory create connection create session look up destination qs = create queue sender } synchronized(inUse) { inUse.put(qs, lookup); } return qs; } void put(QueueSender qs) { String lookup; synchronized(inUse) { lookup = inUse.remove(p); } synchronzied(pSets) { producer set = pSets.get(lookup); if (set == null) { producer set = new producer set

pSets.put(lookup, producer set); } producer set.add(qs); } } } Note: Static classes may be garbage collected if there are no references to them, so make sure the application server has a permanent pointer to them in some manner. One way is to reference it permanently from within a servlet or EJB when they are initialized at startup. Here is an example of using the producer pool within the onMessage method. onMessage() { QueueSender qs = ProducerPool.get(...); qs.send(...); ProducerPool.put(qs); } You can pre-populate this pool by calling it from a startup class or a load-on-start servlet class.
What are pending messages in the console?

Pending means the message could have been: * sent in a transaction but not committed. * received and not acknowledged. * received and not committed. * subject to a redelivery delay (as of WebLogic Server 6.1). * subject to a delivery time (as of WebLogic Server 6.1). A rolled back message remains pending until the transaction actually rolls back. Rolling it back multiple times does not cause double counting, nor does an exception that set a transaction as rollbackOnly followed by an actual rollback. Current implies messages that are not pending. Total implies total since server last started. The byte counts only consider the payload of messages which includes the properties and the body but not the header.
How do I use a less than or greater than on a message selector in ejb-jar.xml?

Enclose the selector in a CDATA section. That will prevent the XML parser from thinking that less than or greater than is a tag. <jms-message-selector> 'user' ]]>

Is it better to have more or fewer sessions for a given number of subscribers?

Using N sessions for N subscribers gives you concurrency up to N simultaneous threads of execution provided you have as many threads to work with. Each Session gets its own thread as long as there are enough threads available. Otherwise, the sessions serially reuse the available threads. One session for N subscribers serializes all subscribers through that one session. If the load is heavy they may not be able to keep up without the extra threads. If you are using CLIENT_ACKNOWLEDGE, N sessions gives you N separate message streams that can be individually recovered. Having one session crosses the streams giving you less control.
Match the EJB functions given below with the functionality equivalent in SQL

A.) ejbStore() 1.) INSERT B.) ejbLoad() 2.) UPDATE C.) ejbCreate() 3.) SELECT a. A->1, B->2, C->3 b. A->2, B->1, C->3 c. A->3, B->2, C->1 d. A->1, B->3, C->2 e. A->2, B->3, C->1 f. A->3, B->1, C->2

Choice E is correct. When the create() method on a home interface is invoked, the container delegates the create() method call to the bean instance's matching ejbCreate() method. The ejbCreate() methods are used to initialize the instance state before record is inserted into the database. The ejbCreate() method is analogous to INSERT. The ejbStore() method is invoked just before the container the container is about to write the bean container-managed fields to the database. It is analogous to the UPDATE . The ejbLoad() is invoked just after the container has refreshed the bean containermanaged files with its state from the database. It is analogous to the SELECT. Thus choice E is correct and others are not.
A client invokes a method on a stateful session bean instance deployed in the WebLogic Server. While the method execution is in progress another method call arrives on the server. What will be the result?

a. RemoteException is thrown if the value of concurrency-strategy property is false b. EJBException is thrown if the value of concurrency-strategy property is false c. The EJB container blocks the concurrent method call and allows it to proceed when the previous call has completed if the value of allow-concurrent-calls is true d. In all cases, RemoteException is thrown Choice C is correct. By default, simultaneous access to a stateful session EJB results in a RemoteException. However, you can set the allow-concurrent-calls option in the WebLogic EJB deployment descriptor to specify that a stateful session bean instance will allow concurrent method calls. This access restriction on stateful session EJBs applies whether the EJB client is remote or internal to WebLogic Server. By default, allows-concurrent-calls is false. However, when this value is set to true, the EJB container blocks the concurrent method call and allows it to proceed when the previous call has completed. The concurrency-strategy element determines ejbLoad() and ejbStore() behavior for entity EJB instances.
Q: What do you mean by weighted based server instance? How do you configure it? Ans: The Weblogic Servers in the clustered environment could be routed in 6 ways ROUND-ROBIN, WEIGHT-BASED, RANDOM and same algorithms with Affinity. Weight is defined as the number of the requests incoming to a managed server that is default 100. As per the machine capacity and Operating environments will make you to deside how much weight is suggested on that managed server. We can control the incoming requests using weights increase or decrease, So, this way we can route all the request to one of the managed server in the Cluster. This Weight differences can be used when there is operating environment differences are there. Q: How to enable EJB available to servlet? asume servlet on apache, ejb on Weblogic cluster. Ans:Any external access to EJB is not allowed. if the apache webserver already configure as frontend. then we need to look up by JNDI tree. Q: What is the silent mode installation file contains root element? When do you require this mode of installation? Ans:The root element in silent.xml is <install>This kind of mode usually required in two different situations. Situation1 : Weblogic clusters could be installed/implemented only on homogenous environments. If cluster1 is constructed with MgdServer1, MgdServer2if one server isusing Weblogic 7 environment and other one on Weblogic 8.1 or higher this is not allowed.

Situation 2: When one huge project is migrated from one physical location to other, Where the Application specialist must have the similar environment as the Production Server had. To prepare Development work with similar kind environment we shall install on First system same as Production Server rest of the developers systems could be installed with silent mode. Q: What are the basic configuraiton requirements for a Cluster? or Why do you need multicast address in Clustering? Ans: The Multicast address is must for clustering, If server instance need to join the cluster it will use multicast address. The Administrator server handles the web/resource request which is incoming to the Weblogic server then the admin server will send poll messages for availability to handle the current incoming request by which member server in the cluster with multicasting. The multicast address should not conflict with the Network configurations on every member server. The range of multicast IP address is : 224.0.0.0 to 239.255.255.255.The admin server sends a TTL (Time to Leave) packet,which will acknowledges the readiness of a managed server. If more than one member server is available then it will choose the member server with first come first server bases. Q: What are all the ANT command options? Ans:To view all options of ant command is simple, just use the following command : prompt> ant -help

Note: This will work on Unix and Windows too iff PATH is pointing to ant specific jars Q: What is the ANT version last you used? How to get it?? Ans: I am using Weblogic 8.1 it internally provides ant support which is 1.5.6 version.To get this simply use : prompt> ant -version Q: How do you config eclipse with Weblogic? Amazon.com Widgets Ans:Weblogic version wise plug-ins are available for free download sites. Eg: lomboz tool it is a very simple tool, my experience is that deployment on WL is very few steps required.Just we need to copy the plug-in extracted to eclipse/plug-ins folder. Here we need to follow the correct J2EE specification for easy deployments of application. Q: what is the source to identifying the Connection pool failure? What is the remedy? Ans: In WL 7/8 to identify the Connection pool failure we have 3 options: 1.The Connection pool hosting Server instance healthchecking by Monitoring tab where we need to find the idle thread availability.2. Checking in the weblogic log of that corresponding server instance. Usually we get broken pipe Exception.This could be generated due to overload on connection pool. To resolve we can tune the execute threads for the corresponding server instance.3. Look for Thread dump and identify the which thread is doing which task execution?

Q: What is Thread Dump? Why we need it? How do we get it? Ans:Thread dump concept is used only by Admin users who operates the production server; it is the dump of the behavior of the WebLogic server instances execute threads.When the thread dumps helpful? If WLS execute threads misbehaving due to following reasons Maybe you just need more threads. Maybe you need some of your application to use a different queue. Maybe your application needs tuning.There is a need of trouble shoots the issues due to various reasons: 1. Requests overloaded 2. Connection Pool fails 3. File cannot read/write for any application (which might be xml file too) 4. Queues are overloaded or back-end legacy connection issues Amazon.com Widgets In windows CTRL + Break , There is another common method to get thread dump: a) Open a cmd window (in Windows) or shell (in Unix/Linux) b) Set the proper java path and add weblogic.jar to the classpath c) Run the following command script :prompt >java weblogic.Admin -url t3://host:port -username weblogic -password weblogic THREAD_DUMP Here please replace with the correct host, port number, username and password. You can get the thread dump from the standard output.

Best WebLogic (JVM ) Thread Dump analyzer are: 1. Samurai 2. Java TDA 3. Thread Dump Viewer 4. Eclipse lock analyzer plugin

Q: What is the procedure for Queues config? How to make them to free? Ans: 1. The Queues configuration requires persistence storage which could be a File on operating system or a DataSource. 2. The queue configuration requires JMSConnectionFactory, JMSServer, jms module Queue or topic as per the application need You can created using the Weblogic Administration console or using WLST in latest versions 9.x onwards.

1. What are deployment descriptors? Modules and applications have deployment descriptorsXML documentsthat describe the contents of the directory or JAR file. Deployment descriptors are text documents formatted with XML tags. The J2EE specifications define standard, portable deployment descriptors for J2EE modules and applications. 2. What is the difference in the web.xml and weblogic.xml? An application-specific XML-based deployment descriptor file named web.xml, which lists your application's J2EE components and their configurations as J2EE modules. Each J2EE module is a collection of one or more J2EE components of the same container type (Web or EJB) that are represented by one component deployment descriptor for that type in the web.xml file. A WebLogic-specific deployment descriptor file named weblogic.xml, which defines how named resources in the web.xml file are mapped to WebLogic Server resources. Examples of weblogic.xml attributes include HTTP session parameters, HTTP cookie parameters, JSP parameters, resource references, security role assignments, and container attributes. 3. What is the default JVM used for Weblogic? Sun Hotspot JDK default for Development installation, JRockit is for Production mode for WebLogic 11g and 12c. Operating environment also factor to select the Certified JDK JVM. If you want to change you need to specify it. 4. How to change from default JVM to other? When you upgrade a domain to WebLogic Server 8.1, consider upgrading your JVM to JRockit. WebLogic JRockit is a JVM designed for running server-side applications in Windows and Linux running on Intel architectures. For server-side applications, JRockit has these advantages over other virtual machines: It employs adaptive optimization, which detects and removes bottlenecks in the deployed application. It is designed specifically for the special requirements of server-side applications, which tend to be parallel and thread-intensive, to run for longer periods of time, and not to use graphical interfaces. You can monitor JRockit using the WebLogic Server Administration Console. Steps to change: In the server start scripts, set JAVA_HOME (or equivalent) shell variables to point to the JRockit root directory. For example, change: @rem Set user-defined variables. set JAVA_HOME=WL_HOME\jdk131 where WL_HOME is the WebLogic Server 7.0 installation directory, to @rem Set user-defined variables. set JAVA_HOME=WL_HOME\jrockit81_141_02 where WL_HOME is the WebLogic Server 8.1 installation directory.

Change the domains config.xml to use the JRockit javac.exe. For example, change JavaCompiler="WL_HOME\jdk131\bin\javac" where WL_HOME is the WebLogic Server 7.0 installation directory, to JavaCompiler=WL_HOME\jrockit81_141_02\bin\javac where WL_HOME is the WebLogic Server 8.1 installation directory. Remove from server start scripts any switches specific to the Sun JVM. For example, from the start command: echo on "%JAVA_HOME%\bin\java" -hotspot .... weblogic.Server delete -hotspot 5.How to make a managed server? Backup the configuration by rename config.xml with config.xml_date Configure the changes in the startManagedWebLogic.sh /cmd with weblogic home and java home and give the admin severs URL updated Go to weblogic admins console and add a managed server and

give the IP and port of the managed server. all the changes confirmed then start the server using startManagedWebLogic.sh script present in the domain bin.
6. What is a license file? now you need to register with Oracle Support ID to get updated license xml file. 7. How to configure a DB connection pool? Choose the DB type (Oracle, Sybase, Mysql, etc...). Then choose the driver type for the DB. Give the connection pool name. Give the DB Service ID, schema name and password. Then it will ask for testing the connection pool/DataSource. After successful connection, it will ask you to create and deploy the connection pool target to server or cluster. After creating new connection pool always point the jdbcstore to the connection pool created. This is required because A JMS JDBC store will be used for persistent messaging. After each JDBC connection, we have to restart the server if there is startup classes dependancy exists otherwise no restart required in WebLogic 9.x and higher versions. 8. What are the modes of operation for Weblogic server domains? There are two modes: Development and production mode: Development mode: You use development mode while you are developing your applications. Development mode uses a relaxed security configuration and enables you to auto-deploy applications. 2. You can use the demonstration digital certificates provided by the WebLogic Server security services. With these certificates, you can design your application to work within environments secured by SSL.
1.

WebLogic Server instances can automatically deploy and update applications that reside in the domain_name/applications directory. 4. When you start a server, the server automatically renames (rotates) its local server log file as server-name.log.n. For the remainder of the server session, the server rotates its local log file whenever the size of the file reaches 500 kilobytes. 5. The default number of threads available to Execute Queues is 15. The default capacity is 15 JDBC connections.
3.

Production mode:
1.

2. 3. 4. 5. 6.

9.

You use production mode when your application is running in its final form. A production domain uses full security and may use clusters or other advanced features. A warning message is displayed if you use the demonstration digital certificates. The auto-deployment feature is disabled, so you must use the WebLogic Server Administration Console or the weblogic.Deployer tool. A server rotates its local log file after the size of the file reaches 500 kilobytes. The default number of threads available to Execute Queues is 25. The default capacity is 25 JDBC connections. What is JNDI?

Java Naming and Directory Interface Applications use naming services to locate objects data sources, EJBs, JMS, MailSessions, and so on within the WebLogic domain. A naming service associates names with objects and finds objects t3 protocol will be used. (The RMI registry is a good example of a naming service.)

JNDI provides a common-denominator interface to many existing naming services, such as LDAP (Lightweight Directory Access Protocol) and DNS (Domain Name System). These naming services maintain a set of bindings, which relate names to objects and provide the ability to look up objects by name. JNDI allows the components in distributed applications to locate each other. The WebLogic Server implementation of JNDI supplies methods that:

Give clients access to the WebLogic Server naming services Make objects available in the WebLogic namespace Retrieve objects from the WebLogic namespace 10. How to configure JMS? JMS (Java Message Service) is a standard API for accessing enterprise messaging systems. Specifically, WebLogic JMS: Enables Java applications sharing a messaging system to exchange messages.

Simplifies application development by providing a standard interface for creating, sending, and receiving messages. Using the Administration Console, you define configuration attributes to:

1. Create JMS servers and target a WebLogic Server instance or a Migratable Target where the JMS server will be deployed. 2. Create and/or customize values for JMS servers, connection factories, destinations (queues and topics), JMS templates, destination sort order (using destination keys), persistent stores (file or JDBC), paging stores, session pools, and connection consumers. 3. Define message and/or bytes thresholds and quotas, as well as a maximum allowable message size on your JMS servers, destinations, and templates. Enable any desired WebLogic JMS features, such as: Server clustering using multiple connection factories. High availability and load balancing for destinations across a cluster by using distributed destinations. Persistent messages and durable subscribers. Paging out message bodies during peak load periods to free up memory. Controlling message flow during peak load periods, including blocking message producers. Establishing a message expiration policy to ensure that expired messages are cleaned up immediately. Preventing message quota errors by temporarily blocking message producers from sending messages to a destination when it exceeds its specified maximum message quota. Concurrent message processing via session pools. 11. What is a domain template? A domain template is a jar file default one is wls.jar file, which is '/bea/weblogic81/common/templates/domains/, it has all the features that is required for the standard weblogic domain, we can even create domain template of our own configuration. by this template we dont have to configure every time we create a new domain. By using template we can: Create servers. Clusters. Machines. Configure services such as JMS, JDBC, Applications 12. What are the Admin Default ports?

The non-SSL listen port for the Administration Server's default network configuration is 7001 by default. The SSL listen port for the Administration Server's default network configuration is 7002 by default.

WebLogic Admin servers and Managed servers could communicate with Admin port which is separate network channel. So that other communications can be run on different networks.
13. What are Weblogic clusters? A WebLogic Server cluster consists of multiple WebLogic Server server instances running simultaneously and working together to provide increased scalability and reliability. A cluster appears to clients to be a single WebLogic Server instance. The server instances that constitute a cluster can run on the same machine, or be located on different machines. You can increase a cluster's capacity by adding additional server instances to the cluster on an existing machine, or you can add machines to the cluster to host the incremental server instances. Each server instance in a cluster must run the same version of WebLogic Server. Benefits of clustering: Scalability: The capacity of an application deployed on a WebLogic Server cluster can be increased dynamically to meet demand. You can add server instances to a cluster without interruption of service, the application continues to run without impact to clients and end users. High-Availability: In a WebLogic Server cluster, application processing can continue when a server instance fails. You "cluster" application components by deploying them on multiple server instances in the cluster, so, if a server instance on which a component is running fails, another server instance on which that component is deployed can continue application processing
1. Can you give the deployer utility syntax? The syntax goes like this: $ java weblogic.Deployer -adminurl http://admin:7001 -name appName -source /myapp/appName.ear -targets [serverList] [-activate or other options] 2. How do you install Apache web server in UNIX and windows? You will get a binaries for Apache website and you compile and build with the 4 steps a. Extract the compressed file b. Execute configure.sh file from the extracted folder c. make d. make install

http://wlabypani.blogspot.com/2009/11/apache-installation-configuaration.html

3 What is Oracle SID in Database? It is a Service ID in Oracle database, that we need to use in configuring JDBC Connection pool. 4. What is listener in database? In Oracle listener is that which is associated with a SID and host, port. It is configured in the tnsnames.ora file. You can verify it by tnsping command. 5. What are the tuning techniques you applied? Tunning for JVM - chanigng -Xmx, -Xms, MaxNewSize, MaxPermSize, and if required GC algorithms Tuning in Threads/ThreadPool -- Defining Workmanager with maximum constraint Tuning TCP/IP connections Interface address, backlog count, Tuing JMS -- changing queue sizes as required Tuing JDBC - initial count, maximum capacity, increase by number of connections

6. How do you troubleshoot if config.xml file will be deleted First we look for is there any last good backup of configuration is availble on the Admin machine. If it is not found then alternatively you can find it on remote machines where the managed servers running.

Best practice is whenever there is a configuration changes made before and after you need to take a backup.That will help you such situation where you might need old configuration sometime.

7. How do u trouble shoot if managed server is in FAILED state? If any managed server is in FAILED state there could be reasons as follows: i) deployment failed ii) JDBC DataSource issue iii) JMS configuration issue

8. How to monitor webLogic using WLST? First you need to connect to the adminServer. then you can use any Runtime MBean. Using WLST we can monitor various Runtime MBeans such as ThreadPool, JVM, JDBC ConnectionPool, JMS Server and Server Life Cycle for state of a WebLogic server instance. 9. Can you explain about bea guardian? Gaurdian is only helpful when you have GUI. It is enables that all new patches available on Oracle site can shown in the right downside corner shows. 10.What are monitoring tools you know? There are wide varieties of monitoring tools available, such as: a. HP-OVO

b. Introscope Willey c. Patrol d. Mercury and many more...

11. What are the difference between Connection pool and data source? ConnectionPool is physically connects to the Database. where as Data Source is a logical resource that can be used by developer or any other resource for accessing Connection of pools. DataSource can be associated with JNDI name that is used for lookup from from any other client.

12. What are the difference in WebLogic 8.1 and 9.x? Side by side deployment introduced in WL 9.x deployment descriptors JDK support 1.4 and 1.5 respectivly console Look and feel changed Cuncurrent access is controlled with Change center 'Lock and Edit' , 'Activate Changes', 'Undo All chnages' buttons. ConnectionPool is included in DataSource configuration part. JMS Uniform distributed destination is reduced configuration side. JMX version change 1.2 so the MBean accessing methods simplified.

13. What is JMS and how do you configure it? Java Messaging System it is a API supported by J2EE application server for messaging between diffent resources. it can be used by MDB (Message Driven Beans). First you need to configure JMS System resource, JMS module consists any one out of PTP, publisher/Subscriber type 14. What is cluster and how do you configure? Cluster is a group of managed servers. Using console Usning WLST You need to provide the Multicast address, Multicast port, Cluster Address which is nothing but the listen addresses, listen port of all managed servers need to group together. 15. What is the use of multicast address? In a WebLogic domain to broadcast the heart beat message to all cluster members. TTL will be send to the multicast address, to this address all the cluster members are subscribers. If one of the Server crashes that can be notified by all other members by missing 3 times heart -beat. So that secondary server will takeover the request and start working with the replication data. 16. How to get thread dump and what the purpose of stuck thread? Get the java process id, you can get it by jps or customized script for it. kill -3 pid for unix env. Ctrl+break for windows env. When there is a Stuck Thread need to monitor the log for few minutes some times 2 or 3 stuck threads hogging but after sometime it will be unstucked. If you take multiple thread dump for every 5 sec gap and analyse with sumarai or Java Thread Analyzer tool you will get to know why it is stuck what is causing the instances to mis behave that time.

17. What is nmenroll in WLST? The nmEnroll() method is used for enroll the machine with the weblogic domains running on that. It is name and its path. the Nodemanager always get the domain information from the Administration server provided that it should have enrolled in that machine. 18. Tell about ant scripts?

You can ANT Scripts are mostly used for deployment process in development environtments.

ANT can be used to 1. start WebLogic Server 2. deploy the application 3. Configure a single WebLogic server 4. invoking WLST script 19. Types of load balancing techniques and differences b/n them There are Hardware loadblancer, Software loadbalancer BIG IP F5 is most leading load balancers in use. Again the Software loadbalancing CMS, CSS Context Switch Servicing Basically Load balances uses Round robin method to its connecting Webservers.

Plrease ref wikipedia.com for more details. 20. What is the important configuration file in apache? The Apache configuration will be defined in the httpd.conf, if required segrigated weblogic.conf file can be created. SSL enable sites requires httpsd.conf 21. How do you provide load balancing? In WebLogic Cluster side we have 3 basic types and each supports Affinity based also. I) Round Robin ii) Random iii) Weight based 22. Why Data source is not there in Weblogic 9? I just wonder about this question!! It is there under jdbc link 23. When do you use vi editor?

In UNIX environments we have vi editor for creating new file which can be shell or python or jython or plain file. I - insert mode Esc - to come out of the mode r - replace char

a - append to the line O - insert above line o - insert below line dw - delete word dd - delete line x - delete char / - search a pattern :set nu setup numbers etc... 24. What type of shell scripts you have created? There are many bash scripts whihc I had developed i) Finding a pattern in all log files. ii) instance name assciated with PID iii) Heap dump iv) Multiple copy for produciton Code move v) Many DB related scripts vi) Log archiving scripts vii) Daily DTS Collector scripts 25. What type of wlst scripts u have created? WLST scripts I) Thread Monitoring script ii) JVM monitoring iii) JMS monitoring iv) DataSource monitoring v) Site wise, Server wise, Domain wise scripts

26. How to test the port is existing or not in unix? On the UNIX you can give the following command netstat -na |grep <port> 1. When do we go for jdrivers and XA drivers?Advantages? This question is focused for weblogic Architect/developers. This choice is depends on the application if it is having more transaction with Database requires reliable connections with the DB,

more Entity Beans on the ejb-tier then we need to choose JDriver when JDO is in application side. Transactional consistency is mandatory for the application and response time is no matter then we choose XA.
2. Is there any disadvantages of using machines in cluster configuration? Yes, If Weblogic domain not using the feature of NodeManager then it is a useless configuration. 3. What happens if we delete the log files when the server is running & when the server is not running? Better option is to NULLify the content of the log after archiving the logs. Nothing happen when we delete a WebLogic server log files, When server is RUNNING, new logs will be generated w.r.t Server instance and application logs depends on log4j.properties.

New loggging will be written if the file exists. It will always do appending to the log file. If the file is removed then no appending happens. So that you don't know what is happening to the Server instance. The other case, When NOT RUNNING not new log generated :
4. Can we change the name of the log files? When we want to change the log file names while running. If we change at run time WebLogic will creates new log file again. Using WLST, specifying logger with edit, save we can change it in the domain level also. Ref: Unnikrishnan pillai blog. 5. What is the actual procedure of the application deployment in realtime? Basic reqiurement? If there is no deployment tools in use then no-stage mode is preferred for production. Application code will be deployed when target managed server is restarted. Admin server need not to copy the code to remote machine. But you need to place the code in the code directory. Production Redeployment can be done with weblogic.Deployer command also. Latest version prefers to use deployment plan. Realtime in the sense development or in Production? If it is Development procedure is simple we can use hot deployment. the number of components of the application are scheduled in sequance of deployment order. for entity-ejbs some times requires restart of the server. 6. Why datasources ,JMS need JNDI? JNDI is a light weight directory which is used to lookup from other resources. Entity EJB lookup for DataSource, Message Driven Beans lookup for JMS. Servlets, JSP web compoents lookup for JDBC connections for few actions. which is not recommmend in real time. 7.Benefits of jRockit over jdk? JRockit JVM strongly built with Aspect of Programming, POJO JRockt don't have separate class loading in JVM space. Sun JDK JVM have a dedicated memory space for it, that is PermSize. JRockit performance is good once it is in RUNNING. Sun JDK is faster than JRockit at launching time. GC options are varies in both.

Please visit: http;//wlabypani.blogspot.com


8.What is Bootup Process? StartWebLogic.sh script flow need to explain... CLASSPATH MEMARGS GC parameters to start the weblogic.Server class check authentication if user, password given script takes from it. if not check for boot.properties

Domain bootup process is like this...

Admin Server -> EJB TIER servers -> Web - Tier 9. How do u identify weblogic health in production? Main Threads... checking ThreadPool state for the WebLogic instance.

This depends on the client capacity ... if Client is willing to spend much on monitoring no downtime then Introscope, HP-OVO some more tools are available. for me I m using WLST for JVM, Idle, Hogging thread count program which I had published in my blog. 10. What are the action to be taken when server is crash ?core file is not genetated what to do? if sever is crash u cannot do anything after words :) if u got alerts you can managed to get Heapdumps as you told. reason pstack, jmap, pmap requires process id. If third party package installed in Solaris then you can use dbx command for further investigation. In solaries we use pstack and pmap command to take long stack and to find which thread library causes the problem instead of using debbuger.. For linux is there any command that do the same tasks..pmap is working in linux but there is no pstack command..after a long search i found one command which is equal to pstack ...i.e lsstack ( equal to pstack).. but it is not working...

11. Difference between Weblogic previous 8.1 and 9.2 above versions such as ,10.3? This you can ans only when you read release notes of each one. already given weblogic interview questions 3

WLS Management from 6.0 to 8.1 Proprietary Remotable APIs to access MBeanServer One MBeanServer, hosted all MBeans Non schema based config.xml Many broken links in MBean hierarchy MBeanHome - Factory for creation/deletion of all MBeans Configuration change mechanism is atomic No control over configuration changes and often unpredictable AdminMBeanHome provided the federated view of the Domain CommandLine administration via weblogic.Admin

WLS Management from 9.0 & above Standards based, JSR 160. Deprecated MBeanHome & RemoteMBeanServer 4 MBeanServers, each MBS hosts MBeans depending on functionality Schema based config.xml All MBeans completely Linked, making the hierarchy traversable Each parent MBean serves as a Factory to create/delete its Child MBeans Introduction of transaction semantics to configuration change Need a lock on configuration to make a change, more control (can undo changes, stop edits etc) DomainRuntime MBeanServer provides the federated view of the Domain Deprecated weblogic.Admin, introduced WLST

WebLogic Domain Name in MBean's Changed to com.bea, ex: ObjectName, ex: com.bea:Name=myserver,Type=Server mydomain:Name=myserver,Type=Server

config.xml represented all WLS configuration

{domain_dir}/config directory represents WLS configuration i.e config is spread across multiple xml files (JMS, JDBC & WLDF config in different files) Service MBeans to get to the root Mbeans Work Manager gives more effective and efficient Thread pool control, like JVM crash can be controlled,

None Execute Queues control Thread pool control

Welogic console combination of Applet New WebLogic console in Portals and easy and webpage less in synchroniztion, no to extention of the console possibility to extention of console. No that much integrated At a time single version archive is allowed for deployment JMS only two types Newly introduced webLogic Diagnostics Framework WLDF is more useful for diagnostics Deployment can be done with application version wise from commandline JMS new types introduced for more flexibility Store and Forward (SAF), distributed destination Domain Templates are excellent feature for creating multiple domains for a development. Node Manager can start even Admin Server and the commands can be given from WLST

12. What is Tivoli?why we use?How it works? Tivoli is a IBM product for profiling tool WebLogic was having similar tool Merqury.

13. In order to see last 20 files what is the command? At your Unix prompt you can give as follows: ls -lrt | tail -20

14. In order to see last 20 days files what is the command ? Simple way is using find command with ctime option and specify days signs +20 15. If SSL certificates are expired what to do? Two options: 1. Using temporary demo certificates. 2. Get new renewal from CA(Certifying Authority) like verisign.

16. How to select where and which driver we have to use? This is a typical question. This is obsolutely depends on application context. Major impacting factors

i) load capacity number of connections ii) Application contains PreparedStatements, CallableStatements preferable is OCI if it is Oracle. (DB vendor specific driver) iii) Thin Driver is preferable for certain number of connections only. But is most widely used with Oracle RAC and Grid databases.

17. How to monitor the incoming traffic for webserver? HP OVO, Patrol, access logs of web servers. By looking in the access logs of the web-server.

18. How to find network outages in environment? Basically ping command will give required output if not outage can be predictable, In WebLogic instance to instance inter-communication breakage will be indicated by BEA-000117 error code. netstat -na |grep using port can be used for identifying the instance is responding or not.

19. How you will analyse threads state using samurai tool? By getting the Thread dump for the impacted WebLogic instance. Normally, thread state could be ACTIVE, STANDBY, STUCK, If the state is same for many thread dumps then need to check about that thread. Check for the 'wait', 'lock' keywords with find option, verify how the threads impacting, does it leads to dead-lock? It is GUI tool which clearly shows in RED color which are the impacting threads in wait state.

20. Basic requirement for datasouce and connection pools? Amazon.com Widgets The Basic need for Connection Pool and DataSource are: 1. connection to the adminserver 2. JDBC Driver name, connecting parameters such as DataSource name, DATABASE schema details (user,password, hostname, port, SID) 3. Target the connection pool to a 'server' or 'cluster'. 4. Finally verify the connection pool by testing it.

What is the difference between TRUNC and DELETE in SQL commands?

TRUNC faster dependent tables cannot work

DELETE slow row-by-row cannot applicable for large tables

1. Explain your work at Current Organization ? I had responded to this keeping in a brief description of Middleware Administration activities... This is common and general question by the interviewer, explained the work that I have been performing at current project. Like WebLogic Installation, Domain creation, Deployment, Clustering, Trouble shooting activities etc. I said that I am good at Shell Scripting. 2. What is the first line in Shell Scripting ? Ans: Shebang (#! /bin/sh) It is an interpreter directive to the program loader. 3. Give some examples of Unix commands like top, netstat etc., These commands are discussed in previous interview questions already so here I am leaving it for navigate :)

4. What is the major configuration file in WebLogic ? Ans: The WebLogic whole configuration stored into a repository file Config.xml in config folder present in the domain directory. 5. What is error 404 and error 500 ? Ans: These are the common issues encounter when web application have trouble. The error code 404 - Page not found this says there is no page on the server when browser client requesting, this can happen when application is not deployed properly or not in active state. 500- Internal server error This error occurs when there is a communication issue between server's intermediate services 6. How many Administration servers and managed servers should be there? Ans: In a WebLogic domain there must be a single Admin server and there can be as many as managed servers as per the need and capacity limitations of the environment. 7. Difference between weblogic 9.2 and 11g ? Ans: The major differences are * JDK Version support WebLogic 9.2 supports JDK 1.5, whereas WebLogic 11g supports JDK 1.6 * More control provided in the Change Center of the Weblogic 11g console * SAF feature is added in the JMS server for WebLogic 11g * More focus given for hot deployment and deployment strategies : production pre-deployment strategy, Production re-deployment strategy with weblogic.Deployer utility and also available in WLST.

What do you mean by hot deployment, clustering, Unix processes and commands were also asked.

What is admin server ? what is the difference between admin and managed server ?

Admin server is the central domain configuration interface which is used to create,delete and configure the resources of a domain likemanaged server, machine, cluster, data source, work managers etc. There is no difference between Admin and Managed server except admin interface application by default deployed on admin serverwhich is used to configure the domain resources. Apart from that a admin server is same as a managed server, you can deploy and create other relative resources on admin server also as you do on managed server.

How to access admin console ? ssl enabled admin console accessed as : https://<hostname_or_ip_address_where_admin_server_running>:<port_on_which_admin_server_ is_running>/console Example - https://localhost:7001/console non ssl admin console accessed as : http://<hostname_or_ip_address_where_admin_server_running>:<port_on_which_admin_server_i s_running>/console Example - http://localhost:7001/console Note : - By default weblogic admin server configured on port 7001 and SSL is not enabled. How to check pid of a weblogic server ? To check the process of a particular managed or admin server you can use ps -ef | grep -i <name_of_your_admin_or_manager_server>|grep -v grep ( grep -v grep will suppress your command in the output ) Example -

ps -ef|grep -i wci_m1|grep -v grep Above command will show you the process details of managed server with name wci_m1 from where you can get process id, see output below, here process id is 32121

some people use ps -ef|grep -i "weblogic.Name=wci_m1"|grep -v grep both are same, you can use anyone To check process id of weblogic server on window On Window, you can go to task manager, under view tab select column option, select PID option.

How many admin consoles possible in a single domain ?


only one.

What is the default port of admin server ?


7001

What is config.xml ?
config.xml is the central configuration repository for a domain. every resource you have configured from admin console or by command line or by any other tool registered under this file. WLS 9.x onwards, this file contain references to other xml configuration files also those are under your domain/config folder ( further sub folder under it for respective resources ) since wls 9.x onwards concept of modules are introduced for sub resources like data source, jms etc otherwise prior to 9.x ( 8.x or older ) every configuration was stored under this single config.xml file.

What is boot.properties file ?


boot.properties is the file used by admin or managed server during startup for username and password. it exist under your domain/servers/server_name/security folder. ( Below information is for some advance users ) To specify a customer directory for this file you can use -Dweblogic.system.BootIdentityFile=[location]/boot.properties When you create a domain in development mode then it creates automatically during startup of admin server but if you create a domain in production mode then you need to define it explicitly otherwise on every reboot of admin server it will prompt you for username and password. So in production mode Start admin server by manually passing the username and password stop it ( press cntrl+c on the started session ) go to your domain/servers/your_admin_server/ create a folder "security" go inside security and create a file "boot.properties" with below contents

username=your_admin_username password=your_admin_password now start the admin server, it will not prompt you for username & password further.

If you are going to start your managed servers from admin console then no need to create this file for managed server but if you are going to start managed servers via startManagedweblogic script then you need to follow the same above procedure for each managed server.

Weblogic Interview Questions 1


1)How do I provide user credentials for starting a server?
When you create a domain, the Configuration Wizard prompts you to provide the username and password for an initial administrative user. If you create the domain in development mode, the wizard saves the username and encrypted password in a boot identity file. A WebLogic Server instance can refer to a boot identity file during its startup process. If a server instance does not find such a file, it prompts you to enter credentials. If you create a domain in production mode, or if you want to change user credentials in an existing boot identity file, you can create a new boot identity file.

2)Can I start a Managed Server if the Administration Server is unavailable?


By default, if a Managed Server is unable to connect to the specified Administration Server during startup, it can retrieve its configuration by reading a configuration file and other files directly. You cannot change the servers configuration until the Administration Server is available. A Managed Server that starts in this way is running in Managed Server Independence mode.

3)What is the function of T3 in WebLogic Server?


T3 provides a framework for WebLogic Server messages that support for enhancements. These enhancements include abbreviations and features, such as object replacement, that work in the context of WebLogic Server clusters and HTTP and other product tunneling. T3 predates Java Object Serialization and RMI, while closely tracking and leveraging these specifications. T3 is a superset of Java Object. Serialization or RMI; anything you can do in Java Object Serialization and RMI can be done over T3. T3 is mandated between WebLogic Servers and between programmatic clients and a WebLogic Server cluster. HTTP and IIOP are optional protocols that can be used to communicate between other processes and WebLogic Server. It depends on what you want to do. For example, when you want to communicate between a browser and WebLogic Server-use HTTP, or an ORB and WebLogic Server-IIOP.

4)How do you set the classpath?


WebLogic Server installs the following script that you can use to set the classpath that a server requires: WL_HOME\server\bin\setWLSEnv.cmd (on Windows) WL_HOME/server/bin/setWLSEnv.sh (on UNIX)

5)How do stubs work in a WebLogic Server cluster?


Clients that connect to a WebLogic Server cluster and look up a clustered object obtain a replica-aware stub for the object. This stub contains the list of available server instances that host implementations of the object. The stub also contains the load balancing logic for distributing the load among its host servers. What happens when a failure occurs and the stub cannot connect to a WebLogic Server instance? When the failure occurs, the stub removes the failed server instance from its list. If there are no servers left in its list, the stubb uses DNS again to find a running server and obtain a current list of running instances. Also, the stub periodically refreshes its list of available server instances in the cluster; this allows the stub to take advantage of new servers as they are added to the cluster.

6)How does a server know when another server is unavailable?


WebLogic Server uses two mechanisms to determine if a given server instance is unavailable. Each WebLogic Server instance in a cluster uses multicast to broadcast regular heartbeat messages that advertise its availability. By monitoring heartbeat messages, server instances in a cluster determine when a server instance has failed. The other server instances will drop a server instance from the cluster, if they do not receive three consecutive heartbeats from that server instance WebLogic Server also monitors socket errors to determine the availability of a server instance. For example, if server instance A has an open socket to server instance B, and the socket unexpectedly closes, server A assumes that server B is offline.

7)How are notifications made when a server is added to a cluster?


The WebLogic Server cluster broadcasts the availability of a new server instance each time a new instance joins the cluster. Cluster-aware stubs also periodically update their list of available server instances.

8)How do clients handle DNS requests to failed servers?


If a server fails and DNS continues to send requests to the unavailable machine, this can waste bandwidth. For a Java client application, this problem occurs only during startup. WebLogic Server caches the DNS entries and removes the unavailable ones, to prevent the client from accessing a failed server twice. Failed servers can be more of a problem for browser-based clients, because they always use DNS. To avoid unnecessary DNS requests with browser-based clients, use a third-party load-balancer such as Resonate, BigIP, Alteon, and LocalDirector. These products mask multiple DNS addresses as a single address. They also provide more sophisticated load-balancing options than round-robin, and they keep track of failed servers to avoid routing unnecessary requests.

9)How many WebLogic Servers can I have on a multi-cpu machine?


There are many possible configurations and each has its own advantages and disadvantages. BEA WebLogic Server has no built-in limit for the number of server instances that can reside in a cluster. Large, multi-processor servers such as Sun Microsystems, Inc. Sun Enterprise 10000, therefore, can host very large clusters or multiple clusters. In most cases, WebLogic Server clusters scale best when deployed with one WebLogic Server instance for every two CPUs. However, as with all capacity planning, you should test the actual deployment with your target web applications to determine the optimal number and distribution of server instances.

10)How can I set deployment order for applications?


WebLogic Server allows you to select the load order for applications. WebLogic Server deploys server-level resources (first JDBC and then JMS) before deploying applications. Applications are deployed in this order: connectors, then EJBs, then Web Applications. If the application is an EAR, the individual components are loaded in the order in which they are declared in the application.xml deployment descriptor.

Weblogic Interview Questions 2


1)Can I refresh static components redeploy the entire application? of a deployed application without having to

Yes. You can use weblogic.Deployer to specify a component and target a server, using the following syntax: java weblogic.Deployer -adminurl http://admin:7001 -name appname -targets server1,server2 -deploy jsps/*.jsp

2)When should I use the -nostage option?


Set the staging mode to -nostage (using weblogic.Deployer or the Administration Console) if you dont want to copy deployment files but want to deploy an application from its present location. All target servers must be able to access the same set of deployment files.

3)When should I use the external_stage option?


Set -external_stage using weblogic.Deployer if you want to stage the application yourself, and prefer to copy it to its target by your own means.

4)Can I modules?

set

the

deployment

order

for

application

modules?

For

standalone

The Load Order attribute controls the deployment order of standalone modules and applications relative to other modules and applications of the same type. For example, standalone EJBs with smaller Load Order values are deployed before those with higher values. Modules that are deployed as part of an Enterprise Application (EAR file or directory) are deployed in the order in which they are specified in the application.xml deployment descriptor. What is the difference between the WL_HOME/config/examples/applications folder and the WL_HOME/config/examples/stage folder? The applications folder is intended for applications that are not yet ready for a production environment. WebLogic Server dynamically deploys the contents of the applications folder. The stage folder (or a folder that you create for the same purpose) is for storing copies of deployment files that are ready for deployment in a production environment (deployments that use the stage or external_stage deployment modes).

5)How do I turn the auto-deployment feature off?


The auto-deployment feature checks the applications folder every three seconds to determine whether there are any new applications or any changes to existing applications and then dynamically deploys these changes. The auto-deployment feature is enabled for servers that run in development mode. To disable auto-deployment feature, use one of the following methods to place servers in production mode: * In the Administration Console, click the name of the domain in the left pane, then select the Production Mode checkbox in the right pane. * At the command line, include the following argument when starting the domains Administration Server:

-Dweblogic.ProductionModeEnabled=true Production mode is set for all WebLogic Server instances in a given domain.

6)Must EJBs be homogeneously deployed across a cluster? Why?


Yes. In WebLogic Server 6.0 and later, EJBs must be homogeneously deployed across a cluster for the following reasons: * To keep clustering EJBs simple * To improve performance by avoiding cross-server calls. If EJBs are not deployed on all servers, cross-server calls are more likely. * To ensure that every EJB is available locall.y * To ensure that all classes are loaded in an undeployable way. Every server must have access to each EJBs classes so that it can be bound into the local JNDI tree. If only a subset of the servers deploys the bean, the other servers will have to load the beans classes in their respective system classpaths which makes it impossible to undeploy the beans.

What are clusters? Cluster is a logical set of multiple Weblogic Server instances running simultaneously across different geographies and working together to achieve high availability and scalability Weblogic Server clusters support multiple algorithms for load balancing and failover: round-robin, weight-based, random, round-robin-affinity, weight-based-affinity, and random-affinity(By default, a Weblogic Server cluster will use the round-robin method)

What is session replication? Weblogic Server provides clustering support for servlets and JSPs by replicating 'HTTP session state' of clients that access servlets and JSPs through a cluster service Weblogic Server can use 'memory, file based and database' persistence for storing session information

How you deploy your applications on weblogic server? Auto Deployment Console Command line weblogic.deployer ANT / WLST

What are stating modes are available in Weblogic Server ? Stage mode: Administration Server copies the deployment files from their original location on the Administration Server machine to the staging directories of each target server

External Stage: target servers deploy using local copies of the deployment files, here the Administration Server does not automatically copy the deployment files to targeted servers in external_stage mode ; instead, you must copy the files to the staging directory of each target server before deployment. No Stage: The Administration Server does not copy deployment unit files; instead, all servers deploy using the same physical copy of the deployment files, which must be directly accessible by the Administration Server and target servers.

What is a Thread dump? How will you take in unix/linux and windows? A Java thread dump is a way of finding out what every thread in the JVM is doing at a particular point in time. This is especially useful if your Java application sometimes seems to hang when running under load, as an analysis of the dump will show where the threads are stuck. Linux : kill -3 <ps_id> Windows (console mode) : crtl+break Windows (service) : beasvc -dump -svcname:mydomain_myserver

How should u look for in a Thread Dump? Always have 7-10 thread dumps taken in an interval of 5 seconds each A thread dump will give you an insight on what every thread in the JVM is currently doing While analyzing the thread dump you should be looking for stuck threads (threads which have not moved from a long time) could be a resource (file / db) lock not allowing the thread to complete the task and free the monitor Look for thread locsk(if two threads store references to different objects into the same reference value, the variable will subsequently contain a reference to one object or the other, not a reference to some other object or a corrupted reference value) Look for recursive loops in application / server code traces, usually hampers server performance by utilizing CPU

What is difference between 8.1 and 9.2, 10.x versions? 8.1 uses JDK 1.4.2 ; 9.2/10.0 uses JDK 1.5 ; 10.3 uses JDK 1.6 8.1 uses execute worker threads ; 9.2/10/10.3 uses work manager for work load distribution within the server Directory structures Console applet bases in 8.1 ; while it is portlet based in later versions 8.1 has one big config.xml ; later versions have basic info in config.xml and subsystem level info in different directories(jms, jdbc, etc)

What are multi pools / multi data sources? MultiPools are 'pools of connection pools' that you can set up according to either a high availability or load balancing algorithm

You can use a MultiPool in the same manner that you use a connection pool. When an application requests a connection, the MultiPool determines which connection pool will provide a connection, based on the selected algorithm

What is IIS server? IIS is a webserver developed by Microsoft which is shipped with Windows NT/2000/2003 + Available versions : 5, 6, 7 Usually used for hosting static HTML pages and used as an aplkication server for ASP.NETapplication developed using DOT NET framework 1+. Can be used as a proxy server for routing requests to weblogic server

Where are user credentials stored? User credentials are stored in the 'boot.properties' file , which has its encryption key in the 'SerializedSystemIni.dat' If you use a script to start a server instance, it is recommended that you do not use this technique because it requires you to store an unencrypted password in the startup script.

Suggest few JVM tuning parameters. Initial heap size and maximum heap size to be same (-xms and xmx):T his ensures less is spend by the CPU to allocate memory in rutime Young generation (-XX:MaxNewSize): The bigger the young generation, the less often minor collections occur. However, for a bounded heap size a larger young generation implies a smaller tenured generation, which will increase the frequency of major collections. The optimal choice depends on the lifetime distribution of the objects allocated by the application.

1.

What is the difference between URL instance and URLConnection instance?- A URL instance represents the location o a resource, and a URLConnection instance represents a link for accessing or communicating with the resource at the location.

2.

What are the two important TCP Socket classes? - Socket and ServerSocket. ServerSocket is used for normal two-way socket communication. Socket class allows us to read and write through the sockets. getInputStream() and getOutputStream() are the two methods available in Socket class. What technologies are included in J2EE? - The primary technologies in J2EE are: Enterprise JavaBeansTM (EJBsTM), JavaServer PagesTM (JSPsTM), Java Servlets, the Java Naming and Directory InterfaceTM (JNDITM), the Java Transaction API (JTA), CORBA, and the JDBCTM data access API.

3.

4.

What is the Java Authentication and Authorization Service (JAAS) 1.0? - The Java Authentication and Authorization Service (JAAS) provides a way for a J2EE application to authenticate and authorize a specific user or group of users to run it. JAAS is a Java programing language version of the standard Pluggable Authentication Module (PAM) framework that extends the Java 2 platform security architecture to support user-based

5.

authorization. Whats the difference between JNDI lookup(), list(), listBindings(), and search()? - lookup() attempts to find the specified object in the given context. I.e., it looks for a single, specific object and either finds it in the current context or it fails. list() attempts to return an enumeration of all of the NameClassPairs of all of the objects in the current context. I.e., its a listing of all of the objects in the current context but only returns the objects name and the name of the class to which the object belongs. listBindings() attempts to return an enumeration of the Bindings of all of the objects in the current context. I.e., its a listing of all of the objects in the curr ent context with the objects name, its class name, and a reference to the object itself. search() attempts to return an enumeration of all of the objects matching a given set of search criteria. It can search across multiple contexts (or not). It can

return whatever attributes of the objects that you desire. Its by far the most complex and powerful of these options but is also the most expensive. 6. Components of JNDI - Naming Interface- The naming interface organizes information hierarchically and maps human-friendly names to addresses or objects that are machine-friendly. It allows access to named objects through multiple namespaces. Directory Interface - JNDI includes a directory service interface that provides access to directory objects, which can contain attributes, thereby providing attribute-based searching and schema support. 7. Service Provider Interface - JNDI comes with the SPI, which supports the protocols provided by third parties. What is the Max amount of information that can be saved in a Session Object? - As such there is no limit on the amount of information that can be saved in a Session Object. Only the RAM available on the server machine is the limitation. The only limit is the Session ID length(Identifier), which should not exceed more than 4K. If the data to be store is very huge, then its preferred to save it to a temporary file onto hard disk, rather than saving it in session. Internally if the amount of data being saved in Session exceeds the predefined limit, most of 8. 9. the servers write it to a temporary cache on Hard disk. Must my bean-managed persistence mechanism use the WebLogic JTS driver? - BEA recommend that you use the TxDataSource for bean-managed persistence. Do EJBs have to be homogeneously deployed across a cluster? Why? - Yes. Beginning with WebLogic Server version 6.0, EJBs must be homogeneously deployed across a cluster for the following reasons: To keep clustering EJBs simple To avoid cross server calls which results in more efficiency. If EJBs are not deployed on all servers, cross server calls are much more likely. To ensure that every EJB is available locally To ensure that all classes are loaded in an undeployable way Every server must have access to each EJBs classes so that it can be bound into the local JNDI tree. If only a subset of the servers deploys the bean, the other servers will have to load the beans classes in their respective system classpaths which makes it impossible to undeploy the beans.

10. Is an XSLT processor bundled in WebLogic Server? - Yes, an XSLT processor, based on Apaches Xalan 2.0.1 processor, in WebLogic Server 6.1. 11. I plugged in a version of Apache Xalan that I downloaded from the Apache Web site, and now I get errors when I try to transform documents. What is the problem? - You must ensure that the version of Apache Xalan you download from the Apache Web site is compatible with Apache Xerces version 1.3.1. Because you cannot plug in a different version of Apache Xerces , the only version of Apache Xerces that is compatible with WebLogic Server 6.1 is 1.3.1. The built-in parser (based on version 1.3.1 of Apache Xerces) and transformer (based on version 2.0.1 of Apache Xalan) have been modified by BEA to be compatible with each other. 12. How do I increase WebLogic Server memory? - Increase the allocation of Java heap memory for WebLogic Server. (Set the minimum and the maximum to the same size.) Start WebLogic Server with the -ms32m option to increase the allocation, as in this example:
$ java ... -ms32m -mx32m ...

This allocates 32 megabytes of Java heap memory to WebLogic Server, which improves performance and allows WebLogic Server to handle more simultaneous connections. You can increase this value if necessary. 13. What causes Java.io exceptions in the log file of WebLogic Server? - You may see messages like these in the log file:
(Windows NT) java.io.IOException Connection Reset by Peer java.io.Exception: Broken pipe java.io.EOFException Connection Reset by Peer (Solaris)

These messages occur when you are using servlets. A client initiates an HTTP request, and then performs a series of actions on the browser:

Click Stop or enter equivalent command or keystrokes Click Refresh or enter equivalent command or keystrokes Send a new HTTP request.

The messages indicate that WebLogic Server has detected and recovered from an interrupted HTTP request. 14. What is the function of T3 in WebLogic Server? - T3 provides a framework for WebLogic Server messages that support for enhancements. These enhancements include abbreviations and features, such as object replacement, that work in the context of WebLogic Server clusters and HTTP and other product tunneling. T3 predates Java Object Serialization and RMI, while closely tracking and leveraging these specifications. T3 is a superset of Java Object. Serialization or RMI; anything you can do in Java Object Serialization and RMI can be done over T3. T3 is mandated between WebLogic Servers and between programmatic clients and a WebLogic

Server cluster. HTTP and IIOP are optional protocols that can be used to communicate between other processes and WebLogic Server. It depends on what you want to do. For example, when you want to communicate between a browser and WebLogic Server-use HTTP, or an ORB and WebLogic Server-IIOP. 15. What are the enhancements in EJB 2.0 specification with respect to Asynchronous communication? - EJB 2.0 mandates integration between JMS and EJB. We have specified the integration of Enterprise JavaBeans with the Java Message Service, and have introduced message-driven beans. A messagedriven bean is a stateless component that is invoked by the container as a result of the arrival of a JMS message. The goal of the message-driven bean model is to make developing an enterprise bean that is asynchronously invoked to handle the processing of incoming JMS messages as simple as developing the same functionality in any other JMS MessageListener. 16. What are the enhancements in EJB 2.0 with respect to CMP? - EJB 2.0 extends CMP to include far more robust modeling capability, with support for declarative management of relationships between entity EJBs. Developers no longer need to re-establish relationships between the various beans that make up their application the container will restore the connections automatically as beans are loaded, allowing bean developers to navigate between beans much as they would between any standard Java objects. EJB 2.0 also introduces for the first time a portable query language, based on the abstract schema, not on the more complex database schema. This provides a database and vendor-independent way to find entity beans at run time, based on a wide variety of search criteria. 17. Can you briefly describe local interfaces? - EJB was originally designed around remote invocation using the Java Remote Method Invocation (RMI) mechanism, and later extended to support to standard CORBA transport for these calls using RMI/IIOP. This design allowed for maximum flexibility in developing applications without consideration for the deployment scenario, and was a strong feature in support of a goal of component reuse in J2EE. Many developers are using EJBs locally - that is, some or all of their EJB calls are between beans in a single container. With this feedback in mind, the EJB 2.0 expert group has created a local interface mechanism. The local interface may be defined for a bean during development, to allow streamlined calls to the bean if a caller is in the same container. This does not involve the overhead involved with RMI like marshalling etc. This facility will thus improve the performance of applications in which co-location is planned. Local interfaces also provide the foundation for container-managed relationships among entity beans with container-managed persistence. 18. What are the special design care that must be taken when you work with local interfaces? - It is important to understand that the calling semantics of local interfaces are different from those of remote interfaces. For example, remote interfaces pass parameters using call-by-value semantics, while local interfaces use call-byreference. This means that in order to use local interfaces safely, application developers need to carefully consider potential deployment scenarios up front, then decide which interfaces can be local and which remote, and finally, develop the application code with these choices in mind. While EJB 2.0 local interfaces are extremely useful in some situations, the long-term costs of these choices, especially when changing requirements and component reuse are taken into account, need to be factored into the design decision. 19. What happens if remove( ) is never invoked on a session bean? - In case of a stateless session bean it may not matter if we call or not as in both cases nothing is done. The number of beans in cache is managed by the container. In case of stateful session bean, the bean may be kept in cache till either the session times out, in which case the bean is removed or when there is a requirement for memory in which case the data is cached and the bean is sent to free pool. 20. What is the difference between creating a distributed application using RMI and using a EJB architecture? - It is possible to create the same application using RMI and EJB. But in case of EJB the container provides the requisite services to the component if we use the proper syntax. It thus helps in easier development and lesser error and use of proven code and methodology. But the investment on application server is mandatory in that case. But this investment is warranted because it results in less complex and maintainable code to the client, which is what the end client wants. Almost all the leading application servers provide load balancing and performance tuning techniques. In case of RMI we have to code the services and include in the program the way to invoke these services. 21. Why would a client application use JTA transactions? - One possible example would be a scenario in which a client needs to employ two (or more) session beans, where each session bean is deployed on a different EJB server and each bean performs operations against external resources (for example, a database) and/or is managing one or more entity beans. In this scenario, the clients logic could required an all-or-nothing guarantee for the operations performed by the session beans; hence, the session bean usage could be bundled together with a JTA UserTransaction object. In the previous scenario, however, the client application developer should address the question of whether or not it would be better to encapsulate these operations in yet another session bean, and allow the session bean to handle the transactions via the EJB container. In general, lightweight clients are easier to maintain than heavyweight clients. Also, EJB environments are ideally suited for transaction management.

Context c = new InitialContext(); UserTransaction ut = (UserTransaction) c.lookup("java:comp/UserTransaction"); ut.begin(); ut.commit() ... // perform multiple operations...

22. Can the bean class implement the EJBObject class directly? If not why? - It is better not to do it will make the Bean class a remote object and its methods can be accessed without the containers? security, and transaction implementations if our code by mistake passed it in one of its parameters. Its just a good design practice. 23. What does isIdentical() method return in case of different type of beans? - Stateless - true always. Stateful - depends whether the references point to the same session object. Entity - Depends whether the primary key is the same and the home is same. 24. How should you type cast a remote object? Why? - A client program that is intended to be interoperable with all compliant EJB Container implementations must use the javax.rmi.PortableRemoteObject.narrow() method to perform type-narrowing of the client-side representations of the remote home and remote interfaces. Programs using the cast operator for narrowing the remote and remote home interfaces are likely to fail if the Container implementation uses RMI-IIOP as the underlying communication transport. 25. What should you do in a passive method? - You try to make all nontransient variables, which are not one of the following to null. For the given list the container takes care of serializing and restoring the object when activated. Serializable objects, null, UserTransaction, SessionContext, JNDI contexts in the beans context, reference to other beans, references to connection pools. Things that must be handled explicitly are like a open database connection etc. These must be closed and set to null and retrieved back in the activate method.

Q1) If we have only 10 users for a particular application, can Admin server do the job of Managed server? Ans: Yes, but generally Admin server is not used to deploy any application. Q2) Does Admin server directs( distributes) end user requests to Managed servers? Ans: No. Request from Load balancer go directly to Managed server. Admin server doesnt interfere in end user requests. Q3) If Admin server goes down, what will happen to end user requests? Ans: Nothing. As they are responded by managed server, even if Admin server goes down, end user request will continue. But the moment Managed server need to contact Admin server for any info, and it find Admin server not available, managed server will go in INDEPENDENCE MODE. It is not good and centralized config.xml is not maintained. So, for 15-20 min, even if Admin server went down, request will run. Q4) If in adomain, only one server is there, it is Admin server or manager server? Ans: Admin server Q5) How the know if the weblogic server running is Admin server or Managed server? Ans: 1. $ ps -ef|grep -i weblogic.server or ps -ef|grep -i java Managed server have Dweblogic.management.server=<admin url> in the parameter provided. Admin server doesnt have it. 2. From config.xml 3. From Admin console Note: i. to find which values are passed to server and what to JVM, here is the way starting witrh D > parameter and value passed to weblogic server

starting with X > parameter and value passed to Java/ JVM

Q1) What is your database for Weblogic server (WL) or what is the default database for WL server? Ans: Point base is the default database for WLS. It comes with Weblogic software bundle. But, we can implement any database oracle, DB2, point base etc Q2) If my admin server is not available, can i still start my managed servers for that domain? Ans: Yes Lets understand this. Admin server,Managed servers all are JVM. All can start/stop independently. Only thing is we cannot change servers configuration until Admin server is available. It is called Independence mode. It is not a advisable one, though. Q3) If my database becomes unreachable or get restarted, will connection pool still stick around? Ans: Yes It is independent of its ability to communicate with DBMS. All the connections in the pool may become defunct, but the connection pool exist.

Q4) Can you tell difference between JMS topic and JMS queue? Ans: Queues delivers messages to one consumer, topic to multiple. Q5) Weblogic is currently owned by which company and originally by which? or What is the full form of BEA? Ans: This is not a technical question, but simply to understand general awareness of the people/organization behind the software. Originally Weblogic was owned by BEASystem. Later purchased by Oracle Inc. 3 Guys named Bill, Ed Scott and Alfred founded it in 1995. So they took first letter of their name. thats it!!!!

Simplicity right!!! Q6) How will find the version of Weblogic server? Ans: Version can be found in log files or config.xml easily. By command also we can do it

$ java weblogic.version

For detailed version info $java weblogic.version -verbose Q7) Tell one recent error you got and how did you solved it? Ans: This is a super offer in plate question. If he asked it, you have a good chance to get selected. What is the trick? Always Always keep in mind 4 5 common/uncommon error and their good solutions. You can make very good impression. I will tell more in coming post. In fact even a scenario like high CPU load article i have posted some time back is good one.

Here is one more We were trying to make a domain, but when we ran config.sh, it showed some java error. /usr/lib/jvm/java.No such file or directory . On investigation , we found it is pointing to wrong java location. Actually we forgot to run env setting file. we ran commEnv.sh and than ran config.sh . It resolved the issue. Q8) What is JNDI? Ans: Java Naming and Directory interface. This is a favorite question. Dont know why. Read mode and more on it Any way, JNDI and Cluster , there 2 are ever HOT topics for interview. Q9) What is autodeployment? What is it used for and how to turn it off? Ans: There was a option Hotdeployment in earlier version. Now its Autodeployment. In simple words, any deploy able files put in autodeploy folder ( $DOMAIN_HOME/autodeploy) are automatically deployed. Libraries cannot be deployed using autodeploy feature. It is generally used for development purposes and is available only when server is started in Development mode. To turn it off, simply remove ths files in the folder or change to production mode.

Q10) What is cross-cluster replication? Ans: It is the ability provided by WL to replicate HTTP sessions across two clusters in separate domains.

Here some direct interview questions. Generally few indirect questions are also asked like in above question, some one may ask.. we need to replicate http session across domains, it is possible. If not why and if yes, how?

weblogic interview questions and answers


1. What is application server?

An application server is a software framework dedicated to the efficient execution of procedures (scripts, routines, programs ...) for supporting the construction of applications. The term was created in the context of web applications. In these, the application server acts as a set of components accessible to the software developer through an API defined by the platform itself. These components are usually performed in the same machine where the web server is running, and their main job is to support the construction of dynamic pages.

Other uses of the term can refer to: the services that a server makes available the computer hardware on which the services run Java application servers

Following the success of the Java platform, the term application server sometimes refers to a J2EE or Java EE 5 application server. Some of the better-known Java Enterprise Edition application servers include:

Apache Tomcat (Apache Software Foundation) Tcat Server (MuleSoft) WebSphere Application Server and WebSphere Application Server Community Edition (IBM) Sybase Enterprise Application Server (Sybase Inc) WebLogic Server (Oracle) JBoss (Red Hat) Apache Geronimo (Apache Software Foundation) Oracle OC4J (Oracle) SAP Netweaver AS (ABAP/Java) (SAP) WebObjects (Apple Inc.) The web modules include servlets and JavaServer Pages. Business logic resides in Enterprise JavaBeans (EJB-3 and later). The Hibernate project offers an EJB-3 container implementation for the JBoss application server. Tomcat from Apache and JOnAS from ObjectWeb exemplify typical containers which can store these modules.

A Java Server Page (JSP) (a servlet from Java) executes in a web container the Java equivalent of CGI scripts. JSPs provide a way to create HTML pages by embedding references to the server logic within the page. HTML coders and Java programmers can work side by side by referencing each other's code from within their own. JavaBeans are the independent class components of the Java architecture from Sun Microsystems. 2. What is web server?

The primary function of a web server is to deliver web pages (HTML documents) and associated content (e.g. images, style sheets, JavaScript's) to clients. A client, commonly a web browser or web crawler, makes a request for a specific resource using HTTP and, if all goes well, the server responds with the content of that resource. The resource is typically a real file on the server's secondary memory, but this is not necessarily the case and depends on how the web server is implemented.

While the primary function is to serve content, a full implementation of HTTP also includes a way of receiving content from clients. This feature is used for submitting web forms, including uploading of files.

Many generic web servers also support server-side scripting (e.g. Apache HTTP Server and PHP). This means that the behavior of the web server can be scripted in separate files, while the actual server software remains unchanged. Usually, this functionality is used to create HTML documents onthe-fly as opposed to return fixed documents. This is referred to as dynamic and static content respectively.

History of web servers In 1989 Tim Berners-Lee proposed to his employer CERN (European Organization for Nuclear Research) a new project, which had the goal of easing the exchange of information between scientists by using a hypertext system. As a result of the implementation of this project, in 1990 Berners-Lee wrote two programs:

a browser called Worldwide Web; the world's first web server, later known as CERN httpd, which ran on NeXTSTEP. Between 1991 and 1994 the simplicity and effectiveness of early technologies used to surf and exchange data through the World Wide Web helped to port them to many different operating systems and spread their use among lots of different social groups of people, first in scientific organizations, then in universities and finally in industry.

In 1994 Tim Berners-Lee decided to constitute the World Wide Web Consortium to regulate the further development of the many technologies involved (HTTP, HTML, etc.) through a standardization process.

Common features Virtual hosting to serve many web sites using one IP address. Large file support to be able to serve files whose size is greater than 2 GB on 32 bit OS. Bandwidth throttling to limit the speed of responses in order to not saturate the network and to be able to serve more clients. 3. What is the difference between Web server and Application Server? Application Server

Webserver serves pages for viewing in web browser, application server provides exposes business logic for client applications through various protocols Webserver exclusively handles http requests. Application server serves business logic to application programs through any number of protocols. Webserver delegation model is fairly simple, when the request comes into the webserver, it simply passes the request to the program best able to handle it(Server side program). It may not support transactions and database connection pooling.

Application server is more capable of dynamic behavior than webserver. We can also configure application server to work as a webserver. Simply application server is a superset of webserver. WEB Server

Web Server serves static HTML pages or gifs, jpegs, etc., and can also run code written in CGI, JSP etc. A Web server handles the HTTP protocol. Eg of some web server are IIS or apache. An Application Server is used to run business logic or dynamically generated presentation code. It can either be .NET based or J2EE based (BEA WebLogic Server, IBM WebSphere, JBoss). A J2EE application server runs servlets and JSPs (infact a part of the app server called web container is responsible for running servlets and JSPs) that are used to create HTML pages dynamically. In addition, J2EE application server can run EJBs - which are used to execute business logic.

An Application server has a 'built-in' web server; in addition to that it supports other modules or features like e-business integration, independent management and security module, portlets etc. 4. What is the Domain in Weblogic serve?

Domain is a logically related group of Oracle WebLogic Server resources that are managed as a single unit Domain Provides one point of administration Can logically separate: Development, test, and production applications Organizational divisions 5. What are the Domain Restrictions?

Each domain requires its own Administration Server. A cluster cannot span multiple domains. The Managed Servers in a domain must run the same version of Oracle WebLogic Server. The Administration Server in a domain must run the same or higher version as Managed Servers in the domain. 6. What is the server?

A server is an instance of weblogic.Server executing in a Java Virtual Machine (JVM). A server:

Runs on a designated Oracle WebLogic Server machine Has a dedicated amount of RAM Is multithreaded Two types of servers: Administration Server Managed Server 7. What is the Administration server? Administration server is central point of control for a domain. It stores the configuration information and logs for a domain. And it runs the Weblogic Administration console. 8. What is the Managed Server? Managed server is a server in a domain that is not the Administration server. It contacts the administration server for configuration information. It runs business application in a production environment. It is independent of all other Managed servers in a domain (unless they are not in a cluster). You can have many managed servers in a domain. Individual managed servers are typically added for capacity and application isolation. 9. How Administration server and Managed servers will interact?

The Administration Server stores the master copy of the domain configuration, including the configuration for all Managed Servers in the domain. Each Managed Server stores a local copy of the domain configuration file. When a Managed Server starts, it connects to the Administration Server to synchronize the configuration. When the configuration is changed, the Administration Server sends the changed configuration to the Managed Servers. 10. What is a Machine in Oracle Weblogic Server? A Machine in a Oracle Weblogic server is a computer that hosts the Oracle Weblogic Server instances. Runs a supported operating system platform and it is used by Node Manager to restart a failed Managed servers. 11. What is a Cluster in Oracle Weblogic server? A cluster is a Logical group of Weblogic servers. Oracle Weblogic server provides HIGH AVAILABILITY & LOAD BALANCING with help of cluster. 12. What is a Node Manager? A Node Manager is a utility or process running on a physical server that enables starting, stopping, suspending or restarting the Administration and Managed servers remotely. It is not associated with a Domain. [Node manager can start any server instances that are resides on the same physical server]. 13. How many ways we can install Oracle Weblogic Server? You can install Oracle Weblogic server in three different ways.

GUI mode (extract server103_linux32.bin/double click on server103_win32.exe ) Console mode (c:\>server103_linux32.bin mode=console log=c:\consoleinstal.log)

Silent mode (c:\> server103_linux32.bin mode=silent silent_xml=path_to_silent.xml log=c:\silentinstal.log) 14. What is the default database for Weblogic server? Point base is the default database. This database comes along with Weblogic software bundle. 15. How many ways we can configure a domain? You can configure Oracle Weblogic server domains in two ways.

Graphical Mode (config.cmd [Scripts are in the <WL_HOME>/common/bin directory]) Console Mode (config.cmd mode=console) 16. How many ways you can start Administration server? You can start the Administration server using 5 ways.

weblogic.Server (only in development) Start menu (only Windows) DOMAIN_DIR/bin/startWebLogic.sh WebLogic Scripting Tool (WLST) and Node Manager WLST without Node Manager 17. How many ways you can configure managed servers? You can configure the Managed server using 3 was.

Domain Configuration Wizard Administration Console Command Line (WLST) 18. How many ways you can configure a machines? You can configure machines by using following:

Domain Configuration Wizard Administration Console Command Line (WLST) 19. How many ways you can start managed servers? Start Managed Servers by using:

weblogic.Server DOMAIN_DIR/bin/startManagedWebLogic.sh Administration Console WLST and Node Manager 20. How do I provide user credentials for starting a server? When you create a domain, the Configuration Wizard prompts you to provide the username and password for an initial administrative user. If you create the domain in development mode, the wizard saves the username and encrypted password in a boot identity file. A WebLogic Server instance can

refer to a boot identity file during its startup process. If a server instance does not find such a file, it prompts you to enter credentials. If you create a domain in production mode, or if you want to change user credentials in an existing boot identity file, you can create a new boot identity file. WebLogic Server does not support copying a boot identity file from one server root directory to another. For information on creating and using boot identity files, see Boot Identity Files in Administration Console Online Help. 21. Can I start a Managed Server if the Administration Server is unavailable? By default, if a Managed Server is unable to connect to the specified Administration Server during startup, it can retrieve its configuration by reading a configuration file and other files directly. You cannot change the server's configuration until the Administration Server is available. A Managed Server that starts in this way is running in Managed Server Independence mode. For more information, see Starting a Managed Server When the Administration Server Is Not Accessible in Configuring and Managing WebLogic Server. 22. What is the function of T3 in WebLogic Server? T3 provides a framework for WebLogic Server messages that support for enhancements. These enhancements include abbreviations and features, such as object replacement, that work in the context of WebLogic Server clusters and HTTP and other product tunneling. T3 predates Java Object Serialization and RMI, while closely tracking and leveraging these specifications. T3 is a superset of Java Object. Serialization or RMI; anything you can do in Java Object Serialization and RMI can be done over T3. T3 is mandated between WebLogic Servers and between programmatic clients and a WebLogic Server cluster. HTTP and IIOP are optional protocols that can be used to communicate between other processes and WebLogic Server. It depends on what you want to do. For example: when you want to communicate between a browser and WebLogic Server -- use HTTP, or an ORB and WebLogic Server-IIOP. 23. What is the easiest way to set the classpath? WebLogic Server installs the following script that you can use to set the classpath that a server requires: WL_HOME\server\bin\setWLSEnv.cmd (on Windows) WL_HOME/server/bin/setWLSEnv.sh (on UNIX) Where WL_HOME is the directory in which you installed WebLogic Server. For more information, see "Setting the Classpath" in the WebLogic Server Command Reference. 24. How do I edit the config.xml file? The persistent configuration for a domain of WebLogic Servers and clusters is stored in an XML configuration file (config.xml). You can modify this file in the following ways:

Using the Administration Console. If you want to create scripts that automate domain management, use the weblogic.Admin utility. See "weblogic.Admin Command-Line Reference". If you want to create Java-based management applications, use the Java Management Extensions (JMX) Application Programming Interface (API). See the Programming WebLogic Management Services with JMX guide.

If you want to edit the config.xml file directly (not recommended), see the BEA WebLogic Server Configuration Reference. 25. Is there a quick way to create and start a remote Managed Server? The recommended approach is to use the Domain Configuration Wizard, as described in "Setting Up and Starting Managed Servers on a Remote Machine" in Creating WebLogic Configurations Using the

Configuration Wizard at http://download.oracle.com/docs/cd/E13196_01/platform/docs81/confgwiz/multi.html. For a streamlined approach, follow the instructions at "Starting Managed Servers From a WebLogic Server Script" in the Administration Console Online Help. 26. The Tree View pane of the WebLogic Console is not visible in my browser. How do I enable it?

Enable the Sun Java Plug-In from the control panel. 27. What is the importance of the Boot Identity file and how will you create it?

If you create boot identity file, it will not ask the user name and password at server startup time. Create a file called boot.properties in the <DOMAIN_HOME>\servers\<server_name>\security directory that contains two lines: username=username password=password The first time you start the server; the server reads the Boot Identity file and overwrites it with an encrypted version of the username and password. Thereafter, the server remembers the credentials for subsequent startup cycles. 28. What is the MSI mode in Weblogic? How can you enable and disable this option?

MSI is nothing but Managed Server Independence. By default, Managed Servers can function independently of the Administration Server. A Managed Server instance can start in MSI mode if the Administration Server is unavailable. Configure MSI mode from the Administration Console. To start a Managed Server in MSI mode, perform the following: Ensure that the Managed Servers root directory contains the config subdirectory. If the config subdirectory does not exist, copy it from the Administration Servers root directory. Start the Managed Server at the command line or by using a script. Environment > Servers > Server_Name > Tuning > Advanced > Managed Server Independence Enabled check box. 29. If the Administration server not available while starting the Managed server which is already enabled MSI, what are the files it will look for?

If the Administration Server is unavailable at boot time, Managed Servers search for: config.xml SerializedSystemIni.dat boot.properties(optional) Each Managed Server looks in its local config directory for config.xml, a replica of the domains config.xml. You cannot change the configuration of the Managed Server that is running in MSI mode until it restores communication with the Administration Server. 30. What if Administration server goes down? What is the behavior of the managed servers? What are all the things will available or not available?

The Administration Server: Can go down without affecting the operation of the Managed Servers Can be restarted when the Managed Servers are still running

When an Administration Server goes down: The domain log entries are unavailable while it is down Managed Servers can start in independent mode The Administration Console and the management tools are unavailable 31. If an administration server running machine got crashed, how will you restart the server with same configuration on new machine?

Oracle WebLogic Server allows the creation of a backup of the server as follows: Install Oracle WebLogic Server on a backup machine. Copy the application files to a backup machine. Copy the configuration files to a backup machine. Restart the Administration Server on a new machine. The new Administration Server contacts the Managed Servers and informs them that it is running on a new IP address. 32. How can you run Multiple Weblogic server instances in a same physical machine?

You can run multiple instances of WLS using different configurations on the same physical machine at the same time by either: Assigning multiple IP addresses to a machine (multihoming) and defining each server to use a unique IP address Specifying the same IP address but using different listen ports A multihomed machine: Is a machine with multiple IP addresses Can run a different WLS instance that is bound to each IP address Can be used to configure a cluster on a single machine 33. How will you create Domain Template? Explain briefly?

A domain template defines the full set of resources within a domain. Oracle provides sample templates for creating any platform domain. There are three ways to create domain templates: WLST offline command line tool pack command Domain Template Builder (config_builder.sh under WL_HOME/common/bin) Use the Domain Template Builder to create a domain template or an extension template. Using the Domain Template Builder: Define a domain and replicate it across multiple projects Distribute a domain packed with an application that has been developed to run in it 34. What are the default Weblogic provided Groups for security realm?

Administrators Deployers Operators Monitors AppTesters CrossDomainConnectors AdminChannelUsers 35. What are the default Weblogic provided Roles for security realm?

Admin Deployer Operator Monitor AppTester CrossDomainConnectors AdminChannelUsers Anonymous 36. What is the default Weblogic provided domain template file name and location? Wls.jar is the default domain template and the location is WL_HOME\common\templates\domains 37. What are the elements of the Administration console?

Change Center Domain Structure How do I Tool Bar Breadcrumb Navigation System Status 38. What are the Node elements of the Administration console or Domain Structure?

Environment (Servers, Clusters, Virtual Hosts, Migratable Targets, Machines ) Deployment Services (Messaging, JDBC, Persistent Store, JTA, File T3, jCOM ) Security Realms Interoperability Diagnostics (Log Files, Diagnostics Modules, Diagnostics Images, Archives, Context) 39. What are the Tool Bar elements in Weblogic?

Welcome Message Connected to Home Log Out Preferences Record Help Search 40. How will you enable the Administration Console? By default, the Administration Console is enabled. If you disable it, you can re-enable it using the WebLogic Scripting Tool (WLST). Start the Administration Server, then invoke WLST and use the following commands: Using WLST to Re-enable the Console connect("username","password") edit() startEdit() cmo.setConsoleEnabled(true) save()

activate() The following attribute(s) have been changed on MBeans which require server re-start.MBean Changed : com.bea:Name=mydomain,Type=Domain Attributes changed : ConsoleEnabled Activation complete ddisconnect() exit() 41. How will you Enable and disable the domain configuration lock? The Administration Console Change Center provides a way to lock a domain configuration so you can make changes to the configuration while preventing other accounts from making changes during your edit session. The domain configuration locking feature is always enabled in production domains. It can be enabled or disabled in development domains. It is disabled by default when you create a new development domain. To enable or disable the domain configuration locking feature in a development domain:

In the banner toolbar region at the top of the right pane of the Console, click Preferences. Click User Preferences. Select or clear Automatically Acquire Lock and Activate Changes to enable or disable the feature. Click Save. After you finish When you enable domain configuration locking, you must use the Change Center to lock and edit for the domain configuration. 42. What are Dynamic and Non-Dynamic Changes in the Weblogic Console? what is the difference? Some changes you make in the Administration Console take place immediately when you activate them. Other changes require you to restart the server or module affected by the change. These latter changes are called non-dynamic changes. Non-dynamic changes are indicated in the Administration Console with this warning icon,. Changes to dynamic configuration attributes become available once they are activated, without restarting the affected server or system restart. These changes are made available to the server and run-time hierarchies once they are activated. Changes to non-dynamic configuration attributes require that the affected servers or system resources be restarted before they become effective. If a change is made to a non-dynamic configuration setting, no changes to dynamic configuration settings will take effect until after restart. This is to assure that a batch of updates having a combination of dynamic and non-dynamic attribute edits will not be partially activated. Note that WebLogic Servers change management process applies to changes in domain and server configuration data, not to security or application data. 43. What is the information is going to store in the security folder of the Domain directory contents? This directory holds the security-related files that are the same for every WebLogic Server instance in the domain:

SerializedSystemIni.dat This directory also holds security-related files that are only needed by the domains Administration Server:

DefaultAuthorizerInit.ldift DefaultAuthenticatorInit.ldift DefaultRoleMapperInit.ldift 44. What is the use of SerializedSystemIni.dat file in Weblogic? It is important to protect passwords that are used to access resources in a WebLogic Server domain. In the past, usernames and passwords were stored in clear text in a WebLogic security realm. Now all the passwords in a WebLogic Server domain are hashed. The SerializedSystemIni.dat file contains the hashes for the passwords. It is associated with a specific WebLogic Server domain so it cannot be moved from domain to domain. If the SerializedSystemIni.dat file is destroyed or corrupted, you must reconfigure the WebLogic Server domain. Therefore, you should take the following precautions: Make a backup copy of the SerializedSystemIni.dat file and put it in a safe location. Set permissions on the SerializedSystemIni.dat file such that the system administrator of a WebLogic Server deployment has write and read privileges and no other users have any privileges. 45. Explain about Domain Directory Contents? By default, WebLogic Server creates domain directories under the BEA_HOME/user_projects/domains directory. This section describes the contents of the domain directory and its subfolders. In this section, domain-name, deployment-name, and server-name represent names that you define when you create a domain. Individual applications in a domain might create additional files and directories in the domain directory. If you have not yet created a domain, you can see an example of an existing domain directory by looking in WL_HOME/examples/domains/wl_server where WL_HOME is the directory in which you installed WebLogic Server. Domain-name The name of this directory is the name of the domain. autodeploy This directory provides a quick way to deploy applications in a development server. When the WebLogic Server instance is running in development mode, it automatically deploys any applications or modules that you place in this directory. The files you place in this directory can be Java EE applications, such as:

An EAR file A WAR, EJB JAR, RAR, or CAR archived module An exploded archive directory for either an application or a module Bin: This directory contains scripts that are used in the process of starting and stopping the Administration Server and the Managed Servers in the domain. These scripts are generally provided as .sh files for UNIX and .cmd files for Windows. The bin directory can optionally contain other scripts of domain-wide interest, such as scripts to start and stop database management systems, full-text search engine processes, etc. Config: This directory contains the current configuration and deployment state of the domain. The central domain configuration file, config.xml, resides in this directory. Config/configCache : Contains data that is used to optimize performance when validating changes in the domains configuration documents. This data is internal to WebLogic Server and does not need to be backed up. Config/diagnostics : This directory contains system modules for instrumentation in the WebLogic Diagnostic Framework.

Config/jdbc : This directory contains system modules for JDBC: global JDBC modules that can be configured directly from JMX (as opposed to JSR-88). Config/jms : This directory contains system modules for JMS: global JMS modules that can be configured directly from JMX (as opposed to JSR-88). Config/lib : This directory is not used in the current release of WebLogic Server. Config/nodemanager : This directory holds configuration information for connection to the Node Manager. Config/security : This directory contains system modules for the security framework. It contains one security provider configuration extension for each kind of security provider in the domains current realm. Config/startup : This directory contains system modules that contain startup plans. Startup plans are used to generate shell scripts that can be used as part of server startup. ConfigArchive : This directory contains a set of JAR files that save the domains configuration state. Just before pending changes to the configuration are activated, the domains existing configuration state, consisting of the config.xml file and the other related configuration files, is saved in a versioned JAR file with a name like config.jar#1, config.jar#2, etc. The maximum number of versioned JAR files to be kept is specified by the archiveConfigurationCount attribute of DomainMBean. Once this maximum number is reached, the oldest conversion archive is deleted before a new one is created. Console-ext : This directory contains extensions to the Administration Console, which enable you to add content to the WebLogic Server Administration Console, replace content, and change the logos, styles and colors without modifying the files that are installed with WebLogic Server. For example, you can add content that provides custom monitoring and management facilities for your applications. See Extending the Administration Console. Init-info : This directory contains files used for WebLogic domain provisioning. You should not modify any files in this directory. Lib : Any JAR files you put in this directory are added to the system classpath of each server instance in the domain when the servers Java virtual machine starts. Pending : This directory contains domain configuration files representing configuration changes that have been requested, but not yet activated. Once the configuration changes have been activated, the configuration files are deleted from this directory. Security : This directory holds those security-related files that are the same for every WebLogic Server instance in the domain:

SerializedSystemIni.dat This directory also holds security-related files that are only needed by the domains Administration Server:

DefaultAuthorizerInit.ldift DefaultAuthenticatorInit.ldift DefaultRoleMapperInit.ldift

Servers : This directory contains one subdirectory for each WebLogic Server instance in the domain. The subdirectories contain data that is specific to each server instance. Servers/server-name : This directory is the server directory for the WebLogic Server instance with the same name as the directory. Servers/server-name/bin : This directory holds executable or shell files that can be or must be different for each server. The server environment script (setServerEnv.sh or setServerEnv.cmd) is an example of a file that resides here because it can differ from one WebLogic Server instance to the next, for example, depending on whether the server instance has its own startup plan. Servers/server-name/cache: This directory holds directories and files that contain cached data. By cached here we mean that the data is a copy, possibly in a processed form (compiled, translated, or reformatted), of other data. Servers/server-name/cache/EJBCompilerCache : This directory is a cache for compiled EJBs. Servers/server-name/data : This directory holds files that maintain persistent per-server state used to run the WebLogic Server instance, other than security state, as opposed to temporary, cached or historical information. Files in this directory are important data that must be retained as the WebLogic Server instance is brought up, is brought down, crashes, restarts, or is upgraded to a new version. Servers/server-name/data/ldap : This directory holds the embedded LDAP database. The run-time security state for the WebLogic Server instance is persisted in this directory. Servers/server-name/data/store: This directory holds WebLogic persistent stores. For each persistent store, there is a subdirectory that holds the files that represent the persistent store. The name of the subdirectory is the name of the persistent store. By convention there is one store named default. Servers/server-name/logs : This directory holds logs and diagnostic information. This information is historical in nature. It is not crucial to the operation of the server, and can be deleted (while the WebLogic Server instance is down, at least) without affecting proper operation. However, the information can be quite useful for debugging or auditing purposes and should not be deleted without good reason. Servers/server-name/logs/diagnostic_images : This directory holds information created by the Server Image Capture component of the WebLogic Diagnostic Framework. Servers/server-name/logs/jmsServers : This directory contains one subdirectory for each JMS server in the WebLogic Server instance. Each such subdirectory contains the logs for that JMS server. The name of the subdirectory is the name of the JMS server. Servers/server-name/logs/connector : This directory is the default base directory for connector module (JCA ResourceAdapter) logs. Servers/server-name/security : This directory holds security-related files that can be or must be different for each WebLogic Server instance. The file boot.properties is an example of a file that resides here because it can differ from one server to the next. This directory also maintains files related to SSL keys. Servers/server-name/tmp : This directory holds temporary directories and files that are created while a server instance is running. For example, a JMS paging directory is automatically created here unless another location is specified. Files in this directory must be left alone while the server is running, but may be freely deleted when the server instance is shut down.

Tmp : This directory stores temporary files used in the change management process. You should not modify any files in this directory. user_staged_config : By default, configuration information is automatically copied from the Administration Server to each Managed Server. If instead you prefer to stage configuration changes manually, you can use this directory as an alternative to the config directory. 46. How many ways you can change the configuration changes? The change management features of WLS:

Enable you to distribute configuration changes throughout a domain securely, consistently, and predictably Are the same, regardless of whether you are using: The WLS Administration Console The WebLogic Scripting Tool (WLST) The Java Management Extension (JMX) APIs 47. What is the user of WLST in Weblogic?

The WLS command-line tools are useful: For automating common administration activities As an alternative to the Administration Console When graphical tools are not supported WLST provides a command-line interface for: Creating new WLS domains Retrieving and updating WLS domain configurations Deploying applications Obtaining run-time server statistics 48.How many WLST modules are there? Explain?

Online mode: Connected to a running server Access to all WLS configuration and run-time attributes Create and activate change sessions similar to the WLS console Offline mode: Domain not running Access to only persisted domain configuration (config.xml) Create or update domains similar to using the Configuration Wizard 49.What is the Node Manager (NM)? Explain briefly? Node Manager (NM):

Starts and stops Managed Servers remotely: server, domain, and cluster Available as either a Java-based or (for UNIX or Linux) a script-based process Monitors and acts on server health Runs on the same computers as the Managed Servers Can be run automatically in the background, as a Windows service or a UNIX daemon 50. How many versions of Node Managers are available?

There are two versions of Node Manager:

Java-based Node Manager Script-based Node Manager Java-based Node Manager runs within a Java Virtual Machine (JVM) process. Script-based Node Manager (used only for UNIX and Linux systems) does not have as much security, but provides the ability to remotely manage servers over a network using Secure Shell (SSH). 51.How Node Manager will work with the Weblogic Server? How will you configure Node Manager in WLS?

Node Manager must run on each computer that hosts the WLS instances that you want to control with Node Manager. You should configure each computer as a machine in Oracle WebLogic Server, and assign each server instance, which is to be controlled by Node Manager, to the machine that the server instance runs on.

Node Manager should run as an operating system service, so that it automatically restarts upon system failure or reboot. 52.What is the Node Manager Default Behavior?

After WebLogic Server is installed, Node Manager is ready-to-run if Node Manager and Administration Server are on the same machine. By default, the following behaviors are configured: The Administration Console can use Node Manager to start the Managed Servers. Node Manager monitors the Managed Servers that it started. The automatic restart of Managed Servers is enabled. 53.To start Node Manager at system start up time, what we have to do? We have to configure Node Manager as a Operating System Service.

It is recommended that you run Node Manager (NM) as: A Windows service on Windows platforms and A daemon on UNIX platforms Running NM during system startup allows it to restart automatically when the system is rebooted. Node Manager can be configured to start at boot time, as either of these: A Windows service A UNIX daemon 54.How will you configure Node Manager as Windows Service?

Edit installNodeMgrSvc.cmd to specify Node Managers listen address and listen port. Run installNodeMgrSvc.cmd to reinstall Node Manager as a service, listening on the updated address and port. Delete the Node Manager Service using uninstallNodeMgrSvc.cmd. 55.Explain about Weblogic server Log Message Format? When a WebLogic Server instance writes a message to the server log file, the first line of each message begins with #### followed by the message attributes. Each attribute is contained between angle brackets. Here is an example of a message in the server log file: ####<Jan 05, 2010 10:46:51 AM EST> <Notice> <WebLogicServer> <MyComputer>

<examplesServer> <main> <<WLS Kernel>> <> <null> <1080575211904> <BEA-000360> <Server started in RUNNING mode> In this example, the message attributes are: Locale-formatted Timestamp, Severity, Subsystem, Machine Name, Server Name, Thread ID, User ID, Transaction ID, Diagnostic Context ID, Raw Time Value, Message ID, and Message Text. If a message is not logged within the context of a transaction, the angle brackets for Transaction ID are present even though no Transaction ID is present. If the message includes a stack trace, the stack trace is included in the message text. WebLogic Server uses the host computers default character encoding for the messages it writes. 56.What is the Log Message Formant of Output to Standard Out and Standard Error? When a WebLogic Server instance writes a message to standard out, the output does not include the #### prefix and does not include the Server Name, Machine Name, Thread ID, User ID, Transaction ID, Diagnostic Context ID, and Raw Time Value fields. Here is an example of how the message from the previous section would be printed to standard out: <jan 01, 2010 10:51:10 AM EST> <Notice> <WebLogicServer> <BEA-000360> <Server started in RUNNING mode>In this example, the message attributes are: Locale-formatted Timestamp, Severity, Subsystem, Message ID, and Message Text. 57.How many log Message Severity levels are there in Weblogic? Explain? The severity attribute of a WebLogic Server log message indicates the potential impact of the event or condition that the message reports. Severity TRACE Meaning

Used for messages from the Diagnostic Action Library. Upon enabling diagnostic instrumentation of server and application classes, TRACE messages follow the request path of a method. Used for reporting normal operations; a low-level informational message. An informational message with a higher level of importance. A suspicious operation or configuration has occurred but it might not affect normal operation. A user error has occurred. The system or application can handle the error with no interruption and limited degradation of service. A system or service error has occurred. The system can recover but there might be a momentary loss or permanent degradation of service. A particular service is in an unusable state while other parts of the system continue to function. Automatic recovery is not possible; the immediate attention of the administrator is needed to resolve the problem.

INFO NOTICE WARNING

ERROR

CRITICAL

ALERT

EMERGENCY The server is in an unusable state. This severity indicates a severe system failure or panic. DEBUG A debug message was generated.

58.What is the default log Message Severity levels in Weblogic? WebLogic Server subsystems generate many messages of lower severity and fewer messages of higher severity. For example, under normal circumstances, they generate many INFO messages and no EMERGENCY messages.

59.What is the Log Message Severity Level sequence from lowest to highest impact? A log level object can specify any of the following values, from lowest to highest impact: TRACE, DEBUG, INFO, NOTICE, WARNING, ERROR, CRITICAL, ALERT, And EMERGENCY 60. How will you specify the logging implementation in Weblogic? We will specify the logging implementation using "Java Logging API" or "Log4j" in Weblogic. About Log4j Log4j has three main components: loggers, appenders, and layouts. The following sections provide a brief introduction to Log4j. Loggers Log4j defines a Logger class. An application can create multiple loggers, each with a unique name. In a typical usage of Log4j, an application creates a Logger instance for each application class that will emit log messages. Loggers exist in a namespace hierarchy and inherit behavior from their ancestors in the hierarchy. Appenders Log4j defines appenders (handlers) to represent destinations for logging output. Multiple appenders can be defined. For example, an application might define an appender that sends log messages to standard out, and another appender that writes log messages to a file. Individual loggers might be configured to write to zero or more appenders. One example usage would be to send all logging messages (all levels) to a log file, but only ERROR level messages to standard out. Layouts Log4j defines layouts to control the format of log messages. Each layout specifies a particular message format. A specific layout is associated with each appender. This lets you specify a different log message format for standard out than for file output, for example. Java Logging API WebLogic logging services provide the Commons LogFactory and Log interface implementations that direct requests to the underlying logging implementation being used by WebLogic logging services. To use Commons Logging, put the WebLogic-specific Commons classes, $BEA_HOME/modules/com.bea.core.weblogic.commons.logging_1.3.0.0.jar, together with the commons-logging.jar file in one of the following locations: APP-INF/LIB or WEB-INF/LIB directory DOMAIN_NAME/LIB directory Server CLASSPATH Note: WebLogic Server does not provide a Commons logging version in its distribution. 61.What is the user of Log Filters in Weblogic? Log filters:

Control the log messages that get published Are based on the values of message attributes Can be applied to different message destinations: Server log file Server memory buffer Server standard out Domain log file 62.What is the user of Network channels in Weblogic? Adds flexibility to the networking configuration:

Multiple NICs for a single WLS server

Specific NICs or multiple port numbers on a NIC for specific WLS servers Ability to use multiple IP addresses with each server Ability to use a single IP address with multiple ports Ability to configure the cluster multicast port number independently of the port numbers used by the cluster members Multiple SSL configurations on one server Network channels:

Define the set of basic attributes of a network connection to WLS Can assign multiple channels to a single server (segment network traffic) Can prioritize internal (non-URL) connections Can separate incoming client traffic from internal server to server traffic in a domain A default channel gets generated when a server is created.

63.How will you configure a web application in Weblogic? Web applications are configured using the web.xml and weblogic.xml deployment descriptors, which:

Define the run-time environment Map URLs to servlets and JSPs Define application defaults such as welcome and error pages Specify J2EE security constraints Define work managers for applications Set the context root for the application 64. What information will be available in web.xml file? The web.xml file is a deployment descriptor that is used to configure the following:

Servlets and JSP registration Servlet initialization parameters JSP tag libraries MIME type mappings Welcome file list Error pages Security constraints and roles Resources EJB references

65. What information will be available in weblogic.xml file? Using weblogic.xml, you can configure the following:

The applications root context path Application logging Security role mappings Advanced session settings Session clustering References to shared libraries References to server resources (data sources, EJBs, and so on) Work managers and threading

Virtual directories JSP compiler options

66. To configure a web service Applications in Weblogic, what are all the files required as a deployment descriptor? A Web service application:

Responds to HTTP client requests using the Simple Object Access Protocol (SOAP) Uses the same structure as a Java EE Web application Supports two additional deployment descriptors: webservices.xml weblogic-webservices.xml

67. What is the Virtual directory Mappings? Which file you are going to provide these virtual directory mappings? Virtual directories:

Can be used to refer to physical directories Enable you to avoid the need to hard code paths to physical directories Allow multiple Web applications to share common physical directories for specific requests Decrease duplication of files across applications Are configured in weblogic.xml

such as images

Example: <virtual-directory-mapping> <local-path>c:/usr/gifs</local-path> <url-pattern>/images/*</url-pattern> <url-pattern>*.jpg</url-pattern> </virtual-directory-mapping> <virtual-directory-mapping> <local-path>c:/usr/common_jsps.jar</local-path> <url-pattern>*.jsp</url-pattern> </virtual-directory-mapping> 68. What is the deployment descriptor file for ejb applications? What are all the information is going to provide in that file? Ejb application deployment descriptor file in Weblogic is weblogic-ejb-jar.xml. Using weblogic-ejb-jar.xml, you can configure the following:

Security role mappings Advanced security settings EJB clustering EJB pooling and caching Work managers and threading

69. What is an Enterprise Application?

An enterprise application is a grouping of several resources into one deployable unit that is These resources include: Web applications (.war) EJB applications (.jar) Java applications (.jar)

packaged in an .ear file.

Resource adapters (.rar)

70. What is the user of Enterprise Applications? Use enterprise applications to:

Avoid namespace clashes Declare application wide security roles Deploy an application as one unit Share application wide EJB resources Configure local JDBC data sources Configure local JMS resources Configure local XML resources

71. What is the user of weblogic-application.xml deployment descriptor file? Using weblogic-application.xml, you can configure:

References to shared libraries Work managers and threading Default EJB and Web application parameter values We can configure enterprise wide WLS-specific features with the weblogic-application.xml deployment descriptor:

XML parsers XML entity mappings JDBC data sources JMS connection factories and destinations Security realms 72. What is the user of Weblogic shared java EE Libraries? A Shared Java EE library:

Is a reusable portion of a Web or enterprise application Is referenced by other deployed applications Avoids duplicating source files among Java EE projects Can contain deployment descriptors that are merged with the applications descriptors 73. Explain about deployment methods in Weblogic?

WLS supports three deployment methods: Auto-deployment Console deployment Command-line deployment You can deploy: Enterprise, Web, and EJB applications Web services J2EE libraries JDBC, JMS, and Diagnostic Framework modules Resource adapters Optional packages Client application archives

Applications and EJBs can be deployed: In an archived file (.ear, .war, .jar) In an exploded (open) directory format 74. How many ways we can deploy an application to Weblogic servers? Several methods are available to deploy the Oracle WebLogic Server applications and shared libraries, including:

Administration Console WebLogic Scripting Tool (WLST) weblogic.Deployer Java class wldeploy Ant task Auto-deployment folder 75. Explain about auto deployment in Weblogic? If Production Mode is OFF:

You can install an application simply by copying it (manually or using the console) to the autodeploy directory of the domain

The Administration Server monitors this directory for new, changed, or removed applications This configures, targets, and deploys the application only to the Administration Server Location of Applications Directory: $BEA_HOME/user_projects/domains/domain_name/autodeploy 76. Explain about FastSwap and On-Demand Deployment in Weblogic?

WebLogics FastSwap feature is: Enabled using the WebLogic deployment descriptors Available only if the domain is not running in production mode Applicable only to Web applications that are not archived When enabled: WebLogic automatically reloads the modified Java class files within applications Developers can perform iterative development without an explicit redeployment On-demand deployment: Excerpt from weblogic.xml: <fast-swap>true</fast-swap> 77. While deploying an application to Weblogic, what is the difference between Development and Production Mode?

An Administration Server starts using either: The development mode, which turns auto-deployment on The production mode, which turns auto-deployment off The Administration Server starts in the mode selected at domain creation time. The mode is set for all Oracle WebLogic Servers in a given domain. 78. Explain about console deployment method? Deploying with the console allows full administrator control:

Installation from a location of your choice Manual configuration of application name Targeting of application to individual servers and/or clusters Configuring the application without targeting it Activating deployment when desired 79. Explain about command line deployment?

The weblogic.Deployer utility allows you to perform deployment operations similar to those available in the console. weblogic.Deployer actions can also be scripted with the Ant task wldeploy. weblogic.Deployer Syntax: % java weblogic.Deployer [options] -deploy|-undeploy|-redeploy|-start|-stop|-listapps] [file(s)] Prepare and deploy a new application: java weblogic.Deployer -adminurl t3://adminserver:7001 -username myuser password mypass name HRServices -source /usr/HRServices.ear -targets serverA deploy Redeploy an application: java weblogic.Deployer -adminurl t3://adminserver:7001 -username myuser password mypass name HRServices redeploy Undeploy an application: java weblogic.Deployer -adminurl t3://adminserver:7001 -username myuser password mypass name HRServices undeploy List all applications: java weblogic.Deployer -adminurl t3://adminserver:7001 -username myuser password mypass -listapps 80.What is JNDI?

The Java Naming and Directory Interface is an API for uniformly accessing the different naming and directory services. This is a major step forward because: Different services use vastly different naming schemes Java applications can now navigate seamlessly across databases, files, directories, objects, and networks 81.Why the JNDI required in Weblogic? In Oracle WebLogic Server, JNDI serves as a repository and lookup service for J2EE objects, including:

Enterprise JavaBeans (EJB) home stubs JDBC DataSources JMS connection factories, queues, and topics Remote Method Invocation (RMI) stubs 82.What is the use of Naming Services?

A naming service provides a method for mapping identifiers to entities or objects. Term Definition Example

Binding

The association of an atomic name and an www.example.com is bound to object 209.10.217.38. A set of unique names in a naming system www.example.com/ products

Namespace

83.Explain about Contexts and Sub-contexts in JNDI?

Subcontexts are referenced through the dot delimiters (.). The subcontexts must be created before objects are placed into them. Typically when objects are bound to a JNDI tree, subcontexts are automatically created based on the JNDI name. If the following context exists: com.oracle.examples You cannot bind: com.oracle.examples.ejb.SomeObject Without first creating: com.oracle.examples.ejb 84.How can I set deployment order for applications? WebLogic Server 8.1 allows you to select the load order for applications. See the ApplicationMBean LoadOrder attribute in Application. WebLogic Server deploys server-level resources (first JDBC and then JMS) before deploying applications. Applications are deployed in this order: connectors, then EJBs, then web Applications. If the application is an EAR, the individual components are loaded in the order in which they are declared in the application.xml deployment descriptor. 85.Can I refresh static components of a deployed application without having to redeploy the entire application? Yes. You can use weblogic.Deployer to specify a component and target a server, using the following syntax: java weblogic.Deployer -adminurl http://admin:7001 -name appname -targets server1,server2 -deploy jsps/*.jsp 86.When should I use the -nostage option? Set the staging mode to -nostage (using weblogic.Deployer or the Administration Console) if you don't want to copy deployment files but want to deploy an application from its present location. All target servers must be able to access the same set of deployment files. 87.When should I use the external_stage option? Set -external_stage using weblogic.Deployer if you want to stage the application yourself, and prefer to copy it to its target by your own means. 88.What are the Deployment Tools for Developers? WebLogic Server provides several tools for deploying applications and stand-alone modules:

wldeploy is an Ant task version of the weblogic.Deployer utility. You can automate deployment tasks by placing wldeploy commands in an Ant build.xml file and running Ant to execute the commands. weblogic.PlanGenerator is a command-line tools that enables developers to export an applications configuration for deployment to multiple WebLogic Server environments. The deployment API allows you to perform deployment tasks programmatically using Java classes. The autodeploy domain directory allows you to deploy an application quickly for evaluation or testing in a development environment. 89.What is the Deployment order of Weblogic Server at Server Startup time? By default, WebLogic Server deploys applications and resources in the following order:

JDBC system modules JMS system modules J2EE Libraries and optional packages Applications and stand-alone modules Startup classes Note: WebLogic Server security services are always initialized before server resources, applications, and startup classes are deployed. For this reason, you cannot configure custom security providers using startup classes, nor can custom security provider implementations rely on deployed server resources such as JDBC. 90.How will you Kill the JVM or running Weblogic server in different operating systems? Each WebLogic Server instance runs in its own JVM. If you are unable to shut down a server instance using the scripts which are provided by the Weblogic (stopWeblogic.cmd/ stopManagedWeblogic.cmd), you can use an operating system command to kill the JVM. Caution: If you kill the JVM, the server immediately stops all processing. Any session data is lost. If you kill the JVM for an Administration Server while the server is writing to the config.xml file, you can corrupt the config.xml file. Some common ways to kill the JVM are as follows:

If the shell (command prompt) in which you start the server is still open, you can type Ctrl-C. On a Windows computer, you can use the Task Manager to kill a JVM. On a UNIX computer, you can use the ps command to list all running processes. Then you can use the kill command to kill the JVM . 91. Can I generate deployment descriptor files automatically? Yes, WebLogic Builder automatically generates deployment descriptor files for your J2EE applications. See WebLogic Builder Online Help. 92.Can I set the deployment order for application modules? For standalone modules? The Load Order attribute controls the deployment order of standalone modules and applications relative to other modules and applications of the same type. For example, standalone EJBs with smaller Load Order values are deployed before those with higher values. Modules that are deployed as part of an Enterprise Application (EAR file or directory) are deployed in the order in which they are specified in the application.xml deployment descriptor.

93.What is the difference between the WL_HOME/config/examples/applications folder and the WL_HOME/config/examples/stage folder? The applications folder is intended for applications that are not yet ready for a production environment. WebLogic Server dynamically deploys the contents of the applications folder. The stage folder (or a folder that you create for the same purpose) is for storing copies of deployment files that are ready for deployment in a production environment (deployments that use the stage or external_stage deployment modes). 94.How do I turn the auto-deployment feature off? The auto-deployment feature checks the applications folder every three seconds to determine whether there are any new applications or any changes to existing applications and then dynamically deploys these changes. The auto-deployment feature is enabled for servers that run in development mode. To disable autodeployment feature, use one of the following methods to place servers in production mode: In the Administration Console, click the name of the domain in the left pane, then select the Production Mode checkbox in the right pane. At the command line, include the following argument when starting the domain's Administration Server: -Dweblogic.ProductionModeEnabled=true Production mode is set for all WebLogic Server instances in a given domain. 95.I downloaded the WebLogic Server installation file, but the installation program will not run. What should I do? The installation file may have been corrupted during the download. Run a checksum on the installation file and check with technical support for the proper values. 96.Do I need to install WebLogic Server as root on Solaris? No you don't need to be root, depending on directory permissions. 97.Can I run the Configuration Wizard outside the installer? Yes. You can start the Configuration Wizard from the Start menu or using a script in the utils directory. See Creating Domains and Servers in Configuring and Managing WebLogic Server. 98.How do I edit the config.xml file? The persistent configuration for a domain of WebLogic Servers and clusters is stored in an XML configuration file (config.xml). You can modify this file in the following ways:

Use the Administration Console. See "Using the Administration Console" in the Administration Console Online Help. If you want to create scripts that automate domain management, use the weblogic.Admin utility. See "weblogic.Admin Command-Line Reference" in the . If you want to create Java-based management applications, use the Java Management Extensions (JMX) Application Programming Interface (API). See the Programming WebLogic Management Services with JMX guide.

If you want to edit the config.xml file directly (not recommended), see the BEA WebLogic Server Configuration Reference. 99.What is the free pool?

The free pool is a data structure the EJB container uses to cache anonymous instances of a given bean type. The free pool improves performance by reusing objects and skipping container callbacks when it can. 100.Can I use the PointBase DBMS included with WebLogic Server for development or production? PointBase Server is an all-Java DBMS product included in the WebLogic Server distribution solely in support of WebLogic Server evaluation, either in the form of custom trial applications or through packaged sample applications provided with WebLogic Server. Non-evaluation development and/or production use of the PointBase Server requires a separate license be obtained by the end user directly from PointBase.

101.How can I enable Oracle Advanced Security encryption on the JDBC Oracle Thin driver with a WebLogic JDBC Connection Pool? Oracle Advanced Security encryption relies on features available through connection properties in the JDBC driver from Oracle. You can specify connection properties in a WebLogic JDBC connection pool in the Properties attribute. This attribute is available on the JDBC Connection Pool > Configuration > General tab in the Administration Console. When WebLogic Server creates database connections for the connection pool, it passes the properties to the JDBC driver so that connections are created with the specified properties. For example, to enable Oracle Advanced Security encryption, you may want to specify the following options: Properties: user=SCOTT oracle.net.encryption_client=ACCEPTED oracle.net.encryption_types_client=RC4_256 protocol=thin Note: See the Oracle documentation for details about required properties for Oracle Advanced Security encryption. Properties listed above are for illustration only. The resulting entry in the config.xml file would look like: <JDBCConnectionPool DriverName="oracle.jdbc.driver.OracleDriver" Name="oraclePool" Password="{3DES}1eNn7kYGZVw=" Properties="user=SCOTT; oracle.net.encryption_client=ACCEPTED; oracle.net.encryption_types_client=RC4_256; protocol=thin" URL="jdbc:oracle:thin:@server:port:sid"/> Note: Line breaks added for readability. 102.When should I use a TxDataSource instead of a DataSource? When you select Honor Global Transactions in the Administration Console, you create a JDBCTxDataSource in the config.xml file (the default). If you clear the Honor Global Transactions check box, you create a JDBCDataSource in the config.xml file. See "When to Enable Global Transactions in a Data Source" in the Administration Console Online Help. 103.Can I enable requests to a JDBC connection pool for a database connection to wait until a connection is available? oracle.net.crypto_checksum_client=ACCEPTED; oracle.net.crypto_checksum_client=ACCEPTED

Yes. You can set two JDBC connection pool properties to enable connection requests to wait for a connection:

ConnectionReserveTimeoutSeconds HighestNumWaiters 104.What happens when my database is restarted or becomes unreachable? Does my connection pool stick around? Yes. The pool is independent of its ability to communicate with to the DBMS. All connections in the connection pool may become defunct, but the connection pool still exists. You can configure the connection pool so that WebLogic Server tests the connections in the pool and replaces bad connections when it can. To manually restart the connection pool using the Administration Console after a database failure, you can undeploy the connection pool by removing all of its deployment targets, and then redeploy the connection pool by adding deployment targets. To do this from the command line using "weblogic.Admin", set the "Targets" attribute of the pool to an empty string ("") and then set it to the desired set of targets. 105.When should I use MultiPools? You can use MultiPools in one of two ways 1) For high availability in the event a database connection fails, or 2) For load balancing between JDBC connection pools. Because you can choose only one option, you need to determine the primary purpose of your MultiPool. Note: If you implement Multipools for a JDBC application, do not configure driver-level load balancing or failover for the connection pools used by the MultiPoolthe MultiPool provides the same functionality as configuring driver-level load balancing or failover. 106.What is JDBC? JDBC is an API for accessing databases in a uniform way. JDBC provides:

Platform-independent access to databases Location transparency Transparency to proprietary database issues Support for both two-tier and multitier models for database access The Java Database Connectivity (JDBC) specification:

Is a platform- and vendor-independent mechanism for accessing and updating a database Provides transparency from proprietary vendor issues Requires the use of a driver JDBC drivers are supplied by WLS or your database vendor. 107.What is the use of Data Source in Weblogic? Data sources:

Allow database connectivity to be managed by the application server Use a dynamic pool of reusable database connections Are obtained by applications from the servers JNDI tree

108.What is the scope of the Data Source in Weblogic server?

Each data source configuration or module is persisted as a separate XML document. The system modules that are created with the console or WLST are: Stored in the domain's config/Jdbc directory Available to all applications in the domain Application-specific modules are: Deployed as part of Java EE enterprise applications Accessible only by the containing application 109.List default Weblogic provided JDBC Drivers?

Oracle and third-party drivers are included in WLS installation for many popular database products: Oracle 9i, 10g, and 11g Sybase Adaptive Server Microsoft SQL Server IBM DB2 Informix MySQL PointBase By default, these drivers are added to servers classpath. 110.What is a Data Source?

A data source object provides a way for a JDBC client to obtain a database connection from a connection pool. A data source: Is stored in the Oracle WebLogic Server JNDI tree Can support transactions Is associated with a connection pool 111.What is a Connection Pool?

A connection pool is a group of ready-to-use database connections associated with a data source. Connection pools: Are created at Oracle WebLogic Server startup Can be administered using the Administration Console Can be dynamically resized to accommodate increasing load 112.What are the benefits of having Data Sources and Connection Pools in Weblogic?

The following are some advantages of this approach: Time and overhead are saved by using an existing database connection. Connection information is managed in one location in the Administration Console. The number of connections to a database can be controlled. The DBMS can be changed without the application developer having to modify the underlying code. A connection pool allows an application to borrow a DBMS connection 113.How Data Sources are used in Weblogic? A client retrieves a data source through a JNDI lookup and uses it to obtain a database connection.

114.What is Multi Data Sources?

Multi data source: Is an abstraction around a group of data sources Determines which data source to use to satisfy the request depending on the algorithm selected in the multi data source configuration: Load balancing or failover Is bound to the JNDI tree XA support for multi data sources: The WLS JDBC supports using multi data sources in XA transactions. You can configure the data sources contained within the multi data source to use XA JDBC drivers. 115.What is the functionality of Message-Oriented Middleware?

Message-oriented middleware refers to an infrastructure that supports messaging. Typical message-oriented middleware architectures define the following elements: Message structure The way to send and receive messages Scaling guidelines 116.Explain about Point-to-Point (Queue)? Many producers can serialize messages to multiple receivers in a queue. 117.Explain about Publish-Subscribe (Topics)? Publishing and subscribing to a topic decouples producers from consumers. 118.Explain about Oracle WebLogic Server JMS Features? Oracle WebLogic Server JMS supports:

PTP and pub/sub domains Guaranteed and transactional message delivery Durable subscribers Distributed destinations Recovery from failed servers 119.How will you implement Messaging Service in Weblogic?

In Oracle Weblogic Server, the messaging service is implemented through a JMS server. A JMS server receives and distributes messages. 120.What is the user of Connection Factories in JMS?

JMS connection factories are used to set default client connection parameters, including: Message priority Message time-to-live (TTL) Message persistence Transactional behavior Acknowledgement policy Flow control

WLS provides a default client connection factory that: Uses WebLogics default connection settings Is located on the server JNDI tree at weblogic.jms.ConnectoryFactory

WEBLOGIC SERVER FAQ(ANS)--9


10:55 WEBLOGIC SERVER No comments

weblogic interview questions and answers


121.What is the use of Destination in JMS? How many types of Destinations are available in JMS?

A destination is a lightweight object that is stored in JNDI. It is the target on a JMS server for sending or receiving messages. The JMS destination types are: Queue Topic 122.Explain about Queue Destinations? In JMS point-to-point messaging, note the following:

Clients communicate with a queue destination. Messages are distributed to consumers in a serial fashion (first in, first out). Each message is delivered only to a single consumer. 123.Explain about Topic Destinations? In JMS publish/subscribe messaging, the following is true:

Clients communicate with a topic destination. Messages are broadcast to all subscribers. A message can be saved until at least one subscriber has consumed it (durable). 124.Explain about Threshold and Quotas in JMS?

A threshold and a quota can be set for the server and destination objects. A quota is a limit defined for the JMS-administered objects; it includes the following values: The maximum number of bytes that can be stored The maximum number of messages that can be stored A threshold is a limit that triggers message paging, flow control, and logged warnings, using: Upper and lower values for the number of bytes Upper and lower values for the number of messages 125.Difference between Durable Subscribers and Subscriptions?

Durable subscribers register durable subscriptions for guaranteed message delivery even if the subscribers are inactive. A subscriber is considered active if the Java object that represents it exists. By default, subscribers are nondurable. Administrators configure: Where the messages are persisted

Persistent connection factories and destinations 126.What is Persistent Messaging? When to Use it?

Persistent messaging permits messages in memory to be written out to a persistent store. Configure persistent messaging if: Development requires durable subscriptions (use durable subscribers in the application) You require that in-progress messages persist across server restarts 127.How will you Configuring a Durable Subscription in Weblogic?

To configure durable subscriptions, an administrator must: Create and configure a JMS store Configure connection factories or destinations as persistent Associate the JMS store with the JMS server The JMS store can be configured to use either: A file store A JDBC store (a connection pool) 128.How a Durable Subscription Works?

If a subscriber client is active, messages are delivered normally. When the client becomes active again, its ID is used to retrieve and redeliver messages. 129.What Node manager can do in Weblogic server? You can use Node Manager to:

Start, shut down, and restart an Administration Server Start, shut down, suspend, and restart Managed Servers Automatically restart the Administration and Managed Servers on failure Monitor servers and collect log data 130.Does the WebLogic JMS server find out about closed or lost connections, crashes, and other problems and does it recover from them? Yes, but how it does this depends on whether a Java client crashes or WebLogic Server crashes, as follows:

If a Java client crashes then the JMS server will clean up all the outstanding server-side resource from the crashed client JVM, such as: JMS connection(s) from the crashed client JVM JMS temporary destination(s) created under the above JMS connection(s) JMS session(s) created under the above JMS connection(s) JMS client(s) created under the above JMS session(s) (connection consumer and regular consumer) JMS browser(s) created under the above session(s) JMS producer(s) created under the above session(s) If WebLogic Server crashes and it is the front-end to the JMS server, then: A JMS client will lose all the server-side resources listed above. The client's javax.jms.ExceptionListener.onException(...) will be called (if javax.jms.JMSConnection.setExceptionListener is set) with a LostServerException, which extends JMSException.

If WebLogic server crashes and it is a back-end to the JMS server, then:

A JMS client may partially lose some of the server-side resources listed above (only the resource on the crashed server, such as JMS temporary destination(s), JMS client(s) and JMS browser(s). The client's javax.jms.ExceptionListener.onException(...) will be called (if weblogic.jms.extensions.WLSession.setExceptionListener is set) with a ConsumerClosedException, which extends JMSException. 131.What Is the Java Message Service? An enterprise messaging system enables applications to communicate with one another through the exchange of messages. A message is a request, report, and/or event that contains information needed to coordinate communication between different applications. A message provides a level of abstraction, allowing you to separate the details about the destination system from the application code. The Java Message Service (JMS) is a standard API for accessing enterprise messaging systems. Specifically, JMS:

Enables Java applications sharing a messaging system to exchange messages Simplifies application development by providing a standard interface for creating, sending, and receiving messages 132.How many Messaging Modules are available in Weblogic? JMS supports two messaging models: point-to-point (PTP) and publish/subscribe (pub/sub). The messaging models are very similar, except for the following differences:

PTP messaging model enables the delivery of a message to exactly one recipient. Pub/sub messaging model enables the delivery of a message to multiple recipients. 133.Explain about Point-to-Point Messaging? The point-to-point (PTP) messaging model enables one application to send a message to another. PTP messaging applications send and receive messages using named queues. A queue sender (producer) sends a message to a specific queue. A queue receiver (consumer) receives messages from a specific queue. 134.Explain about Publish/Subscribe Messaging? The publish/subscribe (pub/sub) messaging model enables an application to send a message to multiple applications. Pub/sub messaging applications send and receive messages by subscribing to a topic. A topic publisher (producer) sends messages to a specific topic. A topic subscriber (consumer) retrieves messages from a specific topic. 135.Explain about Message Persistence? As per the Message Delivery Mode section of the JMS Specification, messages can be specified as persistent or non-persistent:

A persistent message is guaranteed to be delivered once-and-only-once. The message cannot be lost due to a JMS provider failure and it must not be delivered twice. It is not considered sent until it has been safely written to a file or database. WebLogic JMS writes persistent messages to a WebLogic persistent store (disk-base file or JDBC-accessible database) that is optionally targeted by each JMS server during configuration.

Non-persistent messages are not stored. They are guaranteed to be delivered at-most-once, unless there is a JMS provider failure, in which case messages may be lost, and must not be delivered twice. If a connection is closed or recovered, all non-persistent messages that have not yet

been acknowledged will be redelivered. Once a non-persistent message is acknowledged, it will not be redelivered. 136.Topics vs. Queues? Surprisingly, when you are starting to design your application, it is not always immediately obvious whether it would be better to use a Topic or Queue. In general, you should choose a Topic only if one of the following conditions applies:

The same message must be replicated to multiple consumers. A message should be dropped if there are no active consumers that would select it. There are many subscribers, each with a unique selector. It is interesting to note that a topic with a single durable subscriber is semantically similar to a queue. The differences are as follows:

If you change a topic selector for a durable subscriber, all previous messages in the subscription are deleted, while if you change a queue selector for consumer, no messages in the queue are deleted. A queue may have multiple consumers, and will distribute its messages in a round-robin fashion, whereas a topic subscriber is limited to only one consumer. 137.Asynchronous vs. Synchronous Consumers? In general, asynchronous (onMessage) consumers perform and scale better than synchronous consumers:

Asynchronous consumers create less network traffic. Messages are pushed unidirectionally, and are pipelined to the message listener. Pipelining supports the aggregation of multiple messages into a single network call. Note: In WebLogic Server, your synchronous consumers can also use the same efficient behavior as asynchronous consumers by enabling the Prefetch Mode for Synchronous Consumers option on JMS connection factories

Asynchronous consumers use fewer threads. An asynchronous consumer does not use a thread while it is inactive. A synchronous consumer consumes a thread for the duration of its receive call. As a result, a thread can remain idle for long periods, especially if the call specifies a blocking timeout.

For application code that runs on a server, it is almost always best to use asynchronous consumers, typically via MDBs. The use of asynchronous consumers prevents the application code from doing a blocking operation on the server. A blocking operation, in turn, idles a server-side thread; it can even cause deadlocks. Deadlocks occur when blocking operations consume all threads. When no threads remain to handle the operations required unblocking the blocking operation itself, that operation never stops blocking. 138.What is a Distributed Destination? A distributed destination is a set of destinations (queues or topics) that are accessible as a single, logical destination to a client. A distributed destination has the following characteristics:

It is referenced by its own JNDI name. Members of the set are usually distributed across multiple servers within a cluster, with each destination member belonging to a separate JMS server. 139.Why Use a Distributed Destination?

Applications that use distributed destinations are more highly available than applications that use simple destinations because WebLogic JMS provides load balancing and failover for member destinations of a distributed destination within a cluster. Once properly configured, your producers and consumers are able to send and receive messages through the distributed destination. WebLogic JMS then balances the messaging load across all available members of the distributed destination. When one member becomes unavailable due a server failure, traffic is then redirected toward other available destination members in the set. 140.How many Types of Distributed Destinations are available?

Uniform Distributed Destinations Weighted Distributed Destinations Uniform Distributed Destinations In a uniform distributed destination (UDD), each of the member destinations has a consistent configuration of all distributed destination parameters, particularly in regards to weighting, security, persistence, paging, and quotas. Oracle recommends using UDDs because you no longer need to create or designate destination members, but instead rely on WebLogic Server to uniformly create the necessary members on the JMS servers to which a UDD is targeted. This feature of UDDs provides dynamic updating of a UDD when a new member is added or a member is removed. Weighted Distributed Destinations In a weighted distributed destination, the member destinations do not have a consistent configuration of all distributed destination parameters, particularly in regards to weighting, security, persistence, paging, and quotas. Oracle recommends converting weighted distributed destinations to UDDs because of the administrative inflexibility when creating members that are intended to carry extra message load or have extra capacity (more weight). Lack of a consistent member configuration can lead to unforeseen administrative and application problems because the weighted distributed destination cannot be deployed consistently across a cluster.

WEBLOGIC SERVER FAQ(ANS)--10


10:59 WEBLOGIC SERVER No comments

weblogic interview questions and answers


141.What is JNDI? JNDI (Java Naming and Directory Interface) is a Java EE lookup service that maps names to services and resources. JNDI provides a directory of advertised resources that exist on a particular stand-alone (unclustered) WebLogic server, or within a WebLogic server cluster. Examples of such resources include JMS connection factories, JMS destinations, JDBC (database) data sources, and application EJBs. A client connecting to any WebLogic server in a WebLogic cluster can transparently reference any JNDI advertised service or resource hosted on any WebLogic server within the cluster. The client doesn't require explicit knowledge of which particular WebLogic server in the cluster hosts a desired resource. 142.What is a JMS connection factory? A JMS connection factory is a named entity resource stored in JNDI. Applications, message driven beans (MDBs), and messaging bridges lookup a JMS connection factory in JNDI and use it to create JMS connections. JMS connections are used in turn to create JMS sessions, producers, and consumers that can send or receive messages.

143.What is a JMS connection-id? JMS connection-ids are used to name JMS client connections. Durable subscribers require named connections, otherwise connections are typically unnamed. Note that within a clustered set of servers or stand-alone server, only one JMS client connection may use a particular named connection at a time. An attempt to create new connection with the same name as an existing connection will fail. 144.What is the difference between a JMS topic and a JMS queue? JMS queues deliver a message to one consumer, while JMS topics deliver a copy of each message to each consumer. 145.What is a non-durable topic subscriber? A non-durable subscriber creates unnamed subscriptions that exist only for the life of the JMS client. Messages in a non-durable subscription are never persistedeven when the message's publisher specifies a persistent quality of service (QOS). Shutting down a JMS server terminates all non-durable subscriptions. 146.What is a durable subscriber? A durable subscriber creates named subscriptions that continue to exist even after the durable subscriber exits or the server reboots. A durable subscriber connects to its subscription by specifying topic-name, connection-id, and subscriber-id. Together, the connection-id and subscriber-id uniquely name the subscribers subscription within a cluster. A copy of each persistent message published to a topic is persisted to each of the topic's durable subscriptions. In the event of a server crash and restart, durable subscriptions and their unconsumed persistent messages are recovered. 147.What is the WebLogic Store-and-Forward Service? The WebLogic Store-and-Forward (SAF) Service enables WebLogic Server to deliver messages reliably between applications that are distributed across WebLogic Server instances. For example, with the SAF service, an application that runs on or connects to a local WebLogic Server instance can reliably send messages to a destination that resides on a remote server. If the destination is not available at the moment the messages are sent, either because of network problems or system failures, then the messages are saved on a local server instance, and are forwarded to the remote destination once it becomes available. 148.When should I use the WebLogic Store-and-Forward Service? The WebLogic Store-and-Forward (SAF) Service should be used when forwarding JMS messages between WebLogic Server 9.0 or later domains. The SAF service can deliver messages:

Between two stand-alone server instances. Between server instances in a cluster. Across two clusters in a domain. Across separate domains. 149.What is a messaging bridge? Messaging bridges are administratively configured services that run on a WebLogic server. They automatically forward messages from a configured source JMS destination to a configured target JMS destination. These destinations can be on different servers than the bridge and can even be foreign (non-WebLogic) destinations. Each bridge destination is configured using the four common properties of a remote provider:

The initial context factory. The connection URL. The connection factory JNDI name. The destination JNDI name. Messaging bridges can be configured to use transactions to ensure exactly-once message forwarding from any XA capable (global transaction capable) JMS provider to another. 150.When should I use a messaging bridge? Typically, messaging bridges are used to provide store-and-forward high availability design requirements. A messaging bridge is configured to consume from a sender's local destination and forward it to the sender's actual target remote destination. This provides high availability because the sender is still able to send messages to its local destination even when the target remote destination is unreachable. When a remote destination is not reachable, the local destination automatically begins to store messages until the bridge is able to forward them to the target destination when the target becomes available again. 151.When should I avoid using a messaging bridge? Other methods are preferred in the following situations:

Receiving from a remote destinationuse a message driven EJB or implement a client consumer directly. Sending messages to a local destinationsend directly to the local destination. Environment with low tolerance for message latency. Messaging Bridges increase latency and may lower throughput. Messaging bridges increase latency for messages as they introduce an extra destination in the message path and may lower throughput because they forward messages using a single thread.

Forward messages between WebLogic 9.0 domainsUse WebLogic Store-and-Forward. 152.How many types of JMS stores are available?

The JMS store can be configured to use either: A file store A JDBC store (a connection pool) 153.How will you configure a JMS JDBC Store?

To configure JMS JDBC persistence, perform the following: Create a JDBC DataSource. Create a JMS store and refer to the JDBC DataSource. Refer to the JMS store from the JMS server configuration. The required infrastructure (tables and so on) is created automatically. 154.What Is a Transaction?

A transaction is a mechanism to handle groups of operations as though they were one. Either all operations in a transaction occur or none occur at all. The operations involved in a transaction might rely on multiple servers and databases. 155.How many Types of Transactions are there? Explain?

A local transaction deals with a single resource manager. Local transactions use the nonExtended Architecture (non-XA) interface between Oracle WebLogic Server and the resource manager.

A distributed transaction coordinates or spans multiple resource managers. Global transactions can deal with multiple resource managers. Global transactions use the Extended Architecture (XA) interface between Oracle WebLogic Server and the resource managers.

You need to create non-XA or XA resources for local transactions. However, for global transactions, you need to create only XA resources. 156.Explain about Two-Phase Commit Protocol?

The Two-Phase Commit (2PC) protocol uses two steps to commit changes within a distributed transaction. Phase 1 asks the RMs to prepare to make the changes. Phase 2 asks the RMs to commit and make the changes permanent or to roll back the entire transaction. A global transaction ID (XID) is used to track all the changes associated with a distributed transaction. 157.Explain about Extended Architecture Protocol (XA)? The Extended Architecture (XA) protocol:

Is the interface that is used between WLS and the RMs Implements the 2PC protocol Allows programs to control the RMs that are involved in distributed transactions 158.What is the user of Transaction Log?

Each server has a transaction log that stores information about committed transactions coordinated by the server that may not have been completed. Oracle WebLogic Server uses the transaction log when recovering from system crashes or network failures. You cannot directly view the transaction log because the records are in a binary format and are stored in the default persistent store for the server. 159.Explain about Logging Last Resource?

You can configure a JDBC data source to enable the Logging Last Resource (LLR) transaction optimization, which: Enables one non-XA resource to participate in a global transaction Has improved performance and the same ACID guarantee as XA The LLR optimization improves performance by: Removing the need for an XA JDBC driver to connect to the database. XA JDBC drivers are typically inefficient compared to non-XA JDBC drivers. Reducing the number of processing steps to complete the transaction, which also reduces network traffic and I/O Removing the need for XA processing at the database level (if the database is the one non-XA resource) 160.What Is LDAP?

The Lightweight Directory Access Protocol:

Is derived from X.500 Provides a hierarchical lookup service Supports sophisticated searching Can be secured via SSL 160.What Is LDAP? The Lightweight Directory Access Protocol:

Is derived from X.500 Provides a hierarchical lookup service Supports sophisticated searching Can be secured via SSL 161.Explain Security Realms?

A security realm is a collection of system resources and security service providers. Only one security realm can be active at a given time. A single security policy is used in any realm. Users must be recognized by an authentication provider of the security realm. Administration tasks include creating security realms. 162.What Is SSL? Secure Sockets Layer (SSL) is a protocol that enables:

Connection security through encryption A server to authenticate to a client A client to authenticate to a server (optional) Data integrity such that the data that flows between a client and server is protected from tampering by a third party 163.What Is a Deployment Plan?

It is an optional XML document that resides outside an application archive. It configures an application for deployment to a specific WLS environment. A JavaEE deployment plan:

It is created and owned by administrators or developers for a particular environment. Is an XML file that is associated with an application Resides outside an application archive Sets or overrides the values in the JavaEE deployment descriptors
Allows a single application to be easily customized to multiple deployment environments 164.What are the Advantages of Production Redeployment?

Saves the trouble of:

Scheduling application downtime Setting up redundant servers to host new application versions

Managing client access to multiple application versions manually Retiring older versions of an application manually Explain about Packaging Applications? When you deploy applications to a single Managed Server, you can deploy the applications in an exploded
format.

Oracle recommends deploying packaged applications to a cluster of Managed Servers as .war, .ear, or .jar
file 165.What are the Oracle WebLogic Server SSL Requirements?

To enable Oracle WebLogic Server SSL, you must:

Obtain an appropriate digital certificate Install the certificate Configure SSL properties Configure two-way authentication (if desired) SSL impacts performance.
166.What is the user of keytool Utility in WLS?

keytool is a standard J2SE SDK utility for managing: The generation of private keys and the corresponding digital certificates Keystores (databases) of private keys and the associated certificates The keytool utility can the display certificate and keystore contents.
167.How WLS Protecting Against Attacks? What kinds of Attacks are there?

WLS can help protect applications against several attacks:

Man-in-the-middle attacks Denial of service (DoS) attacks Large buffer attacks Connection starvation attacks The slides that follow detail the countermeasures that WLS provides to address these attacks.
168.Explain about Man-in-the-Middle Attacks?

In the man-in-the-middle attack, a third party poses as a destination host intercepting messages
between the client and the real host.

Instead of issuing the real destination hosts SSL certificate, the attacker issues his or her own hoping that
the client would accept it as being from the real destination host.

The man-in-the-middle attacks can be resisted by using


a Host Name Verifier.

A Host Name Verifier validates that the host to which an SSL connection is made is the intended or
authorized party.

WLS provides a Host Name Verifier by default. A custom Host Name Verifier can be created by implementing the interface
weblogic.security.SSL.HostnameVerifier 169.Explain about Denial of Service Attacks (DOS)?

DoS attacks are attempts by attackers to prevent legitimate users of a service from using that service.

There are three basic types of attack: Consumption of scarce, limited, or nonrenewable resources Destruction or alteration of configuration information Physical destruction or alteration of network components
Harden WLS against denial of service attacks by:

Filtering incoming network connections Configuring consumable WLS resources with the appropriate threshold and quotas Limiting access to configuration information and backing up configuration files Preventing unauthorized access by protecting passwords against password-guessing attacks
170.Explain about Filtering Network Connections?

WLS can be configured to accept or deny network connections based on the origin of the client.

This feature can be used to: Restrict the location from which connections to WLS are made Restrict the type of connection made, that is, allow only SSL connections and reject all others
install it To filter network connections, create a class that implements the ConnectionFilter interface and using the Administration Console.

171.Explain about Large Buffer Attacks?

Individuals can try to bring down a Web site by sending a large buffer of data, which starves the system of memory. Administrators can combat this attack by setting a threshold for incoming data. 172.Explain about Connection Starvation?

Individuals can try to take down a Web site by sending small, incomplete messages that cause the server to wait. Administrators can combat this attack by setting a threshold. Connections time out while waiting for the remainder of the data if they have reached the threshold set by the administrator. 173.Explain about User Lockout?

Individuals attempt to hack into a computer using various combinations of usernames and passwords. Administrators can protect against this security attack by setting the lockout attributes. The administrator can unlock a locked user using the console. 174.How will you Protecting the Administration Console?

You can configure a separate administration port for all administration traffic. You can change the Context path of the console. You can disable the console (application). 175.What are the advantages of Deployment Plan?

Works by setting or overriding the deployment property values that are defined in an applications WLS deployment descriptor Helps to easily modify an applications WLS configuration for deployment into different multiple WLS environments without modifying the deployment descriptor files that are included in the application archive

Enables an application to be deployed to multiple domains or to multiple target servers and clusters that have a different configuration within the same 1. domain 176.What is the user of weblogic.PlanGenerator? 1. 2. 3. Is a Java-based deployment configuration tool Is primarily intended for developers who want to export portions of an Oracle WebLogic Server deployment configuration into an XML deployment plan Enables you to generate a basic Oracle WebLogic Server configuration for applications that have only J2EE deployment descriptors 177.How will you generate a Deployment Plan Using the Administration Console? 1. 2. The Administration Console automatically generates or updates the deployment plan. You can generate a deployment plan using the Administration Console using the following steps:

Prepare the deployment files. Install the application archive. Save the configuration changes to a deployment plan.
178.How many types of Staged Deployment are available in WLS? You can configure deployment per server or for each application as: 1. 2. 3. staged (default): Files are copied to the preconfigured staging directory for preparation and activation. nostage: Files are deployed from a static location. external_stage: Files are copied by a user or a third-party tool before deployment. 179.Explain about Production Redeployment? 1. You can redeploy a revised version of a production application alongside the older version:

Without affecting the existing clients to the application Without interrupting the availability of the application to the new client request
2. Oracle WebLogic Server automatically manages client connections so that:

Existing clients continue to use the older application New client requests are directed to the newer application
The older version is undeployed after all current clients complete their work. 180.Explain about Application Availability, after deploying/install to WLS? 1. By default, when an application is redeployed:

It is unavailable to clients for a brief time Existing clients lose any conversational state
2. 3. Some types of applications require availability 24 hours a day, seven days a week. Third-party proxy solutions are possible, but they require multiple servers. 181.Explain about WebLogic Production Redeployment?

1. 1. 2.

Production redeployment: Allows two versions of a single Web application or module to run simultaneously Requires you to include unique version information either:

Within the applications META-INF/MANIFEST.MF file As part of the deployment process

2.

When a new version is redeployed, WLS automatically:

Routes existing clients to the prior (retired) version Routes new clients to the new version Undeploys the prior version when all existing clients finish their work or their conversations time out
182.What are the Requirements and Restrictions for Production Redeployment in WLS? 1. Production redeployment is supported for: application via a Web application (HTTP)

Stand-alone Web Application (WAR) modules and Enterprise Applications (EARs) whose client accesses the Enterprise Applications that are accessed by inbound JMS messages from a global JMS destination, or from
inbound JCA requests

All types of Web Services, including conversational and reliable Web Services
2. Production redeployment is not supported for:

Stand-alone EJB or Resource Archive (RAR) modules Applications that use JTS drivers Applications that obtain JDBC data sources via the DriverManager API instead of using the JNDI lookup Applications that include the EJB 1.1 container-managed persistence (CMP) EJBs
3. 4. 5. A deployed application must specify a version number. WLS can host a maximum of two different versions of an application at one time. When you are redeploying a new version of an application, the following features cannot change:

Deployment targets Security model Persistent store settings


183.Redeploying Versus Distributing an applications in WLS? 1. Distributing is an alternative to deploying an application. validating the files.

Distributing an application prepares it for deployment by copying its files to all target servers and You can start a distributed application in Administration mode. Access to the application is then restricted
to a configured Administration channel. 2. 3. Distributing a new version of the application makes it available for testing before being released for general consumption. Redeploying a new version of an application places the application immediately into use and makes it available to new client requests. 184.How will you Distributing a New Application Version in WLS? 1. 2. 3. 4. 5. Use the weblogic.Deployer distribute command. After the application is distributed, start the application in Administration mode. Test the application. When ready, start the application (without using adminmode). Optionally set a retirement timeout for the older version of the application. 185.How will you Create MANIFEST.mf file for Production Redeployment? 1. Create MANIFEST.mf with the following contents: Name: java/util/ Specification-Title: Java Utility Classes Specification-Version: 1.2 Specification-Vendor: Sun Microsystems, Inc.

Implementation-Title: java.util Implementation-Version: build57 Implementation-Vendor: Sun Microsystems, Inc. 2. Then add an entry for WLS versioning: Weblogic-Application-Version: Version1.0Beta 186.What is a cluster Definition? 1. 2. A cluster is a group of Oracle WebLogic Server instances that work in coordination. Clustering provides:

High availability Load balancing Scalability


187.What Is a Cluster? A cluster: 1. 2. Is a logical group of Oracle WebLogic Servers within a domain Supports features to provide high availability for:

Whole servers Web applications/services EJB applications JMS


3. Is transparent to a client 188.What are the Benefits of Clustering? 1. 1. 2. 2. 3. There are two main benefits of clustering together Oracle WebLogic Servers: Scalability High availability Scalability is the ability to provide more capacity for an application, in this case, by adding additional servers without having to make major architectural changes. High availability ensures that when a server (in a cluster) fails, there are other servers to take over the work, so that the client is not affected. 189.What are the Key Capabilities of clustering? The key capabilities of a WebLogic cluster are: 1. Application failover and finishes the job. 2. Site failover processing. 3. 4. Server migration Load balancing

When an object in an application that is performing a task becomes unavailable, another object takes over

When all the services and applications in a single site fail, they can switch to a separate site and continue

When a server fails, pinned services can be migrated to another server in a cluster. Tasks and communications are evenly distributed across multiple servers.
190.Explain about Cluster Architecture?

Applications are generally broken into multiple tiers, each representing its distinct functionality: 1. 2. 3. Web tier Presentation tier Business or object tier WebLogic provides clustering support for all three tiers. Other services, such as JMS and JDBC, can take advantage of clusters but load-balancing and failover is a little different. 191.How the Server will communicate in a Cluster? The Oracle WebLogic Server instances in a cluster communicate with one another using two different techniques: 1. 2. Unicast/multicast (UDP) Sockets (peer-to-peer TCP) The server instances use IP unicast or multicast to broadcast the availability of services and heartbeats that indicate continued availability. IP multicast broadcasts one-to-many communications among clustered instances. IP unicast is an alternative to multicast to handle cluster messaging and communications. The unicast configuration is much easier because it does not require cross-network configuration that multicast requires. IP sockets are used for peer-to-peer communications between server instances. 192.Explain about Cluster Communication in WLS? Members of a cluster cooperate to achieve high availability using the following: 1. 2. 1. 2. Broadcast messages such as heartbeats Peer-to-peer IP sockets You can configure broadcast communication to use either: IP unicast A dedicated IP multicast address (224.0.0.0 through 239.255.255.255) and port If heartbeats are not received from a cluster member, the server is marked as failed and its services are not used. 193.How the Weblogic Server detect a server Failure? 1. WebLogic clusters detect the failure of a server instance in the following ways: 1. 2. 2. 3. Through the use of IP sockets Through the Oracle WebLogic Server heartbeat If a server in the cluster unexpectedly closes its socket, it is marked as failed and its services are not used. Server instances use multicast to broadcast heartbeats every 10 seconds to the other server instances in the cluster. If three heartbeats are missed from a peer server, the server is marked as failed and its services are not used. 194.Explain about One-to-Many Communications in WLS? Oracle WebLogic Server uses one-to-many communication for: 1. 2. Clusterwide JNDI updates Cluster heartbeats

Because all one-to-many communications occur over IP multicast, when you design a cluster, consider the following factors: 1. 2. 3. 4. If your cluster spans multiple subnets, your network must be configured to reliably transmit messages. A firewall can break IP multicast transmissions. The multicast address should not be shared with other applications. Multicast storms may occur. 195.Explain about Peer-to-Peer Communications in WLS? Oracle WebLogic Server uses peer-to-peer communications for: Accessing the nonclustered objects that reside on a remote server instance in the cluster Replicating HTTP session states and stateful session EJB states between a primary and a secondary server Accessing the clustered objects that reside on a remote server instance (typically, in a multitier cluster architecture) 196.Explain about Multitier Communications in WLS? Multitier clusters require more IP sockets than a combined-tier cluster: 1. 2. One socket for replicating session states One socket for each Oracle WebLogic Server in the EJB cluster, for accessing remote objects As an example, using a three-node cluster, the worst-case scenario would be five open sockets per server: 1. 2. One primary and secondary replicated session Each server simultaneously invokes a remote EJB method on each node in the cluster. 197.How many cluster Configuration Options are available in WLS? There are multiple ways to create and configure an Oracle WebLogic Server cluster: Administration Console Configuration Wizard WebLogic Scripting Tool (WLST) Using the Cluster MBean 198.Explain about Two-Phase Deployment? Applications are deployed using two-phase deployment (TPD). Applications are copied to the cluster and activated in two phases: Phase 1: Application components and modules are distributed to the server. Phase 2: The application is deployed if phase 1 is successful and client access is permitted. This ensures that an application is available and active on each node before clients can access it. 199.How will you Deploy Applications to a Cluster? All nodes must be running before an application is deployed to a cluster. If phase 2 of the two-phase deployment fails, the application is still deployed to other nodes in the cluster. WebLogic allows partial deployment of applications to a partitioned server. Session replication for deployed applications may fail if a node is partitioned at the time of deployment.

Avoid this by using the enforceClusterConstraints tag with weblogic.Deployer. Or select the Enable Cluster Constraints check box in the console.
Do not change cluster membership while deploying applications to the cluster.

200.Explain about HTTP Session Failover? Web applications use HTTP sessions to track information in server memory for each client. By default, when a client fails over to another server in the cluster, its session information is lost. Oracle WebLogic Server supports several Session Replication strategies to recover sessions from failed servers: 1. 2. 3. In-memory replication JDBC replication File replication Replication is configured for each Web application within its weblogic.xml file. Similar options are available for stateful EJB applications. 201.Explain about HTTP Session State Replication in WLS? 1. 2. Oracle WebLogic Server provides clustering support for JSPs and servlets by replicating the HTTP session state. To benefit from HTTP session state clustering, you must ensure that the session state is persistent, by configuring:

In-memory replication JDBC replication File system replication


3. 4. You must also access the cluster via a collection of Web servers with identically configured proxy plugins or load-balancing hardware. Session persistence is configured using the <session-descriptor> element in the weblogic.xml deployment descriptor file.

Each persistence method has its own set of configurable parameters.


202.Explain about Replication Groups in WLS? 1. 2. 3. A replication group is a logical grouping of related servers in a cluster. WLS enables you to determine where to put backup objects using replication groups. WLS attempts to:

Send backup objects to a preferred secondary replication group, if it is configured Send backup objects to a different machine Avoid sending backup objects to servers in the same replication group
203.What is the user of Replication Groups in WLS? 1. Replication groups:

Represent a subset of servers within a cluster Help to determine the placement of secondary sessions (avoid replicating within the same room, for
example)

Are not explicitly defined in the console-like machines and clusters


2. 1. 2. WLS attempts to: Send secondary sessions to servers that are assigned to the preferred secondary replication group of the primary server Avoid sending secondary sessions to servers that are assigned to the same replication group as the primary server 204.Explain about In-Memory Replication in WLS? 1. Each users session always exists on two servers:

Primary Secondary
2. Every update to the primary session is automatically replicated on the secondary server, either:

Synchronously (default) Asynchronously (batch)


3. WLS can replicate:

HttpSession objects Stateful session EJBs


4. 5. Session objects exist on only two servers. Secondary:

The server is determined by the replication group and machine definition. The object is created immediately after the primary object is created.
6. Primary failure makes the backup object the primary object. 205.What are all the Requirements for In-Memory Replication in WLS? 1. 2. 1. 2. 3. Subsequent requests from the same client must have access to the same primary object. To use in-memory replication for the HTTP session state, clients must access the cluster using either: The load-balancing hardware (WLS aware) A collection of Web servers, or a single Web server, with WebLogic proxy plug-ins (configured identically) Oracle WebLogic Server configured with HTTPClusterServlet 206.How will you Configuring In-Memory Replication in WLS? 1. 2. 3. 1. 2. 3. Configure the proxy server (if applicable). Optionally define replication groups and/or machines. Specify the persistence type in the weblogic.xml deployment descriptor; the options include: replicated replicated_if_clustered async-replication-across-cluster 207.Explain about JDBC Replication in WLS?

HTTP sessions are persisted to a database using a common JDBC data source. The required data definition language (DDL) file is available in the documentation. All members of the cluster have access to any clients session for failover purposes (no primary or
secondary).

All server instances have access to all sessions. Subsequent requests from the same client can be handled by any server.
6. 7. Great failover capability Significant performance reduction

Changing session objects causes (slow) database synchronization.


208.How will you Configuring JDBC Replication in WLS?

Create the required table in the database. Create a JDBC data source that has read/write privileges for your database. Configure JDBC session persistence in the weblogic.xml deployment descriptor.
Ex: <session-descriptor> <persistent-store-type>jdbc</persistent-store-type>

<persistent-store-pool>MyDataSource</persistent-store-pool> </session-descriptor> 209.JDBC Persistent Table Configuration A database table named WL_SERVLET_SESSIONS must exist with read/write access: 210.Explain about File Replication? File replication is similar to JDBC replication, but it persists sessions to a highly available file system.

Session state may also be stored in a file. For file-based persistence: You must create the directory in which to store the file The file must have the appropriate access privileges
211.How will you Configuring File Replication in WLS?

Create a folder shared by all servers on the cluster on a highly available file system. Assign read/write privileges to the folder. Configure file session persistence in the weblogic.xml deployment descriptor. Ex: <session-descriptor> <persistent-store-type>file</persistent-store-type> <persistent-store-dir>/mnt/wls_share</persistent-store-dir> </session-descriptor> 212.Explain about Cross-Cluster Replication in WLS? WebLogic provides the ability to replicate HTTP sessions across two clusters in separate domains:

This is most applicable to clusters that are distributed geographically. Configure a global proxy to direct clients back to the same cluster (cluster affinity). Configure a specific network channel for cross-cluster communication. 213.When cant I use WebLogic Store-and-Forward? You cant use the WebLogic Store-and-Forward service in the following situations:

Receiving from a remote destinationuse a message driven EJB or implement a client consumer directly. Sending messages to a local destinationsend directly to the local destination. Forwarding messages to prior releases of WebLogic Server. See Q. What is a messaging bridge?. Interoperating with third-party JMS products (for example, MQSeries). See Q. What is a messaging bridge?. When using temporary destinations with the JMSReplyTo field to return a response to a request. Environment with low tolerance for message latency. SAF increases latency and may lower throughput. 214..Explain about Embedded LDAP Server?

In WLS, users, groups, and authorization information is stored in an embedded LDAP server. Several properties can be set to manage the LDAP server, including: Credentials Backup settings Cache settings

Replication settings 215.How will you create a Deployment Plan?

Tools for creating a deployment plan: weblogic.PlanGenerator Administration Console Goals for creating a deployment plan: To expose the external resource requirements of the application as variables in the deployment plan To expose additional configurable properties, such as tuning parameters as variables in the deployment plan WLS includes tools to accelerate deployment plan creation. The Administration Console: Generates a skeleton plan.xml if a plan folder is detected with a newly deployed application Updates plan.xml when you use the console to modify the deployment descriptor settings The weblogic.PlanGenerator Java class can also generate a skeleton plan.xml for an existing application. 216..Explain the relationship between Transaction and Resource Managers?

A transaction manager coordinates multiple resource managers. The 2PC protocol is used to coordinate the transaction. The XA protocol implements 2PC. 217..What is a topic subscription? A topic subscription can be thought of as an internal queue of messages waiting to be delivered to a particular subscriber. This internal queue accumulates copies of each message published to the topic after the subscription was created. Conversely, it does not accumulate messages that were sent before the subscription was created. Subscriptions are not sharable, only one subscriber may subscribe to a particular subscription at a time. 218.Explain about Trust and Identity in SSL?

SSL and keystore are configured independently. For the purpose of backward compatibility, this release of Oracle WebLogic Server supports private Identity: Private key and digital certificate (can now be looked up directly from the keystore, not necessarily as a stand-alone file outside the keystore) Trust: Certificates of trusted Certificate authorities 219..How will you access SSL enabled applications? keys and a trusted WebLogic Keystore provider.

WLS uses SSL to secure HTTP and t3 communication. To use SSL, clients access WLS via the https or t3s protocols. https://localhost:7002/orderStock t3s://localhost:7002/useCreditCard

FAQS 1. Which protocol is used to transfer the file between two servers? A) FTP&SCP(file transfer protocol & secure copy protocol) 2. How to find the version of OS? A) Uname a 3. What is the use of telnet & ssh? A) Remotely testing the service, telnet ip address.hostname,ssh ipaddress 4. What is the difference between CAT & MORE command? A) Cat is for view, append, overwrite B) Morejust only reading the content 5. Write a command to kill the last background job? How do you kill the processes? A) Cron tab is the command to kill last background job B) Kill-9 pid is the command to kill the processes 6. Which command is used to delete all files in the current directory and all its sub directories? A) Rm rf <directoryname> 7. Which is the command is used to delete all the files in the current directory? A) Rm rf * 8. Is du a command ? If so what is its use? A) du - estimate file space usage 9. how to switch to a super user status to gain privileges? A) Su Appuser id 10. What is a pipe and give an example? A) Pipe is a command to filter ex: ps ef|grep java 11. How do you find out your own username? A) Who am i 12. How do you find what are the processes are running in the background? A) Ps ef 13. What are the prerequisites of install weblogic server? A) Disk space = 2 gb preferable 3.5 gb, ram 1gb, preferable 2 gb, 1ghz processor, tmp=250mb 14. How can you find which version of jvm, components and version of weblogic server can use in the environment? A) Registry.xml 15. What is the difference between Sun jdk and jrockit? A) Sun jdk is for solaris system and jrockit is for intel based systems & sun jdk is default in development mode and jrockit is default jdk in production mode as per bit processor wise we have to choose jdk and as per environment specifications 16. What weblogic utils contains? A) Clone, uninstall, bsu(to add patches) 17. In order to see last 20 days files what is the command? A) Find| -atime+20 18. Which version of jdks we can use the weblogic server version 8.x,9.x,10.x? A) Jdk 1.4, jdk 1.5, jdk 1.6 19. How to test the port is existed or not in unix? A) Netstat a|grep 7001 20. What is the silent mode installation file contains root element? When do you require the mode of installation? A) < bea installer > is the root element, we can use package installer or generic installer for silent mode installation and when we want to install in multiple machines with same configuration then will go for silent mode installation and silent.xml is the file used for installation 21. In a weblogic server what is the domain and how many different types of servers?

A) Logically grouping of services & resources in to a single unit is known as domain and there are two types of servers 1.Admin server 2. Managed server 22. What is the use of config.sh and where is this file located? A) Config.sh is a executable file for creating domain and the file is located in mwhome/wlserver/common/bin/config.sh 23. What are the modes of operation for weblogic server domains? A) Development mode & production mode 24. How many domains you can create in a middleware? N no of domains. 25. How many ways we can create a domain? A) WLST, ./config.sh, pack&unpack 26. What are the administrative tools available in weblogic server? A) Admin console, WLST 27. What is the use of WLST and how can invoke it? A) Automation activities done at WLST and security purpose, we can invoke WLST by using java weblogic.WLST 28. From which version onwards WLST is introduced? A) 9.x 29. What is the difference between web servers and application srevers? A) Webserver is for deliver web pages and supports dynamic and static pages and application server is for supporting construction of applications and supports dynamic pages. 30. What is the difference between admin server and managed server? A) Admin server perform administrative activities and it is central point of domain and store config information and managed server is a serever in a domain and runs business application in production mode & it can run in MSI mode. 31. How to start weblogic admin server & managed server? A) Mw/usreprojects/domain/domainname/bin/ ./startWeblogic.sh admin server , Mw/usreprojects/domain/domainname/bin/ ./startmanagedWeblogic.sh manage server name & using WLST &using scripts 32. Can we disable admin console?Explain it A) Set console enable=false 33. In weblogic what is the MSI code? A) 34. What is the purpose of t3 in weblogic server? A) It is aprotocol used to remotely communication between two application servers. 35. For which servers we can use boot identity files without being prompted for the administrator username and password while starting? A) Admin server, managed server 36. Which link would you click in the console to add or remove columns to or from a monitoring page? A) Custom tables tab 37. Which panel in the administration console uses a tree to represent your domain resources? A) Environment 38. The administration console is unavailable if the administration server is shutdown. True/false? A) True 39. Both the administration server and the managed servers can be started by using the administration console? A) No 40. What is the use of node manager and how can configure the node manager? A) Remotely start and stop the servers and crash recovery and node manager configuration is assigning servers to machines.

41. What is the important configuration file in nodemanager? A) Nodemanager.properties 42. What are the important arguments in nodemanager configuration file? A) Listen port, listen address, secure listener enabled, crash recovery, native library 43. What is the important log file in node manager and where is located? A) Nodemanager.log file and it is located in wlserver/common/nodemanager 44. What is the format of a log message in a weblogic server? A) Date&time loglevel subsystem system servername thread information . Bea catalogue id log-msg 45. What are the log files available in weblogic server? A) Access.log, server.log,server.out 46. Name the various message severity levels in weblogic? A) Info, warn, notice, error, critical, alert, emergency 47. What is a trace in relation to weblogic server? A) If the issue is not track for log file we will enable trace to know more information. 48. What is the emergency log message? A) Server crash 49. Arrange in order the various message severity levels? A) Info, warn, notice, error, critical, alert, emergency, debug, trace( if issue is not tracked) 50. What are log filters and what are their purpose? A) Log filters are to take particular log levels and purpose is to take the log levels as per requirement. 51. What is domain template and how many ways you can create domain template? A) Domain template is a template to create a domain using extend a existing template and can create by using config-builder and pack& unpack command 52. What are deployment descriptors? A) Java modules and applications have deployment descriptors XML files contain information about application and specifies to server WEB.XML- A application specific file which defines to the server that based up on request or url which class should be executed. WebLogic.XML- A server specific file which defines how named resources( jdbc,jndi,jms) in the web.xml file are mapped to weblogic server resources. 53. How to configure a DB connection pool? A) MIN, MAX, AUTOINCREMENT 54. What is the JNDI? Explain ? A) Java naming directory interface is a unique name to invoke the service 55. How can we configure the JMS server? A) By targeting the resources in the system module using sub deployment on JMS server. 56. What is the purpose of using multipools in weblogic server? A) For high availability & load balancing at connection pool. 57. What are valid oracle weblogic server deployment descriptor files for configuring applications? A) Web application .War- web.xml, weblogic.xml, JMS application .rar- ra.xml, weblogic_ra.xml, Ejb application .jar- ejb-jar.xml, weblogic_ejb_jar.xml, Enterprise application .ear- application.xml, weblogic-application.xml 58. Deployment application is distributed to the servers, but is not yet available to clients? What is the status of the deployed application? A) Prepared 59. What are all the different statuses available for the applications in deployment section? A) Distributed initialization, prepared, active, new, retired

60. Name four techniques or tools that can be used to deploy new applications to oracle weblogic server? A) Admin console, WLST, weblogic.deployer, antbuild scripts, recursive deployment 61. What are all the available configurations attributes for a JDBC data source ? A) JNDI, datasource, db type,connection properties 62. What is the difference between datasource and connection pool? A) Data source is nothing but a JDBC to connect application to database, connection pool is ready to use free connections. 63. What are available connection pool properties? A) Min, max, auto increment 64. What are the available resource types with in a weblogic server JMS modue? A) Queues, topics, distributed queues, distributed topics, connection factories 65. Name three attributes used to configure a multi data source? A) JNDI name, driver type, algorithm type(fail over, load balancing), target, add generic data source 66. What data source attributes affects the growth of the connection pool size at runtime? A) Auto increment 67. Name four JMS management operations available in WLS? A) JMS server, system module, sub deployment, thresholds-monitoring 68. Can you explain data source configuration in weblogic? A) Type of data source, data source name, JNDI name, type of driver, DB- connection properties, test DB connection, targets 69. How to deploy an application through command line? A) WLST, weblogic.deployer 70. What is the use of side by side deployment? And from which version this is available? A) With out downtime redeploying the applications using versions. From 9.x it is available.(weblogic.deployer) 71. What are deployment modes available in weblogic server? Explain them? A) Stagemode The Administration Server copies the archive files from their source location to a location on each of the targeted Managed Servers that deploy the archive. For example, if you deploy a J2EE Application to three servers in a cluster, the Administration Server copies the application archive files to each of the three servers. Each server then deploys the J2EE Application using its local copy of the archive files. Stage mode is the default mode when deploying to more than one WebLogic Server instance. Nostagemode The Administration Server does not copy the archive files from their source location. Instead, each targeted server must access the archive files from a single source directory for deployment. For example, if you deploy a J2EE Application to three servers in a cluster, each server must be able to access the same application archive files (from a shared or network-mounted directory) to deploy the application. Nostage mode is the default mode when deploying only to the Administration Server (for example, in a single-server domain). You can also select nostage mode if you run a cluster of server instances on the same machine. -External_stagemode External_stage mode is similar to stage mode, in that the

deployment files must reside locally to each targeted server. However, the Administration Server does not automatically copy the deployment files to targeted servers in external_stage mode; instead, you must manually copy the files, or use a third-party application to copy the files for you. 72. What is sub deployment explain? Does it always need a sub deployment? A) Sub deployment is used target the resources to JMS serevr , No 73. What is the difference between queue and topic? A) Queue is one- one, topic is publisher-subscriber ( one-many) 74. What you will do when data source will down? 75. What is the difference in the web.xml and weblogic.xml? A) WEB.XML- A application specific file which defines to the server that based up on request or url which class should be executed. WebLogic.XML- A server specific file which defines how named resources( jdbc,jndi,jms) in the web.xml file are mapped to weblogic server resources. 76. What are the war, jar,rar, ear files and explain their differences?

A) In J2EE, application modules are packaged as EAR, JAR and WAR based on their
functionality. Each type of file (.jar, .war, .ear) is processed uniquely by application servers, servlet containers, EJB containers, etc JAR: Jar file (file with a .jar extension) is the normal Java Application archive and intended to hold generic libraries of Java classes, resources, auxiliary files, etc This can be added in classpath for compilation and to run java program. Generally in web applications we keep these files in lib directory of the application. Ex: ojdbc14.jar This contains all the classes to connect the oracle database Servlet-api.jar contains servlet related classes WAR: Web modules which contains Servlet class files,JSP Files,supporting files, GIF and HTML files are packaged as JAR file with .war( web archive) extension War files (files with a .war extension) are intended to contain complete Web applications. In this context, a Web application is defined as a single group of files, classes, resources, .jar files that can be packaged and accessed as one servlet context. EAR: Application that use 2 or more containers acoording to the client requirement known as enterprise application. All above files(.jar and .war) are packaged as JAR file with .ear ( enterprise archive) extension and deployed into Application Server. Ear files (files with a .ear extension) are intended to contain complete enterprise applications. In this context, an enterprise application is defined as a collection of .jar files, resources, classes, and multiple Web application. 77. What is the difference between XA and NON XA drivers in JDBC? A) XA- global transactions Multiple commits and multiple roll back) Non XA- single transation single commit and single roll back. An XA transaction, in the most general terms, is a "global transaction" that may span multiple resources. A non-XA transaction always involves just one resource. An XA transaction involves a coordinating transaction manager, with one or more databases (or other resources, like JMS) all involved in a single global transaction. Non-XA transactions have no transaction coordinator, and a single resource is doing all its transaction work itself (this is sometimes called local transactions). XA transactions come from the X/Open group specification on distributed, global transactions. JTA includes the X/Open XA spec, in modified form.

Most stuff in the world is non-XA - a Servlet or EJB or plain old JDBC in a Java application talking to a single database. XA gets involved when you want to work with multiple resources - 2 or more databases, a database and a JMS connection, all of those plus maybe a JCA resource - all in a single transaction. In this scenario, you'll have an app server like Websphere or Weblogic or JBoss acting as the Transaction Manager, and your various resources (Oracle, Sybase, IBM MQ JMS, SAP, whatever) acting as transaction resources. Your code can then update/delete/publish/whatever across the many resources. When you say "commit", the results are commited across all of the resources. When you say "rollback", _everything_ is rolled back across all resources. The Transaction Manager coordinates all of this through a protocol called Two Phase Commit (2PC). This protocol also has to be supported by the individual resources. In terms of datasources, an XA datasource is a data source that can participate in an XA global transaction. A non-XA datasource generally can't participate in a global transaction (sort of - some people implement what's called a "last participant" optimization that can let you do this for exactly one non-XA item). 78. At the time of deployment, error is out of memory error how to solve it? A) Perm gen exceptions non heap memory 79. One application in deployed in jboss it running without errors when same application deployed in weblogic it is giving errors? How to solve it? A) Need to change the configuration files as for the application servers.. 80. How will you find if the connection pool is connected with database or not? Not by using the console? A) telnet ip port tns ping sid 81. what is the use of planner in the deployments? A) Without editing the configuration file to overwrite the values in configuration file using plan.xml 82. What is the cluster and usage of cluster? A) Logically grouping of weblogic servers which are in the same domain is known as cluster High availability, load balancing 83. How many types of cluster architectures and explain them? A) Environmental level based: horizontal, vertical, hybrid. Application level based: basic tier, multi tier Vertical: all the servers which are in the cluster are running in the same machine. Qa, Dev environment

Horizontal : grouping of servers in different machines making as a cluster. Qa, prod Hybrid: combination of horizontal and vertical Prod

Basic tier: complete requests and responses are handled by the servers of a single cluster Multi tier: one cluster will process one type of request, maintaining each layers in individual clusters 84. What is your current working environment and explain it? A) In my current environment we are using oel,weblogic11g,soa11g,oracle11g rac system and providing high availability having 3 nodes 6 clusters one is soa server and bam serevr and osb server which is connected to two proxies and to external load balancer (cisco) 85. A domain configured with a cluster of 10 servers. Out of which 8 servers are in running state. When an application deployed on the cluster what happens to it? A) Deployed partially . 86. A web application is already deployed to a cluster cluster1. There is a need of redeployment when developers came with few changes in jsp dynamic and static contents. What is the best suitable approach? A) Open the stage folder and add the jsp contents in required file. 87. What is the important configuration file in apache? A) http.conf 88. difference between unicast and multicast? A) Unicast: dynamic hosting , tcp(43 layers), supports subnet mask, tl&tm B) Multi cast: class c range of ip address, udp( 7 layers), does not supports subnet mask, tl 89. How can you install the apache server? A) Download httpd 2.2 version and un tar it using tar xvf and go to the file lacation and ./configure prefix=/home/apache , make(for complie) and make install( for installation) 90. How can you configure the apache integration with weblogic?
A)Copy the plugins i.e. .so files(mod_wl_22.so) from the weblogic server based on the operating system and processor to the module in the apache home directory and we have to load the .so file in httpd.conf file using load module command. Server will load from httpd.conf, restart the servers. LoadModule weblogic_module modules/mod_wl_20.so

91. What is the use of plugin? A) Plugin is used to integrate with one server to another server. 92. What is primary and secondary servers? A) The concept is used in cluster with fail over mechanism. A request from client first lands on a JVM, it is called primary server. The primary server then chooses another member of the cluster to replicate the HTTP session. This new server is called secondary server 93. How the servers in a cluster will communicate eah other? A) Socket communication : one server is communicate with another member of the server, heart beat communication: for every 10 sec one server send notification to opposite server. Socket communication: it is one one communication

Heart beat communication: one- many communication Unicast & multi cast 94. What is the session replication? How many types and where can we configure session replication? A) Any ranking system there we will go for this: used in session replication of cluster members. When a http session lands on a server, it chooses a secondary serverbased on the replication groups, We can configure 3 types: In memory, jdbc, file based 95. Ho to find apache version? A) We can find apache version in httpd.conf file & httpd v 96. If we create a cluster as weight based and where we declare that a specific server can handle these many requests? And what is the default no? A) Serversconfigurationclusters-default(100) 97. What is the use of http status codes? Explain the different http statuses? A) Using http codes we can know the status of the client and server and there are different codes 2XX- success status code of the request. 3XX- for re direction ( server has taken req. trying to call another url) 4XX- url which is given is not proper( url is not there in the serve r but tryin to accesss) 5XX-server taken request but not able to respond back( problem admin side) ()server may not respond). 98. Which protocol is used for the multicast communication? A) UDP 99. Diff between horizontal and vertical cluster? A) Vertical: The servers which are in the cluster are in the same machine Horizental: the servers which are in the cluster are in different machines 100. 101. 102. 103. 104. 105. How to check whether the cluster multicast address is available or not? How to check the status of httpd server whether it is running or not? What is the default port for FTP,TELNET,SSH,HTTP, AND SMTP? How to find network outages in environment? how to monitor the incoming traffic for webserver? if ssl certificates are expired what to do? notification to mw admin then we have to create a jks file ( java key store file). Certificates and keys are stored in jks file. We will encrypt the data of jks file using CSR file and send to CA TEAM they will give reply with certificate(.pem), before importing it is called as self signed certificate and after import digital self signed certificate A) Java utils.multicastTest multicast-IP port A) Ps ef|grep httpd A) FTP- 21, TELNET -23, SSH- 22, HTTP-80, SMTP-25 A) using ping command ping <ip address> A) netstat A) we have to renew the certificate, BA team will send required client& password

106. 107. 108.

how do you trouble if managed server is in failed state? How do you troubleshoot if config.xml file will be deleted? Tell about ant scripts?what are all the ant command options? config.properties file and we have to required inputs in these files according to our environment specifications. Go to the location of build.xml and type command ant it will deploy the application automatically in to the server. Package,compile,zip, deploy

A) Ant scripts are used to deploy the applications and we have build.xml and

109. 110.

What is listener in database? What is oracle SID in database? What is thread dump? Why do we needed? How do we get it? of threads and we will get it in no. of ways. Kill -3 pid , using wlst, adminconsole

A) Thread dump is to analyze the thread information and to know the different statuses 111. 112. 113. Can I enable requests to a jdbc connection pool for a database connection to How does a file store compare with a JDBC store? Which of the following attributes in the monitoring tab for a JDBC connection

wait until a connection is available? A) File store has no backup and jdbc store has backup. pool in the administrative console tell us how many clients are currently waiting for a connection? A) Waiting connections current count 114. 115. A) 116. 117. 118. 119. 120. 121. 122. 123. 124. 125. 126. 127. 128. 129. 130. 131. 132. 133. What is heap and how to define max and min heap size? What is the difference between authentication and authorization? Authentication : valid user or not. Authorization: what are the resources user has to access. What is work manager? How do we configure work managers? What can be various reasons for a server crash? How do we differentiate between server crash and server hang issue? What are the different activities involved in performance tuning? Define the relation between oracle soa suite and weblogic? What are all the functional differences between fusion em console and wls List some key fusion middleware 11g products and their usage in brief? Define key components/building blocks/basic architecture of soa suite? What is the role of mds in ofmw? What is a SOA composite? What is the payload and how many types of payloads are available in business What is the path of server related log files in SOA and what is the important log What is synchronous and asynchronous process in BPEL? What is various adapters used in your SOA Application? What is the farm in EM console? What is partition? What are all default adapters available in soa infra? What is the mediators usage?

A) JVM tuning, memory tuning, jdbc tuning,network tuning,db tuning, jms tuning

admin console?

process? file?

134. 135. 136. 137. 138.

As admin will you do any admin activity to db adapter? What are all the different administrative tools available in SOA environment? How to deploy the applications in SOA? What are all the available service engines in SOA infra? What is the usage of file adapter?

Você também pode gostar