IBM Domino Designer: Tips and tricks for maximum productivity

download IBM Domino Designer: Tips and tricks for maximum productivity

If you can't read please download the document

Transcript of IBM Domino Designer: Tips and tricks for maximum productivity

Session Title

IBM Domino Designer: Tips and Tricks for Maximum Productivity

Peter JanzenIBM

In This Session ...

This session will describe the Designer and Eclipse tricks you may not have discovered that can greatly enhance your experience. Learn how to enhance Designer performance, which preferences to turn off or leave on, how to get organized with working sets and perspectives, how to use the Eclipse file system for import/export, and much much more. You'll leave with an understanding of how Domino Designer integrates into Eclipse, and how to make the partnership work best for you!

What Well Cover

Getting Oriented and Organized in IBM Domino Designer

Domino Designer and EclipseTM Under the Hood

Preferences

Wrap-up

Perspectives and Views

Built-in perspectives:IBM Domino Designer:Domino Designer

XPages

Forms/Views

Eclipse:Java

Debug

others

Views and Editors

Moving Eclipse views (panels) around

Create your own perspectives

Applications Navigator

Synch with Editor

Remove design elements you don't use

Close Application

Working sets

Eclipse navigators

Close Application: Helpful for running/debugging scripts that contain a DBOpen.

Controls Palette

For XPages onlyDrag and drop

Other

Palette settings
(behavior of drawers)

Palette profiles

Data Palette

For XPages onlyDrag and drop data binding

Select Controls dialog box

Home Page

Did You Know Tips

Snippets targeted to new and upgrading users

Links to
various
resources

Working sets

Customizable? Officially, no

Working Sets

OverviewIn Navigator

During File Open

On Home page

Applications not in a working setHelps you manage the list of applications

Create your own temp working set

Sync with window working set

Keyboard Navigation

Eclipse has a number of built-in keys to move your focus around the workbenchCtrl+F6: allows you to jump
to any Eclipse editor you select
from the resulting menu

Ctrl+F7: allows you to jump
to any Eclipse view or
editor that you select from
the resulting popup

Ctrl+Shift+E: Switch to editor

Keyboard Navigation (cont.)

Press Control-Shift-L to get the list of keyboard shortcuts Blend of Designer and Eclipse keysCtrl+N (New App), Ctrl+ F8
(Next perspective)

Caveat emptor some don't applyE.g., Left sidebar options

Others:Ctrl+F8: Next perspective

Ctrl+M: Toggles maximize/minimize
the active view or editor

Java editor: Ctrl+Shift+T/R to
navigate to other classes/anywhere

Explore and find your favorites!

Searching

Use the scope to refine your results:Workspace

Selected Elements

Enclosed projects

Working sets

Eclipse does remember your
previous searches

What Well Cover

Getting Oriented and Organized in IBM Domino Designer

Domino Designer and EclipseTM Under the Hood

Preferences

Wrap-up

Understanding the Eclipse Virtual File System

An NSF is a physical (single) file on the O/S file systemWe think of Design Elements as single files also how do we resolve this?

The Eclipse Virtual File System allows us represent data as resources in EclipseFunctionality introduced to Eclipse in 3.0, can be applied to any data, not just Notes applications

The Eclipse Virtual File System is often referred to as the EFS or VFS interchangeably

Understanding the Eclipse Virtual File System (cont.)

IBM Domino Designer implements extension points and interfaces for a file systemEach NSF/NTF is mapped to an Eclipse Project (IProject)

Each Design Element category is mapped to an Eclipse Folder (IFolder), e.g., forms

Each Design Element is mapped to an Eclipse File (IFile)

The Eclipse VFS artifacts should NOT be confused with O/S artifacts

Additionally Designer virtualizes files required by Eclipse that allow Notes applications to behave like Eclipse projects (e.g., plugin.xml, .classpath, etc.)These elements do not interfere with the application at runtime

Under the Hood

The NSF is an Eclipse
ProjectTypically named
appName.nsf (or
appName(1).nsf, etc.)

Design Element
categories are sorted
alphabetically

Under the Hood (cont.)

Local is a special folderAs the name suggests
Local to the OS!!

It is a TEMP storage
area for Domino
Designer use only

Expect anything stored
there to disappear!

You can create your
own folders tooCan be achieved via
extension point and
Domino Designer APIs

Source control in
Designer utilizes the EFS

Source Control

Domino Designer Source Control functionality uses the EFS to export the contents of an application to disk as a collection of files

Domino Designer listens for changes to either the files on disk or to the design elements and syncs as changes are made

Understanding the EFS will greatly help with source control functionality

Preferences are in place to control how often synchronization occurs (if at all) automatically

Working with Eclipse Projects

Eclipse builds all open projects in the workspaceWorkspace is an overloaded term in Domino Designer in the context of Eclipse, the workspace is where the Eclipse settings are stored and is different from the Notes Workspace

Avoid having too many, unnecessary applications opened in DesignerNew Close Application context menu item added in Social Edition

Working with Eclipse Projects (cont.)

Known issues in the area of building Java code over the networkAvoid (if possible) having Databases open in Designer which reside on a remote server if the database has a lot of Java code (i.e., dozens of Java classes)

More efficient to perform development on a local replica

Optionally turn off Build Automatically (more on that later!)

Remove multiple applications from the Navigator is a long standing requestEclipse views allow you to remove multiple projects which achieves the same goal today!!

Importing & Exporting Content

The Designer perspective has not (yet) implemented Import or Export

It has many different meanings across the different elements

If you yearn for the import/export capabilities of the old LS editor you can re-enable it

You can carefully use this function today in the other perspectives

Bring in files, lss files, etc.

Export design elements to share with others

This is how Domino Designer source control works!

Power and responsibility ...

Eclipse assumes you know what you are doing so make sure you do!

Build Automatically What Does It Do?

Eclipse has a concept of builders and validators

Contributors to Eclipse (/Designer) can contribute their own builders/validators which get invoked based on the setting of Build Automatically

As the name suggests Builders are responsible for acting on/building binaries from the code

Validators are responsible for validating the contents of source files

When build automatically is ON builders/validators are notified whenever a resource is modified

When build automatically is OFF it is the responsibility of the user to invoke a build of the project

Build Automatically What Does This Mean?

When build automatically is off design changes are not automatically updated for 8.5+ design elements:XPages

Custom Controls

Java Classes

Custom Design Elements (design elements potentially contributed by third parties)

To Build Automatically or Not?

Mainly a matter of user experienceNovice users tend to forget to manually build the application

Consider turning build automatically off if you have large applications on remote serversEclipse Java Builder is not optimized to execute over the network

To Build Automatically or Not? (cont.)

Java compile settingDo not modify the
Java->Compiler->JDK Compliance settings

Domino remains backwards compatibleJava artifacts written on 9.0 will run on
previous versions

As a result, the
compliance is set
to 1.5 automatically
by Designer on
startup

Problems View

Log output of a build is displayed in Problems viewProblems view improved in 9.0

LotusScript validator now shows correct line numbers!!

Problems View (cont.)

The view can contain Errors or WarningsErrors typically are fatal for the application at runtime (the application will not run/run properly)

Double clicking on an error or warning will bring you to the source of the issue

Problems View (cont.)

The problems view can be filteredSuggest to filter by selected project

To

Tracing History of Design Elements

Eclipse provides file change history tracking functionality

Tracks changes to each file during a session

Very useful for Java-based Design Elements (XPages, SSJS, Themes, etc.)

Great for figuring out why
something which worked five
minutes ago now does not!!

Available via Designer
Applications Navigator
(but also through regular
Eclipse Navigators)

If using source control the
complete history of the design element can be traced through the Eclipse Navigator

Tracing History of Design Elements (cont.)

Results are displayed in an Eclipse view

Double clicking on any of the results will compare the current version with the selected version

Compare and Replace

Two design elements can be compared with each other for differences Adaptation of previously seen compare with local history functionality

Replace functionality allows developers to replace design elements with older versions inline

Choosing Other Editors

Designer perspectives/Views generally ignore file association settings for editors for file extensions we have defined (xsp, component, form, etc.)General file types are associated with the correct editor (.html, .xml, .properties, etc.)

Open With
(in the other
perspectives/views)

A Hybrid Editor Environment

Designer leverages native Eclipse editors wherever possible and reasonable

More recent Designer editors are written with Eclipse technology

Notes EditorsEclipse-based Notes EditorsEclipse Editors

Forms/Pages/SubformsViews/FoldersFramesetsShared actionsShared fieldsOutlinesNavigatorsAppletsAbout/Using documentsFormula agents

XPages & Custom ControlsLotusScript agents, Script libraries & Database ScriptJava agents, Script libraries, Web Service Consumers, Web Service ProvidersServer & Client JavaScript LibrariesWiring PropertiesComposite ApplicationsComponentsApplication propertiesXSP PropertiesIconStyle sheets (.css)Files (.xml, .html, etc.)Java design elementThemesFaces-Config

What Well Cover

Getting Oriented and Organized in IBM Domino Designer

Domino Designer and EclipseTM Under the Hood

Preferences

Wrap-up

Preferences

General Designer preferencesShow InfoBox automatically or not

Working sets

Various warnings

Eclipse view behavior for traditional design elements

Preferences Eclipse

Eclipse provides a wealth of editor preferencesMost preferences apply, but there are exceptions general hierarchy

Editor preferencesLine numbers

Code folding

Syntax coloring (Java, JavaScript, and other editors)

Code templates (LotusScript, Java, CSS, HTML, XML)

LotusScript Preferences

Enable/Disable new Eclipse-based editor!

Enable/Disable automatic indentation of pasted code Automatic indentation of code has caused performance issues in the past

In 9.0 this feature can be disabled

LotusScript Preferences (cont.)

Enable/Disable recompilation, save & sign dependencies

Prompt user when saving with errors

Set time-outs for Content Assist & Hover Help

Set your preferences here

LotusScript Code & Comment Templates

Code and Comment templates allow organizations to easily implement certain coding standardsAllow users to automatically insert user defined templates on predefined artifacts/events (e.g., new Script Lib, new Sub, etc.)

E.g., all Design elements
have a copyright
comment header, etc.

Font, colors, etc.Define which fonts (sizes and colors) are to be used for various language syntax

XPages Preferences

Enable/Disable bubble help in properties panels

Enable/Disable content assist (note: ctrl+space invokes content assist in any editor)

Enable/Disable hover help in properties panelSet time out for hover help

Enable/Disable hover help in the XSP source editorSet time out
for hover help

Set recompilation
options

XPages Preferences (cont.)

Font settings are controlled by General->Appearance->Colors and Fonts

XML Editor preferences drive the XSP source editor

Useful settings:Line width (set to ~150 [chars])

Split multiple
attributes onto
separate lines

Preserve white space in CDATA

XPages Preferences (cont.)

Fonts and colors of XML/XSP code are configurable

Other Helpful Preferences

XML Snippets

Turn off spell check!

Browser definitions can be added via preferences

Sharing Preferences

Preferences can easily be shared via Import/Export

Advisable to backup preferences (using export)Open an Eclipse navigator view

Right click and choose Export.../Import...

Select General->Preferences

Export/Import all preferences

Consistent preferences
can quickly (and easily)
be shared across teams

Extremely useful in the
unfortunate situation where
it is necessary to delete the
Data/Workspace directory

JVM Performance Do This TODAY!

Domino Designer/Notes is a Java program

It requires a JRE to run

The JVM has low memory settings in order to keep the Notes footprint as small as possible

Designer requires more memory due to the large number of editors and builders it supports

Designer performance is VASTLY improved with the following settings:vmarg.Xmx=-Xmx1024m

vmarg.Xms=-Xms512m

vmarg.Xmca=-Xmca512k

jvm.properties is located at \framework\rcp\deploy

Full details: http://tinyurl.com/DesignerJVMSettings

What Well Cover

Getting Oriented and Organized in IBM Domino Designer

Domino Designer and EclipseTM Under the Hood

Preferences

Wrap-up

Where to Find More Information

www.lotus.com/ldd/ddwiki.nsfDomino Application Development wiki including product documentation

http://tinyurl.com/DesignerJVMSettingsDesigner Performance Technote

http://nathantfreeman.files.wordpress.com/2013/04/tamingdesigner.pdfMaking Domino Designer work like you want by Nathan Freeman

http://notesin9.com/Notes In 9 A lot of videos on XPages, Designer and more. Includes what's new in Designer 9.0 beta which is applicable for 9.0 gold

7 Key Points to Take Home

Use the appropriate Eclipse perspective for the development task at hand

Work with application locally especially if it has a lot of Java code

Consider turning build automatically off when applications reside on remote server

Eclipse trace history feature can help troubleshoot problems due to code changes

Tailor XPages and LotusScript editor experience through Designer preferences

Develop better and more maintainable code using code and comment templates

Improve Designer performance by applying Domino Designer JVM settings

Your Turn!

How to contact me:Pete [email protected]

Questions

2013 Wellesley Information Services. All rights reserved.

wis_logo_rgb_color.jpg

Click to edit the outline text formatSecond Outline LevelThird Outline LevelFourth Outline LevelFifth Outline LevelSixth Outline Level

2013 IBM Corporation