Welcome!

Weblogic Authors: Yeshim Deniz, Elizabeth White, Michael Meiner, Michael Bushong, Avi Rosenthal

Related Topics: Weblogic

Weblogic: Article

New Deployment Model in BEA WebLogic Server 7.0

New Deployment Model in BEA WebLogic Server 7.0

The release of BEA WebLogic Server 7.0 offered several new features such as Web services; a pluggable, flexible security infrastructure; a migratable framework; new developer tools; JMS; and a new deployment model to provide a highly reliable framework for scalable and secure applications.

In this article I'll talk about the deployment model introduced in WebLogic Server 7.0 and the different modes of application staging.

New Deployment Model
The new deployment model helps us prevent inconsistent deployment states across servers, especially clustered servers.

In previous versions of WebLogic Server, when an application was deployed, the admin server sent a copy of the application file(s) to all the targeted servers. The main problem with this approach is, if deployment of an application fails to any of these targeted servers, the entire deployment's state across its target servers became inconsistent. The second problem was, since the admin server copyied the files to managed servers upon their restart, server start-up was delayed as all the JSP's had to be compiled.

The new deployment model (aka "2 phase deployment protocol") was introduced to solve this problem in addition to maintaining domain consistency. In other words, this model ensures homogeneous application deployment in Clusters.

It also ensures better status reporting for success/failure of deployments. The WebLogic Server 6.x deployment style will continue to work as is; however, you are strongly encouraged to use the new deployment model as it is highly flexible and rich in terms of its new features:

  • Consistent deployment states for clusters: If an application targeted to a cluster fails on any of the cluster members in the prepare phase or in the activate phase, the application is not activated on any of the cluster members. This helps to ensure that the cluster is kept homogeneous.
  • Application ordering: At server startup, you set the order of application activations.
  • Improved API: A simple API separates configuration from the actual deployment operations. When a deployment is requested, this API will create the necessary configuration (MBeans) for you.
  • Deployment status: It is now easier to track the progress of a deployment, especially when it has multiple targets.

    Now let's talk about the phases in the new deployment model.

  • Prepare Phase (also known as first phase): The container prepares the application across all target servers. The container distributes or copies files and prepares the application and its components for activation, validating them and performing error checks on them. The purpose of the prepare phase is to ensure that the application and its components are in a state in which they can be reliably deployed.
  • Activation Phase (also known as second phase): The actual deployment of the application or activation is done in this phase. After it is completed, the application is made available to clients.

    If deployment of an application fails in either the prepare or activation phase, then the cluster deployment will fail. In the case of a non-cluster environment, the application won't be prepared or activated.

    Application Staging
    To efficiently support Content Management Providers, WebLogic Server 7.0 introduced several staging modes, described below.

    Nostage
    You do not need to copy application files to another location. A server in nostage mode will run applications deployed to it directly from their source directories. For example:

    java weblogic. Deployer url {admin-url}
    -username {admin-user} -activate -nostage
    -source c:/myapps/myapp.ear -targets managed-server1
    -password {admin-password}

    This command activates the EAR specified with the name myapp. The application is deployed to the targeted server, which in this case is called managed-server1.

    The -nostage option indicates that the application path "c:/myapps" is available on all of the servers in the domain and that it is not necessary to "stage" or transfer the files to the managed servers (e.g., shared file system).

    This staging mode may not be helpful if admin & managed servers are in different machines or in different Operating Systems.

    Stage
    The stage mode copies application files to servers targeted in deployment phase. This means that the application will automatically be copied to the staging directory on the server. The servers will initialize and run the application from this directory.

    java weblogic.Deployer url {admin-url} -username
    {admin-user} -password {admin-password} -activate -stage
    -source c:/myapps/myapp.ear -targets managed-server1

    This command activates the EAR specified with the name myapp. The application is deployed to the targeted server, which in this case is called managed-server1.

    The -stage option indicates that the application files are copied from -source directory to a directory with the application name under each target server's staging directory.

    External_stage
    The administrator manually copies files to the server's staging directory. In the external stage mode, the application will be run from a staging directory to which an external entity is expected to distribute the files. (e.g., CMP's)

    java weblogic.Deployer url {admin-url} -username {admin-user}
    -password {admin-password} -activate -external_stage
    -source C:/myapp/myapp.ear -targets managed-server1, managed-server2

    This command activates the EAR specified with the name myapp. The application is deployed to the targeted server, which in this case is called managed-server1.

    The -external_stage option indicates that the application files expect to be copied under each target server's staging directory.

    Default Staging modes
    For Admin servers, the default is "nostage". For Managed Servers, the default is "stage".

    The staging directory for each server is located under $WL_HOME/user_projects/mydomain/{server_name}/stage

    Available Deployment Tools for Two-Phase Deployment
    WebLogic Server 7.0 provides the following deployment tools to deploy applications using the two-phase deployment model:

    1. weblogic.Deployer command line utility
    2. WLS admin console
    3. WebLogic Builder
    4. Deployment via applications folder
    Conclusion
    In this article we looked at the new deployment model introduced in WebLogic Server 7.0, which ensures homogeneous deployments in a clustered environment. I hope this will help you choose the appropriate staging mode depending on your deployment needs.

    References

  • http://e-docs.bea.com/wls/docs70/programming/deploying.html
  • java weblogic. Deployer - examples: http://e-docs.bea.com/wls/docs70/faq/deploy.html#733195
  • More Stories By Kumar Allamraju

    Kumar Allamraju is a Sr. Developer Relations Engineer at BEA Systems in WebLogic server
    support division based in San Francisco. Kumar has 5 yrs of experience in object oriented
    programming and in J2EE related technologies. He has a Bachelors degree in Computer Science

    Comments (0)

    Share your thoughts on this story.

    Add your comment
    You must be signed in to add a comment. Sign-in | Register

    In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


    @ThingsExpo Stories
    SYS-CON Events announced today that CollabNet, a global leader in enterprise software development, release automation and DevOps solutions, will be a Bronze Sponsor of SYS-CON's 20th International Cloud Expo®, taking place from June 6-8, 2017, at the Javits Center in New York City, NY. CollabNet offers a broad range of solutions with the mission of helping modern organizations deliver quality software at speed. The company’s latest innovation, the DevOps Lifecycle Manager (DLM), supports Value S...
    SYS-CON Events announced today that Outscale will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Outscale's technology makes an automated and adaptable Cloud available to businesses, supporting them in the most complex IT projects while controlling their operational aspects. You boost your IT infrastructure's reactivity, with request responses that only take a few seconds.
    SYS-CON Events announced today that Peak 10, Inc., a national IT infrastructure and cloud services provider, will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Peak 10 provides reliable, tailored data center and network services, cloud and managed services. Its solutions are designed to scale and adapt to customers’ changing business needs, enabling them to lower costs, improve performance and focus intern...
    The 21st International Cloud Expo has announced that its Call for Papers is open. Cloud Expo, to be held October 31 - November 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA, brings together Cloud Computing, Big Data, Internet of Things, DevOps, Digital Transformation, Machine Learning and WebRTC to one location. With cloud computing driving a higher percentage of enterprise IT budgets every year, it becomes increasingly important to plant your flag in this fast-expanding busin...
    Internet of @ThingsExpo, taking place October 31 - November 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA, is co-located with the 21st International Cloud Expo and will feature technical sessions from a rock star conference faculty and the leading industry players in the world. @ThingsExpo Silicon Valley Call for Papers is now open.
    As cloud adoption continues to transform business, today's global enterprises are challenged with managing a growing amount of information living outside of the data center. The rapid adoption of IoT and increasingly mobile workforce are exacerbating the problem. Ensuring secure data sharing and efficient backup poses capacity and bandwidth considerations as well as policy and regulatory compliance issues.
    DevOps is often described as a combination of technology and culture. Without both, DevOps isn't complete. However, applying the culture to outdated technology is a recipe for disaster; as response times grow and connections between teams are delayed by technology, the culture will die. A Nutanix Enterprise Cloud has many benefits that provide the needed base for a true DevOps paradigm.
    SYS-CON Events announced today that SoftLayer, an IBM Company, has been named “Gold Sponsor” of SYS-CON's 18th Cloud Expo, which will take place on June 7-9, 2016, at the Javits Center in New York, New York. SoftLayer, an IBM Company, provides cloud infrastructure as a service from a growing number of data centers and network points of presence around the world. SoftLayer’s customers range from Web startups to global enterprises.
    Five years ago development was seen as a dead-end career, now it’s anything but – with an explosion in mobile and IoT initiatives increasing the demand for skilled engineers. But apart from having a ready supply of great coders, what constitutes true ‘DevOps Royalty’? It’ll be the ability to craft resilient architectures, supportability, security everywhere across the software lifecycle. In his keynote at @DevOpsSummit at 20th Cloud Expo, Jeffrey Scheaffer, GM and SVP, Continuous Delivery Busine...
    SYS-CON Events announced today that Loom Systems will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Founded in 2015, Loom Systems delivers an advanced AI solution to predict and prevent problems in the digital business. Loom stands alone in the industry as an AI analysis platform requiring no prior math knowledge from operators, leveraging the existing staff to succeed in the digital era. With offices in S...
    SYS-CON Events announced today that DivvyCloud will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. DivvyCloud software enables organizations to achieve their cloud computing goals by simplifying and automating security, compliance and cost optimization of public and private cloud infrastructure. Using DivvyCloud, customers can leverage programmatic Bots to identify and remediate common cloud problems in rea...
    SYS-CON Events announced today that Tintri, Inc, a leading provider of enterprise cloud infrastructure, will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Tintri offers an enterprise cloud platform built with public cloud-like web services and RESTful APIs. Organizations use Tintri all-flash storage with scale-out and automation as a foundation for their own clouds – to build agile development environments...
    SYS-CON Events announced today that Progress, a global leader in application development, has been named “Bronze Sponsor” of SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Enterprises today are rapidly adopting the cloud, while continuing to retain business-critical/sensitive data inside the firewall. This is creating two separate data silos – one inside the firewall and the other outside the firewall. Cloud ISVs ofte...
    SYS-CON Events announced today that Tappest will exhibit MooseFS at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. MooseFS is a breakthrough concept in the storage industry. It allows you to secure stored data with either duplication or erasure coding using any server. The newest – 4.0 version of the software enables users to maintain the redundancy level with even 50% less hard drive space required. The software func...
    SYS-CON Events announced today that EARP will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. "We are a software house, so we perfectly understand challenges that other software houses face in their projects. We can augment a team, that will work with the same standards and processes as our partners' internal teams. Our teams will deliver the same quality within the required time and budget just as our partn...
    SYS-CON Events announced today that Interoute has been named “Bronze Sponsor” of SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Interoute is the owner operator of Europe's largest network and a global cloud services platform, which encompasses over 70,000 km of lit fiber, 15 data centers, 17 virtual data centers and 33 colocation centers, with connections to 195 additional partner data centers. Our full-service Unifie...
    SYS-CON Events announced today that Super Micro Computer, Inc., a global leader in compute, storage and networking technologies, will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Supermicro (NASDAQ: SMCI), the leading innovator in high-performance, high-efficiency server technology, is a premier provider of advanced server Building Block Solutions® for Data Center, Cloud Computing, Enterprise IT, Hadoop/...
    SYS-CON Events announced today that Carbonite will exhibit at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Carbonite protects your entire IT footprint with the right level of protection for each workload, ensuring lower costs and dependable solutions with DoubleTake and Evault.
    SYS-CON Events announced today that Technologic Systems Inc., an embedded systems solutions company, will exhibit at SYS-CON's @ThingsExpo, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Technologic Systems is an embedded systems company with headquarters in Fountain Hills, Arizona. They have been in business for 32 years, helping more than 8,000 OEM customers and building over a hundred COTS products that have never been discontinued. Technologic Systems’ pr...
    SYS-CON Events announced today that Cloudistics, an on-premises cloud computing company, has been named “Bronze Sponsor” of SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. Cloudistics delivers a complete public cloud experience with composable on-premises infrastructures to medium and large enterprises. Its software-defined technology natively converges network, storage, compute, virtualization, and management into a ...