Monday, 18 June 2012


weblogic interview questions and answers

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 application’s 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 such as images
§                   Decrease duplication of files across applications
§                   Are configured in weblogic.xml

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 packaged in an .ear file.
§                   These resources include:
§                        Web applications (.war)
§                        EJB applications (.jar)
§                        Java applications (.jar)
§                        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 application’s 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?
    • WebLogic’s 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:

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
   Undeploy an application
           java weblogic.Deployer -adminurl t3://adminserver:7001 
           -username myuser –password mypass –name HRServices
  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



Post a Comment