INFO-LINK




Creating Dynamic Singletons & the Loki Library


April, 2005: Creating Dynamic Singletons & the Loki Library

Curtis Krauskopf is the principal of The Database Managers Inc., where he creates decompilers. He can be contacted at curtis@ decompile.com.


My C++ program is using a third-party database library. It uses one object that represents the state of the database. The database object can be dynamically deleted to release all of its resources and it needs to be automatically deleted if it still exists at program termination. "So how am I going to solve this problem?" I ask myself.

The "one object" requirement screams for a Singleton solution. But the ability to dynamically destroy a Singleton isn't handled by most Singleton implementations [1]. After the Singleton has been manually destroyed, it needs to automatically resurrect itself the next time it's used in the program. Also, if the Singleton exists when the program terminates, it needs to destroy itself to release its resources.

In this article, I examine the trade-offs in implementing the Singleton design pattern, show how the Loki C++ Library of design patterns and idioms accommodates them, and then define a new policy to solve a difficult problem that Loki does not address. Along the way, I illustrate several issues related to std::atexit, create a new policy that works well within a policy-based framework, and work around the abstraction limitations offered by Loki's Singleton. The policy encapsulates a technique in which a Singleton watches the lifetime of another Singleton.

The Loki library has a Singleton template called a SingletonHolder, which lets you instantiate a Singleton from any struct or class with a constructor that takes no parameters [2]. The Loki implementation provides template policies that let you specify how the Singleton is created, how it is destroyed, and even what threading model it uses (either single threaded or multithreaded).

From a user's perspective, all of these features are wrapped into a single typedef that looks like this:

typedef SingletonHolder<MyClass,
  CreateUsingNew,
  DefaultLifetime,
  SingleThreaded
> obj;

And because of default parameters in the template, this declaration can be simplified to be more friendly looking:

typedef SingletonHolder<MyClass>obj;

The Singleton is accessed by using obj::Instance(). The Instance() method returns a reference to the Singleton so you access the Singleton's methods with the dot operator, like this:

obj::Instance().method();

SingletonHolder Policies

There are three template policies that specify how a Singleton is created: CreateUsingNew, CreateUsingMalloc, and CreateStatic. Both CreateUsingNew and CreateUsingMalloc do that obvious thing of creating the object using new or malloc. CreateStatic uses placement new to create the object in static memory.

There are four template policies that define the Singleton's lifetime: DefaultLifetime, NoDestroy, PhoenixSingleton, and SingletonWithLongevity.

The DefaultLifetime policy mimics the lifespan of a normal global C++ object: The object lives until the program terminates, then the object's destructor is called.

The NoDestroy policy is the simplest—the Singleton is not destroyed. Undestroyed Singletons are not a memory leak but are a potential resource leak [3].

The PhoenixSingleton is an interesting policy because it can resurrect a Singleton during program termination. When the Singleton is needed after it has been destroyed (when the program is terminating), the PhoenixSingleton policy causes the Singleton to be reincarnated. All of the code needed for this ability is invisible to users. Here's an example of a PhoenixSingleton declaration and use:

class Example {
public:
  void method() { ... }
};
typedef SingletonHolder<
  Example,
  CreateUsingNew,
  PhoenixSingleton
> myExample;
 ...
myExample()::Instance().method();

Despite its name, the SingletonWithLongevity policy does not create a Singleton that retains its state after it has been destroyed (it does not create a persistent Singleton). Instead, it lets users specify the order in which Singletons are destroyed. With this policy, regardless of what order the Singletons were created or first accessed, the Singletons are destroyed in a user-defined priority [4].

The SingletonWithLongevity policy has a static function called SetLongevity. Both globally and locally declared dynamic objects can be scheduled for destruction by using SetLongevity():

Example *pLocal =
  new Example("Dynamic Example");
SetLongevity(pLocal, 5);

The default (third) parameter for SetLongevity is:

Loki::Private::Deleter<Example>::Delete

This is a static function that simply calls delete on whatever object is passed to it. SetLongevity uses std::atexit() to register a callback function that deletes the object during program termination. Listing 1 is a Keyboard Singleton object scheduled for destruction with a longevity value of 10.

Back to PhoenixSingleton

Whereas SingletonWithLongevity lets users specify the destruction order of Singletons, the PhoenixSingleton policy takes a different philosophy. It says, "I don't care what order the Singletons are destroyed; but if I need a Singleton after it has been destroyed, automatically bring it back to life and then schedule it for destruction again."

Listing 2, an example of the PhoenixSingleton policy at work, defines Example and Log classes that display text when each class's constructor and destructor execute. Log is a PhoenixSingleton.

The Example object's destructor calls the Log Singleton. If a Log Singleton doesn't exist when the Example destructor executes, a Log object is instantiated.

In main(), the longevity for the Example object is set before a Log object is instantiated. Calling SetLongevity schedules the object for destruction. This is important because, for this test program, the Log Singleton needs to be destroyed before the Example object is destroyed so that the Log Singleton is a dead reference when the Example object is destroyed. Loki causes the Log Singleton to be destroyed before the dynamically allocated Example object because the Log Singleton was the last object instantiated—this mimics automatic C++ object destruction rules. Figure 1 shows the output of Listing 2.

What should be surprising about this output is the last line—or rather, what's not the last line. If the PhoenixSingleton policy was really working, you should expect "Log d'tor" to be the last line. So why is the PhoenixSingleton policy not destroying Log a second time?

The reason is because of some oddities in the std::atexit function. Both the C and C++ Standards were unclear about what should happen when atexit() is called from within a function that itself was called when the atexit call stack is unwinding. This has been fixed in a subsequent corrigendum [5], but your compiler may not be compatible.

Common sense says "it should just work," but Andrei Alexandrescu discovered "on three widely used compilers that the behavior ranges from incorrect (resource leaks) to application crashes" [6].

Loki allows PhoenixSingletons that are resurrected to become resource leaks when the ATEXIT_FIXED symbol is not defined at compile time. Of course, one reliable way of knowing if atexit works well for functions called during exit processing on your compiler is to read the documentation. Because most compilers don't have obscure library functions documented to that degree, you can try the atexit/test.cpp program (available at http://www.cuj.com/code/).

Back To the Problem

Table 1 shows a comparison of the Loki lifetime policies and the problem. The PhoenixSingleton policy is the closest solution because its limitation is being able to handle a Singleton deleted by users. The limitation exists because there is no way to tell atexit that a function shouldn't be called anymore.

Building a Policy

I need a callback function for atexit that doesn't blindly delete a Singleton. I also need to create a policy that lets the Singleton be deleted on demand but automatically deletes the Singleton at the end of the program, if it's still alive.

DeletableSingleton seems like an appropriate name. It needs the same policy interface that the SingletonHolder lifetime policies use. Listing 3 is the public interface for DeletableSingleton.

It looks straightforward. The oddest part is the pFun parameter—it's a pointer to a static function that takes no arguments and returns void. When a SingletonHolder wants to schedule a Singleton for destruction, it calls ScheduleDestruction in the lifetime policy and passes a callback function that the policy should use when the Singleton needs to be destroyed.

Listing 4 shows a snippet of the SingletonHolder class that schedules a Singleton's destruction when the object is instantiated. Listing 5 is the DestroySingleton template method that is used to destroy SingletonHolder Singletons. This is the function pointer that is passed to ScheduleDestruction.

The way that a Singleton is destroyed depends on how it was created. Listing 5 shows that CreationPolicy<T>::Destroy is called to destroy the Singleton.

Putting all of these pieces together, this is how it works:

  1. The first time the code in Listing 4 executes, pInstance_ is null and destroyed_ is false.
  2. MakeInstance() creates an instance of the Singleton by calling CreationPolicy<T>:: Create();.
  3. MakeInstance() calls ScheduleDestruction with a callback function pointer. This is where the DestroySingleton policy gets to take over. It needs to remember the pointer function passed to DestroySingleton so that it can be called later when the Singleton needs to be deleted during program termination. ScheduleDestruction needs to register a callback function in atexit that is smart enough to not blindly delete the Singleton if it has already been deleted by users.
  4. At some point, users might manually delete the Singleton. When that happens, the private destroyed_ Boolean in SingletonHolder is set to true to signal that pInstance_ is a dead reference.
  5. The Singleton might again be referenced in the program. Since it's a dead reference when MakeInstance() is called, this time, MakeInstance() calls OnDeadReference() in the DestroySingleton policy.
  6. MakeInstance then calls CreationPolicy<T>:: Create() again to recreate the Singleton.
  7. MakeInstance then once again calls ScheduleDestruction. Because the DeletableSingleton-specific callback static function has already been registered in atexit (in step 2), ScheduleDestruction only needs to remember the pointer function passed on this iteration. This is because it might be different than on the first pass when the original (now dead) Singleton was instantiated.
  8. The program eventually terminates. atexit unwinds the function callback stack and the custom static for DestroySingleton is called. If the Singleton is still alive (if destroyed_ in SingletonHolder is false), the most recent function pointer passed to ScheduleDestruction is called to destroy the Singleton. If the Singleton has been killed manually, there is nothing for the callback function to do so, it should quietly terminate.

Based on this step-by-step account, the code for DestroySingleton's ScheduleDestruction method is in Listing 6.

GracefulDelete is a function for the DeletableSingleton policy that checks if the Singleton has been deleted. It's a static callback function that atexit calls when the program terminates.

For GracefulDelete to do its work, it needs to know the status of SingletonHolder's destroyed_ Boolean. Unfortunately, that is private data and SingletonHolder doesn't provide any method that otherwise exposes destroyed_.

Back To the Drawing Board

I could cheat and make destroyed_ public—or better (if there is such a thing as "better" cheating), I could add a method to SingletonHolder that returns destroyed_'s status.

The abstraction provided by SingletonHolder is otherwise fine, so I'll do some more work to accommodate a new policy.

I only need to know when the Singleton is manually destroyed; otherwise, I can assume it's still alive and Do The Right Thing in GracefulDelete.

The way users would manually destroy a SingletonHolder that uses the DestroySingleton policy is to call this prototype:

CreationPolicy<T>::Destroy(T*);

where CreationPolicy is the creation policy users specified for the SingletonHolder for class T. Because MakeInstance() returns a reference and Destroy takes a pointer, an actual call would look like this:

MyClass &singleton =
   myclass::MakeInstance();
CreateUsingMalloc<MyClass>
  ::Destroy(singleton);

This would certainly delete the Singleton, but there are two problems:

  • Whenever the creation policy for the Singleton changes, it's inconvenient to find all of the occurrences of Destroy and change the creation policy there, too. A typedef would simplify the work, but the typedef would still have to be changed whenever the creation policy for the Singleton was changed. If you get it wrong, the compiler will not help you because it doesn't know why you're calling Destroy—it just knows that you want to call Destroy for a particular creation policy. The compiler will use a template that uses the obsolete policy you've specified. You could be using free() to destroy your statically allocated Singletons!
  • However Destroy is called, there needs to be some kind of hook that tells DeletableSingleton that the Singleton is dead because we can't peek into SingletonHolder to get that information.

What about that Loki::Private::Deleter<...>::Delete static that is used as a default parameter to SetLongevity? It's just fine for Singletons that use the CreateUsingNew policy, but it won't work for the other policies because the Deleter static always uses delete to kill the Singleton.

Since atexit() is calling a static method to destroy the Singleton (GracefulDelete) when the program terminates, what if users called the same method? That would actually work if GracefulDelete kept track of the status of the Singleton.

The pseudocode for GracefulDelete is:

if (singleton is dead) then exit
mark singleton as dead
call SingletonHolder's callback function

The code for GracefulDelete is:

void DeletableSingleton<T>
  ::GracefulDelete()
{
  if (isDead) return;
  isDead = true;
  deleter();
}

Remember that deleter is a pointer to the SingletonHolder callback function.

Listing 7 implements the DeletableSingleton policy. The code to delete a Singleton that is using the DeletableSingleton policy is:

DeletableSingleton<MyClass>::
  GracefulDelete();

This can even be simplified by using a typedef:

typedef DeletableSingleton<MyClass>
  killMyClass;
 ...
killMyClass::GracefulDelete();

What if the typedef for the Singleton for MyClass is changed to not be a DeletableSingleton? What if it's changed to use the PhoenixSingleton or even the NoDelete policy?

The program still uses this code to try to manually delete the Singleton. The compiler won't catch this mistake, but it's not a problem. The first thing that GracefulDelete does is check if isDead is true. isDead defaults to true and it is only set false when ScheduleDestruction is called in DeletableSingleton. Since that never happens for Singletons that don't use the DeletableSingleton policy, there isn't a problem. The Singleton isn't manually deleted, but it still is automatically deleted when using policies other than NoDelete.

That's exactly what you would like to have happen. The code for manually deleting the policy does nothing when the Singleton isn't using DeletableSingleton and the code works right when the Singleton is using the DeletableSingleton policy.

Program Termination

DeletableSingleton only calls std::atexit() the first time a specific Singleton class is instantiated to prevent filling up the atexit() stack. DeletableSingletons are always deleted in the order of their first instantiation, not based on their most recent instantiation.

That leads to a problem, though. What happens if a DeletableSingleton is instantiated after its own atexit callback function has executed? In that case, based on Listing 7, the Singleton becomes a resource leak because GracefulDelete will not be passed to atexit again.

That problem can be fixed, too. Listing 8 shows the differences of Listing 7 that eliminate a resource leak. atexitCallback was made protected so that users wouldn't accidentally use it instead of GracefulDelete.

Conclusion

The Loki library provides a SingletonHolder template that is able to create a Singleton object from any user-defined class. The library is flexible enough to provide automatic deletion for most policies and to provide automatic deletion for objects allocated with new that are not otherwise deleted by users.

The PhoenixSingleton policy lets a Singleton be resurrected if it was destroyed during program termination. None of the Loki policies allow Singletons to be manually deleted by users and to provide automatic deletion if the Singleton is still alive at program termination.

The DeletableSingleton policy provides exactly those services. The GracefulDelete static is even graceful enough to not do any harm if it's called when the Singleton does not use the DeletableSingleton policy.

Because DeletableSingleton is using a template, all of the instances of DeletableSingleton<T> for any type T are using the same pairs of static Booleans (isDead and needCallback). Effectively, DeletableSingleton becomes a Singleton that is watching another Singleton.

Acknowledgment

Thanks to Andrei Alexandrescu for peer-reviewing this article and providing excellent suggestions.

References

  1. [1] Vlissides, John. "To Kill a Singleton," C++ Report, June 1996.
  2. [2] http://sourceforge.net/projects/loki-lib/.
  3. [3] Alexandrescu, Andrei. Modern C++ Design: Generic Programming and Design Patterns Applied, Addison-Wesley, 2001, page 133.
  4. [4] The errata note for Modern C++ Design, located at http://moderncppdesign.com/errata/, for page 142 reports that the comparison for LifetimeTracker::Compare is backwards—it should make higher longevity objects last longer, but instead it destroys the highest longevity objects first. Alexandrescu's note for this errata is that it has been fixed in the code on SourceForge. If your implementation of Loki does the opposite, then download the most current version of Loki and try again.
  5. [5] The full WG21 committee has voted to accept the Defect Report's Proposed Resolution as a Technical Corrigenda (ISO/IEC IS 14882:1998(E)). The solution is completely compatible with Loki's expectation of having ATEXIT_FIXED defined at compile time.
  6. [6] Alexandrescu, Andrei. Modern C++ Design: Generic Programming and Design Patterns Applied, Addison-Wesley, 2001, page 139.


Around the Web

An Events Based Algorithm for Distributing Concurrent Tasks on Multi-Core Architectures

Here's a programming model which enables scalable parallel performance on multi-core shared memory architectures.

Quick Read

Swarm: A True Distributed Programming Language

The Swarm prototype is a simple stack-based language, akin to a primitive version of the Java bytecode interpreter.

Quick Read

Key Software Development Trends

Several trends are emerging within the area of software development. Here are some of the most important trends S. Somasegar has been thinking about recently.

Quick Read

Understanding Parallel Performance

Understanding parallel performance. How do you know when good is good enough?

Quick Read

Short and Tweet: Experiments on Recommending Content from Information Streams

The authors used 12 algorithms to study the URL recommendation on Twitter as a means of better directing attention in information streams.

Quick Read



Video

Forty finalists will gather in Washington, D.C. from March 11-16 to compete for $630,000 in awards.; DDJ; Intel; science; Dr. Dobb's talks with Commonsware's Mark Murphy about what's involved in developing software for the Android operating system; Android; apple; DDJ; tablet development; The new method uses analytics technology developed by the Mayo and IBM collaboration, Medical Imaging Informatics Innovation Center, and has proven a 95 percent accuracy rate in detecting aneurysm.; Algorithm; DDJ; diagnostics; ibm; imaging; T-Mobile USA is enabling phone calls to Haiti without charges for international long distance through January 31 and retroactive to the earthquake on January 12; DDJ; mobile; wireless; Al Williams gives you a demor of One-Der: The One Instruction CPU; DDJ; At the 2010 International Consumer Electronics Show, the auto industry's first working smartphone application was unveiled; DDJ; mobile; The Bluetooth Special Interest Group (SIG) has announced the adoption of BLUETOOTH low energy wireless technology.; bluetooth; DDJ; wireless; IBM has unveiled its list of five innovations that have the potential to change how people live, work and play in cities around the world over the next five to ten years; DDJ; ibm; TeliaSonera's LTE mobile broadband commercial network in Stockholm is now the fastest and largest in the world.; broadband; DDJ; ericsson; mobile; Google has introduced, google Goggles, a visual search application on Android devices that allows users to search for objects using images rather than words; Android; DDJ; google; mobile; Visual Search Applications; Dr. Dobb's talks with David Intersimone, Vice President of Developer Relations and Chief Evangelist at Embarcadero Technologies, about RAD Studio 2010, SQL optimization and his reflections on the software industry.; database programming; DDJ; sql; Researchers from Intel Labs have created an experimental, 48-core Intel processor or "single-chip cloud computer."; cloud computing; DDJ; Intel; multicore; parallelism; The Large Hadron Collider will produce roughly 15 million gigabytes of data annually, to be accessed by a distributed computing and data storage infrastructure called the LHC Computing Grid.; CERN; DDJ; grid computing; physics; A mobile handheld device designed to let users can point, shoot and listen to printed text.; DDJ; Intel; mobile; Ericsson has become the first vendor to prove end to end interoperability in TD-LTE, another standard of 4G radio technologies designed to increase the capacity and speed of mobile telephone networks.; DDJ; ericsson; mobile; TD-LTE; According to a recent study, 80 percent of US respondents feel there are unspoken rules about mobile technology usage, and approximately 69 percent agreed that violations of these unspoken mobile manners are unacceptable.; DDJ; Intel; mobile; IBM and Canonical will introduce a software package for netbooks and other thin client devices in Africa. This is the first cloud- and premise-based Linux netbook software package offered by IBM and Canonical.; cloud computing; DDJ; ibm; His unprecedented ability to manipulate individual atoms signaled a quantum leap forward in in nanoscience experimentation and heralded in the age of nanotechnology.; DDJ; ibm; nanotechnology; IBM honored for its invention of the Blue Gene family of supercomputers. Adobe founders also recognized.; adobe; DDJ; ibm; Former U.S. President Bill Clinton addressed thousands of online entrepreneurs from around the world gathered for the third APEC Business Advisory Council SME Summit in Hangzhou, China.; DDJ; e-business; With free cooling for several months a year, Sweden is an ideal location for cost-efficient data centers.; data centers; DDJ; PNC Bank introduces a new mobile App for the iPhone and iPod touch that provides Virtual Wallet customers with a high-def view of their money while on the go.; DDJ; iphone; The Swedish LTE site will be part of a commercial network scheduled to go live in 2010, bringing data rates far above what is possible in today's mobile broadband networks.; DDJ; ericsson; mobile broadband; Nanotechnology advancement could lead to smaller, faster, more energy efficient computer chips.; circuit boards; DDJ; nanotech; semiconductor; Dr Dobbs talks with with Claudia Backus, Senior Director of Ecosystem Programs at Motorola, regarding the company's recently released MotoDEV Studio for their Android-powered phones.; Android; DDJ; mobile; motodev; The Extremadura Regional Government of Spain and IBM have launched an electronic prescription system in 680 pharmacies in western Spain.; DDJ; ibm; Ericsson to Acquire Majority of Nortel's North American Wireless Business; DDJ; ericsson; mobile; telecom; Nintendo's Wii Sports Resort is an immersive, expansive active-play game that includes a dozen resort-themed activities.; DDJ; nintendo; video games; OnStar can remotely send a signal to the electronic system in the subscriber's stolen vehicle and the vehicle will not be able to be re-started.; cellular; DDJ; wireless; In celebration of the historic Apollo Moon landing, Google has released Moon in Google Earth.; DDJ; google; Ericsson has been awarded contracts with the three telecom operators in China to provide fixed broadband access.; broadband; DDJ; mobile; tv; wireless; Dr. Dobb's talks with Adobe's Adam Lehman about the upcoming release of ColdFusion specifically optimized for Flash and Adobe AIR platform delivery.; adobe; ColdFusion; DDJ; eclipse; Companies team to develop computing device and chipset architectures that will combine the performance of powerful computers with high-bandwidth mobile broadband communications and ubiquitous Internet connectivity.; broadband; DDJ; Intel; mobile; nokia; Adobe Systems and HTC recently announced that the new HTC Hero will be the first Android phone to ship with support for Adobe Flash Platform technology.; adobe; Android; cell phones; DDJ; flash; mobile; mobility; 3.2 million Euros awarded across eight prize categorie recognizing world-class scientific research and artistic creation.; DDJ; A parody of Paul Simon's "50 Ways to Leave Your Lover," but for software security nerds.; DDJ; sql; Dr. Dobb's Mike Riley talks with Jim Manias of Advanced Systems Concepts.  In this conversation, Jim discusses the new ActiveBatch 7 and how it can provide significant productivity gains for application developers and business process owners alike.; ActiveBatch; DDJ; Sun cofounder Scott McNealy and Oracle CEO Larry Ellison discussed Java's role in computing. Sun has also released OpenSolaris 2009.06.; DDJ; java; opensolaris; oracle; sun; Spotlight on NATO's centre of excellence on cyber defense in Tallinn, Estonia.; cyber defense; DDJ; nework security; security; Create Data Access Layers in ASP.NET; DDJ; In this demonstration you will learn how to layout a WPF application. We will explore the major layout panels that come with WPF, contrasting them with each other and describing when to use each.; DDJ; web development; windows; wpf; The Intel Foundation has announced the top winners of the Intel International Science and Engineering Fair; DDJ; Intel; News; science; Matt Hester demonstrates Internet Explorer’s 8 new feature Selectors API for utilizing CSS selectors for quick and easy element lookups.; DDJ; IE8; microsoft; windows; The NATO Virtual Silk Highway provides affordable, high-speed Internet access via satellite to the academic communities of the Caucasus and Central Asia.; DDJ; On a Windows Mobile device, applications are typically not closed down, but they stay in the background. Maarten Struys shows you a simple way to preserve battery power inside your own applications.; DDJ; microsoft; power consumption; windows; Windows Mobile Devices; Cadillac is now offering wireless Internet access with its CTS sedan.; DDJ; wireless broadband; By default, Windows Mobile Standard (Smartphone) applications launched from Visual Studio are not accessible on the device/emulator once they are minimized. In this video, Jim Wilson demonstrates two simple techniques to solve the problem.; DDJ; microsoft; smartphone; VIsual Studio; Mike Riley talks with the brass from Everypoint, creators of the NEMO mobile application development platform.; DDJ; Developers; development environments; mobile applications; Symmetric and asymmetric encryption algorithms, the SHA256 hash encryption algorithms, and how to implement in a simple application using Microsoft's Azure Services Platform.; Azure; DDJ; encryption; microsoft; security; windows; T-Mobile has introduced the Sidekick LX, which features enhanced video capability.; DDJ; Mobile Smartphone; Bluetooth 3.0 offers speedier transmission of large amounts of video, music and photos between devices wirelessly.; bluetooth; DDJ; mobile networks; wireless broadband; Cities around the world are battling with stressed transportation networks, so IBM has announced plans for three new smart rail projects in China, Taiwan and The Netherlands.; DDJ; ibm; ILOG; CASMOBOT is a Nintendo Wii remote controlled slope lawn mower.; DDJ; Denmark; nintendo wii; research; robotics; Project ensures documents, images, video and other Internet-based data growing at over 100 terabytes per month will live on for future generations; data storage; DDJ; history; Intenet; research; Sun Microsystems; Dr. Dobb's talks with Dave McAllister, Director of Standards and Open Source for Adobe, about the Open Screen Project.; adobe; DDJ; Open Screen Project; open source; The Facebook Connect SDK provides the code to let third-party developers embed hooks into their applications so users can connect to their Facebook accounts and exchange information using iPhone apps.; apple; cocoa; DDJ; Facebook; iphone; Mars in Google Earth Updated; DDJ; google; google earth; Google mars; red planet; The Sun Cloud is built on the Sun Open Cloud Platform that leverages the best in world-class open source technologies. The Sun Open Cloud Platform brings together Java, MySQL, OpenSolaris and OpenStorage.; cloud computing; DDJ; java; open solaris; sun; DDJ; High School; Intel; science; ILOG Elixir is a suite of professional user interface controls that gives developers a rich collection of innovative and interactive data display components for Adobe Flex and Adobe Air.; adobe; air; DDJ; elixir; flash; flex; ILOG; The inaugural San Diego Science Festival being held this month is touted as one of the largest multicultural, multigenerational, multidisciplinary celebrations of science ever seen on the West Coast; DDJ; lockheed; News; science; IBM has announced Innov8 version 2, a new version of its serious game that helps students and professionals hone their business and technology skills in a compelling, familiar video game format.; DDJ; ibm; serious games; Swiss Automobile Visionary Frank M. Rinderknecht builds a concept car with adaptive energy concept and iPhone controls.; apple; Concept Car; DDJ; iphone; j; siemens; Two-Year Plan to Focus on 32 Nanometer Manufacturing Technology; 32 nanometer technology; chip; cpu; DDJ; gpu; Intel; manufacturing; Nehalem; Westmere; New version features ocean layer, historical imagery, and more.; DDJ; google; Dr. Dobb's talks with Marty Alchin, author of "Pro Django" about his book and the deep internals of the Django framework.; DDJ; Django; A new content-authoring solution for learning professionals; adobe; DDJ; toolkits; web authoring; In a Second Life setting, Danny Coward discusses Java FX with Dr. Dobb's Jon Erickson.; DDJ; java; JavaFX; sun; The Core i7 processor is the first member of a new family of Nehalem processor designs with new technologies that boost performance on demand.; chip; DDJ; Intel; processors; Dan Diephouse, creator of XFire, a high-performance open-source SOAP framework (which became the Apache CXF project), shares the five common mistakes in SOA governance and insight about the Apache CXF and Mule RESTpack development environments.; apache; Apache CXF; DDJ; mule; open source; soa; soap; Xfire; Adrian Kaehler and Gary Bradski discuss the Open Computer Vision Library (sourceforge.net/projects/opencvlibrary/) and their book "Learning OpenCV".; DDJ; Open Computer Vision Library; OpenCV; In the first part of this two-part interview, Stephen Wolfram reflects on the 20-year anniversary of Wolfram Research.; DDJ; Mathematica; Mathematics; science; In the second part of this two-part interview, Stephen Wolfram discusses his book "A New Kind of Science."; DDJ; Mathematica; Mathematics; science; Nick Hodges talks about Delphi 2009, a RAD tool for Windows, and Delphi Prism, a database engine for Windows, Mac OS X, and Linux.; DDJ; delphi; RAD; windows; Dr. Dobb's talks with Tony Lombardo, lead Technical Evangelist at Infragistics, about all new UI tools for Windows and .NET.; .net; DDJ; silverlight; ui; windows; wpf; Dr. Dobb's talks with Eric Schulz about his International Mathematica User's Conference 2008 presentation on the Mathematica Essentials Palette and the future digital educational material; DDJ; Mathematica; Mathematics; Dr. Dobb's talks with ActiveState's Trent Mick about the recently released Komodo IDE 5.0.; DDJ; ide; open source; Dr. Dobb's talks with Continuity Logic's Kris Carlson about "Why We Die: Simulation of the Evolution of Senescence" and why he programs with Mathematica's functional programming language.; DDJ; functional programming; Mathematica; simulation; Ericsson collaborates with Intel; DDJ; ericsson; Intel; Mobile technology; Dr. Dobb's talks with Schoeller Porter about the grid and cloud versions of Mathematica; clouds; DDJ; Grid; Mathematica; Dr Dobb's interviews Yehuda Katz, maintainer of the Merb project, about the advantages this highly optimized Ruby on Rails alternative offers to web application developers.; DDJ; Ruby on Rails; Dr. Dobb's talks with Thomas Roman, Professor of Mathematics at Central Connecticut State University, about "Mathematica Visualization in a Theoretical Physics Problem - Negative Energy in an Unusual Quantum State."; DDJ; Mathematica; physics; quantum; science; The Forbidden City: Beyond Space & Time is a fully immersive, three-dimensional virtual world that recreates a visceral sense of space and time.; Blade Server; China; DDJ; ibm; linux; mac; online; virtual world; windows; Dr. Dobb's interviews open source luminary Miguel de Icaza about his latest milestone of achieving Microsoft .NET 2.0 Framework compatibility with the Mono Project .; DDJ; Dr. Dobb/s interviews Paul Kimmel, author of "LINQ Unleashed for C#", about Microsoft's new query technology that lets developers poll any information from any data source regardless of location or structure. I; C#; DDJ; Dr. Dobb's; LINQ; microsoft; It takes a supercomputer to build a super car. ; DDJ; HPC; simulation; Dr. Dobb's shows how to install and execute cross-platform scripting languages on the Windows Mobile platform. In this installment, Mike Riley examines Perl for Windows Mobile devices.; DDJ; mobile devices; perl; windows; Dr. Dobb's shows how to install and execute cross-platform scripting languages on the Windows Mobile platform. In this installment, Mike Riley examines Python CE which is optimized for Windows Mobile devices.; DDJ; mobile devices; python; windows; Dr. Dobb's shows how to install and execute cross-platform scripting languages on the Windows Mobile platform. In this installment, Mike Riley examines Ruby for Windows Mobile devices.; DDJ; mobile devices; ruby; windows; Young participants at ITU TELECOM ASIA 2008 in Bangkok, Thailand received free laptops as part of ITU’s initiative to promote affordable devices to increase access to information and communication technologies.; communication; DDJ; itu; Currently technical strategist to Microsoft's Chief Software Architect, Rebecca Norlander has had a tremendous impact on Excel, Internet Explorer, Windows XP SP2, and Windows Vista Security. ; DDJ; microsoft; Contributing authors to the book "Beautiful Code" got together at Dr. Dobb's SD West Conference in March, 2008. Part 1 of 3.; DDJ; programming; software development; Contributing authors to the book "Beautiful Code" got together at Dr. Dobb's SD West Conference in March, 2008. Part 2 of 3.; DDJ; programming; software development; Contributing authors to the book "Beautiful Code" got together at Dr. Dobb's SD West Conference in March, 2008. Part 3 of 3.; DDJ; programming; software development; Anders Hejlsberg discusses C#, Turbo Pascal, and what it means to design a programming language. ; C#; DDJ; microsoft; Turbo Pascal; Solar powered laptops given to youths at ITU Asia 2008.; DDJ; News; telecommunications; IBM breakthrough stands to impact future direction of information technology.; DDJ; Mike Riley spoke to ActiveState's Jeff Hobbes about the new features in Tcl Dev Kit and Perl Dev Kit including the code coverage and hot-spot analysis tool and Mac OSX support.; DDJ; Tim O'Reilly addressed the OSCON convention in his Wednesday keynote titled "Degrees of Freedom, Open Source in the Wed 2.0 Era.; DDJ;


Enabling People and Organizations to Harness the Transformative Power of Technology