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

Related Topics: Weblogic

Weblogic: Article

WebLogic on the Mac

A development environment worthy of serious consideration

You may not be aware of it yet, but Mac OS X - version 10.3, better known as Panther - is a great Java development environment.

I am a fairly recent Mac convert from the Windows and sometimes Unix/Linux world that I lived in. Maybe you are like me. Maybe aliens have abducted your friends and have turned them into Mac converts as well. Maybe you should join us. Speaking for myself, being able to use the Unix-based Mac OS X for WebLogic/J2EE development has given me yet another reason to be both a Java and a Mac Evangineer.

So what makes Mac OS X such a great Java development environment? Let's start with the best user interface on the planet. Add to that the core power of Unix and the ability to develop in an environment that more closely simulates the likely deployment environment for many enterprise applications (i.e., Unix-based Solaris, HPUX, and Linux). Top it all off with the use of BEA WebLogic Server and WebLogic Workshop for a surprising package of ease of use, power, and productivity.

This article is not a tutorial on WebLogic Server/WebLogic Workshop, or on Mac OS X, but it is an overview of where these technologies meet to create something that is unparalleled in the industry - a J2EE development environment on a Unix desktop done right. I will, however, provide you with basic instructions on how to set up your Mac on a productive WebLogic and WebLogic Workshop development environment. I used these instructions myself to set up WebLogic Server and Workshop successfully on my own Power Mac G5 and have used this environment to quickly and successfully create a small Web application. This application captures information, sends the information through a Page Flow (as a FormBean), writes that information to disk by using a Workshop FileControl, and finally exposes this functionality as a Web service. To do this, I created my own Workshop Domain using the Domain Configuration Wizard. All of this worked just fine, although there were some bumps along the way. I will share some of these with you.

It is important to note that at this time the Mac OS X and the Mac JVM are not official BEA-supported platforms. You must use this information within that context. So, it is up to the developer community to take it to the next level - take WebLogic Server and Workshop for a spin, report any bugs, make suggestions, and get involved.

Mac OS X Development Benefits

I wasn't going to spend much time justifying the Mac as a development platform, but I realized that a number of people may not have followed the astonishing progress of the Mac lately. You probably relate to the Mac as the "right brain" in the computing world, the creative side used by graphic artists and other nontechnical kin.

The release of Mac OS X offers the power of Unix as the foundational OS substrate with, arguably, the best GUI on the planet. The only other desktop OS to effectively combine Unix and GUI is Linux. We all love Linux, but from an ease-of-use and overall desktop capabilities standpoint, it can't hold a candle to the Mac's eadership in interface technology and implementation.

But don't just take my word for it; even the Father of Java, James Gosling, has fully embraced the Mac platform (see www.apple.com/pro/science/gosling/). According to the article, James and most of his development team love developing on a Mac because it blends the power of UNIX with the best MMI (man-machine interface) or user experience available. That is to say, it provides the power of a Unix server with the ease of operation that a Windows system aspires to.

An article in the March 2004 issue of Java Developer's Journal (Vol. 9, issue 3) talks through some additional benefits of Java on Mac OS X (www.sys-con.com/story/?storyid=43949&DE=1 ).

Here are some detailed reasons why Mac OS X is a great WebLogic/WebLogic Workshop development environment.

  1. Java delivered as part of core system (i.e., JDK included): Java is well integrated into the OS, not an afterthought.
  2. GUI: Unequaled ease of-use and history of excellence that other "alternative" desktops don't have.
  3. Unix core: Utilities and productivity tools all at your fingertips.
    - Keep your valuable UnIX skills up while improving your productivity with WLW's 10 x productivity gains: You can issue all your favorite commands right from the Terminal window (available in the Applications/Utilities folder).
    - Solid UNIX distribution: Distribution of Unix on Mac OS X is BSD (Berkeley Software Distribution) that has been in existence since the '60s.
  4. Integrates into Office Environment: Plays well with productivity tools like MS Office Suite for Mac (used in writing this article) so you will not be isolated from your team when it comes to sharing standard documents.
  5. Simple networking: Hook your Mac up to your home network, allowing you to do cross-platform validation and clustering in the comfort of your home.
Now let's get on with the task at hand of installing, running, and developing with BEA WebLogic Server and WebLogic Workshop.

The installation process really is as easy as 1-2-3.

  1. Download the correct distribution
  2. Run the installer
  3. Fix the Mac JVM distribution
With those simple steps completed you are now ready to run WebLogic Server and WebLogic Workshop, but you might want to refine the environment a little.


The following instructions assume that you are using Mac OS X 10.3 and have JDK level 1.4.2 installed. You can check this by (a) running "java -version", which should show you that the version is 1.4.2_03 (as of this writing); or (b) by navigating to /System/Library/Frameworks/JavaVM.framework/Versions, from which you should see folders for 1.2/1.3/1.3.1/1.4.2. If 1.4.2 is not the version you see as the most recent folder, make sure to upgrade before continuing.

Step 1: Download the Installation
This part is easy, as long as you have a high-speed connection. The first thing to know is which distribution of WebLogic Server 8.1 SP2 to get from BEA's download site (Click Here !). Your first choice is (a) WebLogic Platform Net Installer, (b) WebLogic Server Package Installer, or (c) Mail CD. I used option "b"and selected the IBM AIX (5.1,5.2) option, which will allow you to download a JAR file called pj_server812_generic.jar. Save this file to any folder that you use to store installation files. This file is 221.4 MB.

The file you download is the "generic" distribution that ends in ".jar" and is labeled as the AIX version on the download site. Note that this WebLogic Server/Workshop distribution, unlike, for example, the Windows distribution, does not include a JDK. We will use the JDK distribution that comes with Mac OS X 10.3 (Panther). More discussion on using the native JDK is in the "Fix the Mac Java Distribution"section.

Step 2: Run the GUI Installer
Now for installing the software. I will discuss using the GUI install wizard, though there is the option to install from the command line and even to do a silent installation. I will not bore you with the details, but you follow the directions listed in the installation guide at edocs.bea.com/wls/docs81/install/instprg.html#1054300.

Essentially, you run the following command and you are off and running/installing. The wizard walks you through the handful of steps to finish the installation.

java -jar pj_server811_generic.jar

Step 3: Fix the Mac Java Distribution
A word on the base install of your Mac JDK: the integration between the JDK and the OS is tighter than it is on other platforms. In fact Mac OS X has a layer of indirection that makes upgrading to new JDKs easy for the average user, but can be a little confusing at first glance to developers who need to know where, for example, the JAVA_HOME is.

If you try to run WebLogic Server or Workshop before you do this "fix," your servers will not start up because some directories are missing that Server and Workshop look for and, when missing, they will cause Server and Workshop to assume that you are not pointing to a valid JDK install. Further background information on the Mac JVM layout can be gleamed from an outstanding book, Mac OS X for Java Geeks by Will Iverson (O'Reilly; 2003).

Issue the following commands to allow WebLogic Server/Workshop to see your JDK as valid:

  • sudo su: This is the substitute-user command allowing a permitted user to execute a command as the superuser or another user, as specified in the sudoers file.
  • mkdir -p /Library/Java/Home/jre/bin: Create the missing bin directory.
  • mkdir /Library/Java/Home/jre/lib: Create the missing lib directory.
  • cd /Library/Java/Home/jre/bin
  • ln -s ../../bin/java: Create a symbolic directory link to existing Java executables directory. A link is useful for maintaining multiple copies of a file in many places at once without using up storage for the "copies'"; instead, a link "points" to the original copy.
  • cd ../lib
  • ln -s ../../../Classes/classes.jar rt.jar: Create symbolic file links to existing Java library files.

Refining the Installation

After you open a terminal shell and you start the WebLogic Workshop IDE (or ISE as Gartner would call it), and attempt to run an application, Workshop tries to use Internet Explorer as the default browser. It is worth noting that you can theoretically set the browser to be anything you want. I was able to get Safari to partially work, meaning that it will auto-launch as the test harness from WebLogic Workshop when you hit the Run option. I was not, however, able to get the Mac version of Internet Explorer to auto-launch. The good news is that Netscape 7.1 for Mac OS X ran beautifully!

An issue that I ran into is that the HTML and Applet that is part of the WebLogic Server console completely and utterly refuses to load in the Safari browser. So, whereas I was using Safari for the Workshop browser, for administration in the WebLogic Server console, you must use another browser such as IE.

To specify the browser that Workshop will use, you need to set the IDE properties by going to the Tools>IDE Properties menu.

Initially, I selected "/Applications/Safari.app/Contents/MacOS/Safari" to indicate Safari as the browser. It is interesting that the "Browse" button on this screen will let you navigate to the correct directory but this directory is not visible to Mac's Finder (analogous to Window Explorer) unless you CTRL-CLICK or right click the Safari icon and select "Show Package Contents" from the context menu and drill in from there.

I was able to get Safari auto-launched from Workshop's Run option, but a lot of extraneous information is pre-pended to the URL. If you clear this garbage (file:///Users/patshepherd/beaplat/weblogic81/workshop/) and fix the single slash just after the port number (http:/localhost:7001/GettingStarted/Controller.jpf > http://localhost:7001/GettingStarted/Controller.jpf), then the application will run and you will even be able to debug your application. This, quite frankly, can be quite a speed bump in the standard build-test development cycle (see Figure 1).

When I found that Netscape 7.1 will auto-launch, I was overjoyed. That was until I tried to hit the WebLogic Server console and found that Netscape does not load the console's applet(s) either. Figure 2 shows the path I used to register the Netscape browser to auto-launch.

In summary, the Netscape browser is your best bet to use as Workshop's auto-launched browser, but none of the browsers will load the Server console applet(s). One quirk you will notice, though, is that Netscape will not automatically notify Workshop that the debug session is over when Netscape is closed - this is normal behavior on the Windows platform. The Netscape browser can be obtained at channels.netscape.com/ns/browsers/download.jsp.

Running the Domain Configuration Tool

The Domain Configuration Tool allows you to quickly create a domain from a predefined template.

While creating your domain, you will be asked to specify the directory where your JVM lives because, obviously, you are using your native Mac OS X JVM and none has been supplied as part of the generic distribution we have installed (see Figure 3).

I got my domain running by selecting the linked directory shown in the browser tree which is, as discussed earlier, a link to the /Library/Java/Home directory we fixed earlier (see Figure 4).

Tips and Tricks

Cut and Paste
One joke I always tell is that "Copy, Paste" is the world's most prevalent form of code reuse. So, you might get frustrated using the standard Apple key combination of CMD-C for "copy" or CMD-V for paste. It is worth noting that the shortcut keystrokes in Workshop are exactly the same as they would be in the Windows world where, for example, CTRL-C is the standard "copy" combination. In fact, all key combinations are the same as their Windows brethren (with the exception of things like CMD-Q for "quit").

Terminal Velocity
Now is a great time to mention a very useful feature - the ability to drag a script file from finder and drop it right into the terminal shell. No more need to type in long path and file information to execute a start script, for example. Figures 5a and 5b show the result of dragging the file "config.sh"onto the terminal shell to start the Domain Configuration Tool, but the process works equally well for launching the start scripts for WebLogic Workshop or WebLogic Server.


For developers who are interested in a Java development environment that gives them "the best of both worlds" - the best user interface coupled with the power of a very mature UNIX distribution - you should seriously consider Mac OS X. While Apple was slow to keep the JVM versions in OS 9 up to date (never made it past 1.1.8), with Mac OS X Apple is now shipping a native 1.4.2 JVM that establishes Java as a first-class citizen in the Mac world.

Adding BEA's J2EE-based Application Platform Suite (APS), developers can leverage the power of Mac OS X to begin to develp world-class, service-oriented applications.

There are parts and pieces of Workshop that do not fully work on Mac OS X, but keep in mind that, as I stated earlier, Mac OS X is not currently a BEA-supported platform and has not gone through rigorous certification. With the BEA and Mac communities working together, Mac OS X could become a premiere development environment for truly serious developers. If you want to register with BEA your interest in making Mac OS X a BEA-supported platform, please e-mail [email protected] and Put "OS.X interest" in the subject.


I want to acknowledge some very useful postings by various users on O'Reilly Developer WebLogs hosted by BEA's Rod Chavez. There is a steady stream of postings there and interested readers should feel free to contribute to the momentum with their own postings. (www.oreillynet.com/pub/wlg/4091).

More Stories By Pat Shepherd

Pat Shepherd has been an active member of the Java revolution since its inception in 1995. He has written for several magazines and was a technical editor for the Sams book BEA WebLogic Platform 7. He has worked at BEA for more than five years and is currently a global account architect who spreads the Java/SOA message everywhere he goes.

Comments (1)

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
DevOpsSummit New York 2018, colocated with CloudEXPO | DXWorldEXPO New York 2018 will be held November 11-13, 2018, in New York City. Digital Transformation (DX) is a major focus with the introduction of DXWorldEXPO within the program. Successful transformation requires a laser focus on being data-driven and on using all the tools available that enable transformation if they plan to survive over the long term. A total of 88% of Fortune 500 companies from a generation ago are now out of bus...
Cloud Expo | DXWorld Expo have announced the conference tracks for Cloud Expo 2018. Cloud Expo will be held June 5-7, 2018, at the Javits Center in New York City, and November 6-8, 2018, at the Santa Clara Convention Center, Santa Clara, CA. Digital Transformation (DX) is a major focus with the introduction of DX Expo within the program. Successful transformation requires a laser focus on being data-driven and on using all the tools available that enable transformation if they plan to survive ov...
DXWordEXPO New York 2018, colocated with CloudEXPO New York 2018 will be held November 11-13, 2018, in New York City and will bring together Cloud Computing, FinTech and Blockchain, Digital Transformation, Big Data, Internet of Things, DevOps, AI, Machine Learning and WebRTC to one location.
DXWorldEXPO LLC announced today that ICOHOLDER named "Media Sponsor" of Miami Blockchain Event by FinTechEXPO. ICOHOLDER give you detailed information and help the community to invest in the trusty projects. Miami Blockchain Event by FinTechEXPO has opened its Call for Papers. The two-day event will present 20 top Blockchain experts. All speaking inquiries which covers the following information can be submitted by email to [email protected]com. Miami Blockchain Event by FinTechEXPO also offers s...
DXWorldEXPO | CloudEXPO are the world's most influential, independent events where Cloud Computing was coined and where technology buyers and vendors meet to experience and discuss the big picture of Digital Transformation and all of the strategies, tactics, and tools they need to realize their goals. Sponsors of DXWorldEXPO | CloudEXPO benefit from unmatched branding, profile building and lead generation opportunities.
Dion Hinchcliffe is an internationally recognized digital expert, bestselling book author, frequent keynote speaker, analyst, futurist, and transformation expert based in Washington, DC. He is currently Chief Strategy Officer at the industry-leading digital strategy and online community solutions firm, 7Summits.
Digital Transformation and Disruption, Amazon Style - What You Can Learn. Chris Kocher is a co-founder of Grey Heron, a management and strategic marketing consulting firm. He has 25+ years in both strategic and hands-on operating experience helping executives and investors build revenues and shareholder value. He has consulted with over 130 companies on innovating with new business models, product strategies and monetization. Chris has held management positions at HP and Symantec in addition to ...
Cloud-enabled transformation has evolved from cost saving measure to business innovation strategy -- one that combines the cloud with cognitive capabilities to drive market disruption. Learn how you can achieve the insight and agility you need to gain a competitive advantage. Industry-acclaimed CTO and cloud expert, Shankar Kalyana presents. Only the most exceptional IBMers are appointed with the rare distinction of IBM Fellow, the highest technical honor in the company. Shankar has also receive...
Enterprises have taken advantage of IoT to achieve important revenue and cost advantages. What is less apparent is how incumbent enterprises operating at scale have, following success with IoT, built analytic, operations management and software development capabilities - ranging from autonomous vehicles to manageable robotics installations. They have embraced these capabilities as if they were Silicon Valley startups.
Poor data quality and analytics drive down business value. In fact, Gartner estimated that the average financial impact of poor data quality on organizations is $9.7 million per year. But bad data is much more than a cost center. By eroding trust in information, analytics and the business decisions based on these, it is a serious impediment to digital transformation.
Predicting the future has never been more challenging - not because of the lack of data but because of the flood of ungoverned and risk laden information. Microsoft states that 2.5 exabytes of data are created every day. Expectations and reliance on data are being pushed to the limits, as demands around hybrid options continue to grow.
The standardization of container runtimes and images has sparked the creation of an almost overwhelming number of new open source projects that build on and otherwise work with these specifications. Of course, there's Kubernetes, which orchestrates and manages collections of containers. It was one of the first and best-known examples of projects that make containers truly useful for production use. However, more recently, the container ecosystem has truly exploded. A service mesh like Istio addr...
Digital Transformation: Preparing Cloud & IoT Security for the Age of Artificial Intelligence. As automation and artificial intelligence (AI) power solution development and delivery, many businesses need to build backend cloud capabilities. Well-poised organizations, marketing smart devices with AI and BlockChain capabilities prepare to refine compliance and regulatory capabilities in 2018. Volumes of health, financial, technical and privacy data, along with tightening compliance requirements by...
As IoT continues to increase momentum, so does the associated risk. Secure Device Lifecycle Management (DLM) is ranked as one of the most important technology areas of IoT. Driving this trend is the realization that secure support for IoT devices provides companies the ability to deliver high-quality, reliable, secure offerings faster, create new revenue streams, and reduce support costs, all while building a competitive advantage in their markets. In this session, we will use customer use cases...
Business professionals no longer wonder if they'll migrate to the cloud; it's now a matter of when. The cloud environment has proved to be a major force in transitioning to an agile business model that enables quick decisions and fast implementation that solidify customer relationships. And when the cloud is combined with the power of cognitive computing, it drives innovation and transformation that achieves astounding competitive advantage.
With 10 simultaneous tracks, keynotes, general sessions and targeted breakout classes, @CloudEXPO and DXWorldEXPO are two of the most important technology events of the year. Since its launch over eight years ago, @CloudEXPO and DXWorldEXPO have presented a rock star faculty as well as showcased hundreds of sponsors and exhibitors! In this blog post, we provide 7 tips on how, as part of our world-class faculty, you can deliver one of the most popular sessions at our events. But before reading...
The best way to leverage your Cloud Expo presence as a sponsor and exhibitor is to plan your news announcements around our events. The press covering Cloud Expo and @ThingsExpo will have access to these releases and will amplify your news announcements. More than two dozen Cloud companies either set deals at our shows or have announced their mergers and acquisitions at Cloud Expo. Product announcements during our show provide your company with the most reach through our targeted audiences.
The IoT Will Grow: In what might be the most obvious prediction of the decade, the IoT will continue to expand next year, with more and more devices coming online every single day. What isn’t so obvious about this prediction: where that growth will occur. The retail, healthcare, and industrial/supply chain industries will likely see the greatest growth. Forrester Research has predicted the IoT will become “the backbone” of customer value as it continues to grow. It is no surprise that retail is ...
Andrew Keys is Co-Founder of ConsenSys Enterprise. He comes to ConsenSys Enterprise with capital markets, technology and entrepreneurial experience. Previously, he worked for UBS investment bank in equities analysis. Later, he was responsible for the creation and distribution of life settlement products to hedge funds and investment banks. After, he co-founded a revenue cycle management company where he learned about Bitcoin and eventually Ethereal. Andrew's role at ConsenSys Enterprise is a mul...
DXWorldEXPO LLC announced today that "Miami Blockchain Event by FinTechEXPO" has announced that its Call for Papers is now open. The two-day event will present 20 top Blockchain experts. All speaking inquiries which covers the following information can be submitted by email to [email protected] Financial enterprises in New York City, London, Singapore, and other world financial capitals are embracing a new generation of smart, automated FinTech that eliminates many cumbersome, slow, and expe...