Bring information and collaboration into the context of your daily business processes using composite applications
They will be accepting abstracts for Lotusphere 2008 very soon. Please respond to this blog entry to get your ideas of what you want to see in the Composite Application space at this years Lotusphere. Feel free to ask for the world because you may get it!
There is a new version of the customer interests demo on IRIS sandbox. The new version runs on the beta 3 Windows and Linux, uses a new tag cloud component and is even easier to install since it uses an NSF based update site.
The following directories contain composite application data that is cached in Notes 8.0. It is possible to delete all of this data. It is re-created when the app is re-opened the next time. Deleting this data should never be necessary though. But maybe this information is helpful for some advanced developers or support people.
I've been asked recently by different customers, BPs and ISVs what the advantages of composite applications in Notes 8 are. Here is my take on it from a technical perspective.
Mix & match of components through standardized inter component communication
Most importantly composite applications provide an extended way to allow rapid application programming. Rapid application development has always been one of the main reasons why Notes/Domino has been that successful. While you can still do all the cool things that Notes has provided in the previous releases, composite applications re-emphasize this aspect again and push it to another dimension. You can now easily assemble new applications by re-using existing components in new contexts.
The components in composite applications (the rectangles in the UI) are coarse grained components with well defined interfaces. While you can even have framesets and frames communicating via profile documents and such, the key with composite applications is that they provide a standardized way to do this type of communication. This standard mechanism is what we call property broker using WSDLs under the cover.
The property broker allows also a loosely coupling of components. This is important for a mix & match of components and an easy aggregation of components into new composite applications on demand. Re-use of finer grained components has not been proven successfully in the industry except of standard libraries like Swing that have been defined by an organization with a lot of influence. I personally think that the component model in composite applications is one of the only models that allows such a re-use of UI components within a department, between departments in an enterprise, between ISVs and customers, etc.
I think that composite applications have the potential to significantly change the way customers, ISVs, system integrators and business partners make business. For example BPs could much easier re-use the same components in different applications for different customers. Some ISVs can focus on building components instead of complete solutions. Customers could have much more flexibility when choosing third parties to build their applications. Some higher skilled customers will be able to extend a CA and improve an already existing solution without having to request simple changes from ISVs. ISVs can focus on developing components and new CAs instead of having to make every change for a customer. Some customers will also feel more empowered by their ability to customize and extend CAs. Advanced LOB users can assemble and extend CAs without requiring developers to make every change and understand every detail of the solution or process.
As I wrote a clear advantage of composite applications in Notes 8 is the possibility to use reusable components in applications. This opportunity is best achieved by BPs, ISVs, etc. building and distributing such components. We're working to build a public catalog to help share these components. This catalog is expected to come fairly soon. It is up you, our developer community, to help populate this catalog and really build an ecosystem around composite applications.
Support for more component types through Eclipse
As everyone is aware of Notes 8 bases on Eclipse. This gives us many new capabilities and many new ways to do the same things differently, maybe for some people easier.
With Eclipse, SWT and JFace you have maximal flexibility in terms of developing sophisticated user interfaces. This was one of our main reasons to build the new and modern UI for the PIM applications with Eclipse. We just get a lot of cool UI libraries for free from the Eclipse community and can focus on collaborative functionality rather than infrastructure. This doesn't only save us time within development, but also allows us providing more functionality for our customers. I'd think that there are many external people that would want to use Eclipse for this purpose as well.
Maximal flexibility however never means that you get all of this for free. Even with Eclipse and all the available libraries you need to manually code a lot of this. However I think providing a more difficult way to implement certain features is better than no way to do this.
While more flexibility for UI development can also be done today in Notes 7 (e.g. by embedding objects and controls) I personally think that there are advantages of doing this with Eclipse/Java. First of all you can build re-usable components for multiple platforms without even having to recompile code. Then you have even more flexibility where to put your extensions/code. Not only forms can be used to embed objects but you have the whole rectangle in the UI. You can even contribute menu actions to wherever you want.
The other advantage of Eclipse compared to other ways to embed other component types is that there is a well established community around this. The established community allows two things. First there are people that know how to build Eclipse components. Students learn this at university, many people have come across Eclipse in previous projects etc. Even if your company doesn't have these skills yet, it is relative easy to get them and there is relative little risk that building up these skills wouldn't pay out.
By providing Eclipse as a first class citizen in the Notes client, Notes can also attract new markets and new customers that haven't been interested for different reasons in Notes yet, but now can continue to build Eclipse applications and then use the advanced collaborative functionality provided by the Notes layer on top of Eclipse.
The second advantage of the well established Eclipse community are the existing tutorials, samples, articles and re-usable applications, often even available as freeware. A perfect example is BIRT which is an open source project to do graphical reporting. It is easy to imagine that someone could take BIRT, add a Notes data adapter and then put it as component in a composite application.
Eclipse and Expeditor also allow us through the extensibility to run JSR 168 portlets locally. This doesn't mean that the whole server side logic is automagically taken offline but you can now build portlets running on server and on the client in online mode. For example you could now easily take some very popular portlets from the portal catalog and run them in Notes.
Features that couldn't be done in previous Notes releases and features that can now be done easier
I'm a big fan of Notes and had been long before we started with composite applications. I think Notes allows you to do incredible applications and there are features like the NIF facilities, the replication, security etc. I haven't seen in any other product. I also understand that our partners have done things with Notes that we in development have not even anticipated when we built Notes features.
That having said I think that there are features in Notes 8.0 and that there will be features in Notes 8.x that you couldn't do in previous Notes releases. Let me give a concrete sample. Notes 8.0 comes with a new type of API, an UI API, for the PIM applications. The PIM apps support some properties and some actions. Granted, these APIs support only minimal functionality yet, but we didn't feel comfortable putting in more functionality since we usually wait a whole release cycle before we make APIs public. But you can imagine that at some not distant point of time you can extend the PIM functionality WITHOUT design changes to the PIM templates. This is possible since you can reuse PIM components in new applications and use the property broker to interact with other components.
Also the rectangles in the UI can be easily minimized and maximized in composite applications. This is not easy to do with frames in a frameset. However this is an important UX pattern when you use multiple peripheral components on a page. You don't always want to see everything expanded.
Eclipse also allows embedding other types of components. The embedded browser is a good example. In Notes 8.0 the embedded browser is a re-usable component for composite applications allowing to set the URL to display initially via component preferences in the CAE as well as to pass in new URLs to display at runtime via property broker. Other HTML rendering engines like Gecko can also very easily be used from Eclipse components. Another example are the Personal Productivity Editors that we've planned also to provide as components at some point.
You can also pass in context to Eclipse components in composite applications allowing these components to behave slightly differently depending on this declarative configuration. This will also be possible for NSF components in Notes 8.0.1. This context is defined using the CAE when the CA is assembled instead of when components are built. This allows developers to design components which accept context and LOB users assembling composite applications can specify different parameters to increase the resuability of components.
Notes applications are typically very form based. In previous Notes releases other components had to know the field names of forms to populate some fields. With composite applications UI services (the actions of components with property broker) can be provided to encapsulate the storage layer and provide real business services like in SOA.
In Notes 8.0 you can turn on logging to get more error messages.
Java side logging can be enabled in the file Notes\framework\rcp\eclipse\plugins\com.ibm.rcp.base_188.8.131.52707010500\rcpinstall.properties. Add the module you want to log in a new line like this:
The output will go in trace-log-0.xml (and error-log-0.xml) und Notes\Data\workspace\logs.
These are the modules with composite applications code:
Notes plugin including bridge from Expeditor pb to Notes and NSF based applications
Expeditor property broker
Expeditor topology handler
Expeditor composite application infrastructure
On C side logging can be enabled via notes.ini:
The C side logs contain information about the Notes projection of the property broker and to open NSF based comp apps.
Here are some good tips how to debug NSF components in composite applications in Lotus Notes 8. The following text is from Andre Guirard.
For debugging your composite applications, the LotusScript debugger may be helpful, but there are challenges, especially when there are multiple pieces of LotusScript code running at the same time in different components, which may not always start in the same order. You only get to debug whichever one starts up first.
'Print' statements are particularly helpful because you can see the sequence that events occurred in, they don't grab focus or affect timing (much) the way a modal dialog (a.k.a. Messagebox) would, they require fewer mouse clicks than Messagebox or the debugger, and you can see the results easily, all at once.
By default, the status bar history shows the last 20 or so entries, which is not very useful for an application of any complexity. But you can increase this number to 100 in the status bar preferences dialog (File / Preferences / Status Bar Preferences from the Designer client).
This setting only affects the Designer (or Basic) client, so after you try something in your composite application, you must Alt+Tab to Designer to see the longer status history. Also, you can arrange for all status messages to be written to your local log.nsf (Miscellaneous Events view). Add the following line in your notes.ini:
You can change this setting (and others) without having to exit the Notes client, using this script. LogStatusBar works no matter which client you use.
The status bar and Print statements are pretty good for casual debugging while you're developing an application. When you roll it out, you'll want to remove the debug output, but at the same time, if something goes wrong "in the field" you want to know what was going on at the time and how you got to that point. You can add some logging to your application that execute only if an error occurs (by which I mean either a LotusScript error condition, or just something you regard as wrong, such as a variable being blank that you expected to not be blank). The dW article Debugging Domino Applications part 1 and part 2 discusses how to design your application to trap errors and get the stack trace. If you want to retrieve the stack information when there's not an error condition (e.g. when that variable is blank), use the Error statement to throw your own error. The NotesLog class can be used to record this information in the user's log.nsf or to a file, so that it's available to support and development when they go to diagnose the problem later.
You might even email the trace information to a centralized error logging application. This is the approach IBM took with crashes in the Notes client, and the resulting database of crash stacks, memory dumps, and user explanations of what they were doing has been very valuable to us in prioritizing and reproducing problems.
For more sophisticated logging, you can also use the popular OpenLog application on openntf.org. This takes a lot of this good stuff I've been talking about (and more!), incorporates it into a standard format, and gives you a script library so you don't have to write all that code yourself.[Read More]
One of our customers has implemented an interesting use case with composite applications. Unfortunately I'm not allowed to write who this customer is, but I have the ok to write about the component.
Here is a screenshot of an application using the tagging functionality. It essentially allows users to tag Notes documents. These tags are stored in another central NSF which contains the links (Notes URLs) of tagged Notes documents, the different tags, amount of times a document has been tagged and it knows by which users a document has been tagged.
The screenshot shows that the document 'Mail Replication' has been tagged with the word 'test'. The component at the bottom shows other documents that have been tagged with the same word and by the same user.
A document can be tagged with different words. You can see a list of all tags for the current document in the component in the upper right corner. This component also allows creating new tags. When you want to assign a new tag to the current document you can choose in the UI from one of the existing tags.
The blue tag cloud component displays the mostly used tags in different sizes. When you choose a tag you'll see the list of documents with that tags in the component at the bottom.
The final version of the redbook "Building Composite Applications" has now been published.
Do you have (or want) a component that performs different functions in different circumstances?
There are some features in CAE and Comp Apps to help you with this.
1) Copy components in CAE palette
Right-click on a component the palette, and choose "Copy"
Right-click somewhere else in the palette (or in a different palette) and choose "Paste".
This will create an identical copy of the component on the palette, along with any advanced settings (e.g. preferences) you've applied to the component.
2) Rename your component
Right-click on the component and choose "Rename" to give the component a new name.
At runtime this name is available via the com.ibm.rcp.title preference, so you can set the title of your component appropriately.
3) Apply different settings to the components
Use the Advanced Settings dialog to apply some new preferences to the component to differentiate it from the original.
These settings can then be read by the component at runtime. See this previous entry for more details.
Typically the majority of simple components will employ a single java feature, and the CAE will detect that required feature when the component is added to the palette from an updatesite. The sample image below shows a simple view configured with a single feature.
With more complex components that have multiple features it is a requirement to configure the component after it has been added to the CAE palette. Use the advanced component properties to list the additional dependant features using an underscore and incrementing digits postfixed to the id.feature, match.feature and version.feature property names. The sample below shows a configured two feature component.