SlideShare une entreprise Scribd logo
1  sur  14
XPages Developer
Be more efficient and write better code
Jakob Majkilde
 Education: Data Engineer
 Lotus Notes Developer since 1992 (release 2.1)
 Certified administrator and instructor (early releases) and 8.5 Developer
 Certified Scrum Master, Certified Java Developer
 Founder of notesnet.dk
 Blogs
 XPages.dk
 Lotusscript.dk
 Majkilde.com
 Book reader, because programming is a lot more than syntax …
 Refactoring, Domain Driven Design, Clean Code, The Art of Unit Testing, Extreme Programming, Design
Patterns, Working with Legacy Code, Psychology of Computer Programming, The Pragmatic Programmer,
The Mythical Man Month, Effective Java, Mastering XPages, Portable command Guide, XPages Ext Lib,
and more …
Basic setup
 As a developer you need to be ‘in flow’. An interruption and you will have to start all over
 Use the fastest PC possible – a SSD disk is required
 Work in a silent office (no phones). Disable email and skype popups
 Max. 5 seconds from code to test = instant deployment
 Build and run
 Not: build, replicate, refresh design, sign …
 You need at least Notes 8.5.3 to run XPages (but 9.0.1 is a lot better)
 Do yourself a favor: use 2 (or 3) monitors
 No matter what the admin says: You do need access and permission to install your own tools and
software on your PC
 The Programmer’s Bill of Rights
Learn the DDE
 Tweak it: http://xpages.dk/?p=1075
 Memory settings in lotusnotesframeworkrcpdeployjvm.properties
 vmarg.Xmx=-Xmx1024m
 vmarg.Xms=-Xms512m
 Use shortcuts
 Open Type: Ctrl+Shift+T
 Open Resource: Ctrl+Shift+R
 Open Declaration: F3 (or Ctrl+Click)
 Last Edit Location: Ctrl+Q
 Rename: Shift+Alt+R
 And of course:
 Ctrl+D, Ctrl+M, Ctrl+F8, Ctrl+Shift+7, …
 Use code templates!
Use a local server
 Local server
 Build times will be too slow on a central Domino server (Notes uses a lot of network bandwidth)
 XPages only works for one developer at a time
 If you have a compiler error – then nobody else can build
 SessionAsSigner requires one signer only
 Only one debugger session at a time
 You need access to the log files
 You must be able to restart the http task at will
 You need access (java.policy, ext folder, etc)
 Don’t ever use a production server
 Disable all tasks but HTTP
 Update,Replica,Router,AMgr,AdminP,CalConn,Sched,RnRMgr,Catalog,Design,UpdAll,Statlog
 Also recommended by Paul Withers and Nathan Freeman
 The blagger’s guide to XPages Domino Administraion
Source control is a must
 If you are the only developer – then you could just replicate, but
 Source control gives you
 Full tracking and version control
 When your boss asks: when, why, who made the change? You have the answer!
 Shared code (across domains) / several developers
 Branching
 Make a hotfix to the current version and work on the new version on the same time
 Backup
 Delete or refactor code. No problem – you can always go back
 With two developers, both having there own local server
 How do you think Notes handles replication conflicts?
 Answer: newest change will win – the older is lost.
 Solution: Source Control (e.g. git)
Source control
 We use git, SourceTree and Bitbucket
 It’s all free, but other options are available too
 But, keep making manual backups of your files in the beginning – there is a learning curve!
 Tips
 Use a .gitignore file
 Handle line breaks with ‘Autocrlf = true’ – we had problems in a mixed Windows/Mac environment
 See David Leedys video, Per Henrik Laustens presentation or
my blog entry: http://xpages.dk/?p=690. Best practice here (pending)
Source Control Settings
 Preferences, General, Workspace:
 Refresh Automatically: Yes
 Build Automatically: Yes
 Auto build no longer changes the signatures
 Encoding: Default (Cp1252)
 Because that’s what others do
 Preferences, Domino Designer, Source Control
 Automatic Import/Export: No
 Auto build is required
 Use Binary DXL: Yes
 important that everybody does the same
 Notice:
 The auto refresh doesn’t work on network drives. Do a manual refresh (F9) from Package Explorer
Think ‘Auto Refresh’ is required when using ‘Auto
import/export’, otherwise strange things might
happen if the ODP is not in sync with the disk.
Yes to ‘Auto refresh’ – but not with the ‘Auto
import/export’ as this will start an indefinite
refresh/rebuild loop
Source Control Tips
 On-Disc-Project
 Prefix the project name with ODP or GIT
 Makes it easier to distinguish them from your nsf files
 Make a folder for the project
 And one (or more) sub folders for the nsf file(s)
 Use Git Flow
 http://nvie.com/posts/a-successful-git-branching-model/
 New project
 Enable Git flow
 Make a initial commit
 Then start coding
Unit testing
 In the book “Working Effectively with legacy code”, Michael Feathers wrote:
 “Legacy code is simply code without tests”
 Pros
 Better Design / better structure
 You can change your code without breaking it (refactoring)
 10 more reasons here
 Bottom line: better code with fewer bugs in less time !
 Links
 Unit testing in XPages with JUnit: http://xpages.dk/?p=1162
 The Art of Unit Testning
 Unit testning: Why bother?
Reuse
 Lots of great open source code on the internet
 OpenNTF.org
 XSnippets
 XPages Designer Import Tool: http://xpages.dk/?p=1098
 ExtLib
 Domino API
 Apache.org
 The FREE Java toolbox you didn’t know you had
 File handling, String handling, Validators, Office Integration (POI), PDF generation (FOP)
 Beware of the security settings: http://xpages.dk/?p=1373
 Code everything in Java using Design Patterns and MVC (more on frostillic and Pipalia)
Tools from OpenNTF
 Debug
 Debug Toolbar
 Log File Reader 2.0
 Log
 XPages OpenLog Logger
 Profiling
 XPages toolbox
 XPages Masterclass (video series)
Keypoints
 Local development server
 Source Control
 Unit Testning
 OpenNTF & Apache
Need help?
 Contact the ‘Gang of four’
 Jakob Majkilde: majkilde.dk
 Per Henrik Lausten: phl-consult.dk
 John Dalsgaard: dalsgaard-data.dk
 John Foldager: izone.dk

Contenu connexe

Tendances

Alternatives to Proprietary Software
Alternatives to Proprietary SoftwareAlternatives to Proprietary Software
Alternatives to Proprietary Softwaretechlug
 
Chef Conf 2015: Package Management & Chef
Chef Conf 2015: Package Management & ChefChef Conf 2015: Package Management & Chef
Chef Conf 2015: Package Management & Chefice799
 
Intro To Linux
Intro To LinuxIntro To Linux
Intro To Linuxtechlug
 
How to write a Dockerfile
How to write a DockerfileHow to write a Dockerfile
How to write a DockerfileKnoldus Inc.
 
Crafting interactive troubleshooting guides and team documentation for your K...
Crafting interactive troubleshooting guides and team documentation for your K...Crafting interactive troubleshooting guides and team documentation for your K...
Crafting interactive troubleshooting guides and team documentation for your K...Manning Publications
 
First adventure within a shell - Andrea Telatin at Quadram Institute
First adventure within a shell - Andrea Telatin at Quadram InstituteFirst adventure within a shell - Andrea Telatin at Quadram Institute
First adventure within a shell - Andrea Telatin at Quadram InstituteAndrea Telatin
 
The Professional Programmer
The Professional ProgrammerThe Professional Programmer
The Professional ProgrammerDave Cross
 
DevOps Fest 2020. immutable infrastructure as code. True story.
DevOps Fest 2020. immutable infrastructure as code. True story.DevOps Fest 2020. immutable infrastructure as code. True story.
DevOps Fest 2020. immutable infrastructure as code. True story.Vlad Fedosov
 
Software Testing
Software TestingSoftware Testing
Software TestingAndrew Wang
 
Easy Cross-Platform PowerShell Automation with Puppet Bolt
Easy Cross-Platform PowerShell Automation with Puppet BoltEasy Cross-Platform PowerShell Automation with Puppet Bolt
Easy Cross-Platform PowerShell Automation with Puppet BoltPuppet
 
Jenkins and Docker for native Linux packages
Jenkins and Docker for native Linux packagesJenkins and Docker for native Linux packages
Jenkins and Docker for native Linux packagesDaniel Paulus
 
Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12
Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12
Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12Puppet
 
Try harder or go home
Try harder or go homeTry harder or go home
Try harder or go homejaredhaight
 
DevOps Automation with Puppet Bolt & Puppet Enterprise
DevOps Automation with Puppet Bolt & Puppet EnterpriseDevOps Automation with Puppet Bolt & Puppet Enterprise
DevOps Automation with Puppet Bolt & Puppet EnterpriseEficode
 
Virtual Puppet Ecosystem Workshop - March 18,2020
Virtual Puppet Ecosystem Workshop - March 18,2020Virtual Puppet Ecosystem Workshop - March 18,2020
Virtual Puppet Ecosystem Workshop - March 18,2020Puppet
 

Tendances (20)

Is Python still production ready ? Ludovic Gasc
Is Python still production ready ? Ludovic GascIs Python still production ready ? Ludovic Gasc
Is Python still production ready ? Ludovic Gasc
 
Test driving QML
Test driving QMLTest driving QML
Test driving QML
 
Alternatives to Proprietary Software
Alternatives to Proprietary SoftwareAlternatives to Proprietary Software
Alternatives to Proprietary Software
 
Chef Conf 2015: Package Management & Chef
Chef Conf 2015: Package Management & ChefChef Conf 2015: Package Management & Chef
Chef Conf 2015: Package Management & Chef
 
Automate Yo' Self
Automate Yo' SelfAutomate Yo' Self
Automate Yo' Self
 
Intro To Linux
Intro To LinuxIntro To Linux
Intro To Linux
 
How to write a Dockerfile
How to write a DockerfileHow to write a Dockerfile
How to write a Dockerfile
 
Crafting interactive troubleshooting guides and team documentation for your K...
Crafting interactive troubleshooting guides and team documentation for your K...Crafting interactive troubleshooting guides and team documentation for your K...
Crafting interactive troubleshooting guides and team documentation for your K...
 
First adventure within a shell - Andrea Telatin at Quadram Institute
First adventure within a shell - Andrea Telatin at Quadram InstituteFirst adventure within a shell - Andrea Telatin at Quadram Institute
First adventure within a shell - Andrea Telatin at Quadram Institute
 
The Professional Programmer
The Professional ProgrammerThe Professional Programmer
The Professional Programmer
 
DevOps Fest 2020. immutable infrastructure as code. True story.
DevOps Fest 2020. immutable infrastructure as code. True story.DevOps Fest 2020. immutable infrastructure as code. True story.
DevOps Fest 2020. immutable infrastructure as code. True story.
 
Test driving-qml
Test driving-qmlTest driving-qml
Test driving-qml
 
From VB Script to PowerShell
From VB Script to PowerShellFrom VB Script to PowerShell
From VB Script to PowerShell
 
Software Testing
Software TestingSoftware Testing
Software Testing
 
Easy Cross-Platform PowerShell Automation with Puppet Bolt
Easy Cross-Platform PowerShell Automation with Puppet BoltEasy Cross-Platform PowerShell Automation with Puppet Bolt
Easy Cross-Platform PowerShell Automation with Puppet Bolt
 
Jenkins and Docker for native Linux packages
Jenkins and Docker for native Linux packagesJenkins and Docker for native Linux packages
Jenkins and Docker for native Linux packages
 
Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12
Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12
Puppet@Citygrid - Julien Rottenberg - PuppetCamp LA '12
 
Try harder or go home
Try harder or go homeTry harder or go home
Try harder or go home
 
DevOps Automation with Puppet Bolt & Puppet Enterprise
DevOps Automation with Puppet Bolt & Puppet EnterpriseDevOps Automation with Puppet Bolt & Puppet Enterprise
DevOps Automation with Puppet Bolt & Puppet Enterprise
 
Virtual Puppet Ecosystem Workshop - March 18,2020
Virtual Puppet Ecosystem Workshop - March 18,2020Virtual Puppet Ecosystem Workshop - March 18,2020
Virtual Puppet Ecosystem Workshop - March 18,2020
 

Similaire à X page developer

Some wonderful Linux softwares for daily use
Some wonderful Linux softwares for daily useSome wonderful Linux softwares for daily use
Some wonderful Linux softwares for daily usearun.arwachin
 
Bp106 Worst Practices Final
Bp106   Worst Practices FinalBp106   Worst Practices Final
Bp106 Worst Practices FinalBill Buchan
 
Novice Programmers Workshop
Novice Programmers WorkshopNovice Programmers Workshop
Novice Programmers WorkshopAlec Clews
 
Interactive Development Environments
Interactive Development EnvironmentsInteractive Development Environments
Interactive Development EnvironmentsPhilip Johnson
 
The "Holy Grail" of Dev/Ops
The "Holy Grail" of Dev/OpsThe "Holy Grail" of Dev/Ops
The "Holy Grail" of Dev/OpsErik Osterman
 
Jenkins talk at Silicon valley DevOps meetup
Jenkins talk at Silicon valley DevOps meetupJenkins talk at Silicon valley DevOps meetup
Jenkins talk at Silicon valley DevOps meetupCloudBees
 
Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)
Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)
Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)Per Henrik Lausten
 
[Mas 500] Software Development Strategies
[Mas 500] Software Development Strategies[Mas 500] Software Development Strategies
[Mas 500] Software Development Strategiesrahulbot
 
Continuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon OttoContinuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon OttoPeter Bittner
 
Introducing Yeoman 1.0 beta
Introducing Yeoman 1.0 betaIntroducing Yeoman 1.0 beta
Introducing Yeoman 1.0 betadigitalzombie
 
TDD for joomla extensions
TDD for joomla extensionsTDD for joomla extensions
TDD for joomla extensionsRoberto Segura
 
Getting Started with the OpenNTF Domino API
Getting Started with the OpenNTF Domino APIGetting Started with the OpenNTF Domino API
Getting Started with the OpenNTF Domino APITeamstudio
 
Blugsphere2011 dev
Blugsphere2011 devBlugsphere2011 dev
Blugsphere2011 devAusLUG
 
The Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingThe Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingJuan J. Merelo
 
My "Perfect" Toolchain Setup for Grails Projects
My "Perfect" Toolchain Setup for Grails ProjectsMy "Perfect" Toolchain Setup for Grails Projects
My "Perfect" Toolchain Setup for Grails ProjectsGR8Conf
 
Makefile
MakefileMakefile
MakefileIonela
 
Reproducibility in artificial intelligence
Reproducibility in artificial intelligenceReproducibility in artificial intelligence
Reproducibility in artificial intelligenceCarlos Toxtli
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.Richard Taylor
 

Similaire à X page developer (20)

How do we do it
How do we do itHow do we do it
How do we do it
 
Some wonderful Linux softwares for daily use
Some wonderful Linux softwares for daily useSome wonderful Linux softwares for daily use
Some wonderful Linux softwares for daily use
 
Lug
LugLug
Lug
 
Bp106 Worst Practices Final
Bp106   Worst Practices FinalBp106   Worst Practices Final
Bp106 Worst Practices Final
 
Novice Programmers Workshop
Novice Programmers WorkshopNovice Programmers Workshop
Novice Programmers Workshop
 
Interactive Development Environments
Interactive Development EnvironmentsInteractive Development Environments
Interactive Development Environments
 
The "Holy Grail" of Dev/Ops
The "Holy Grail" of Dev/OpsThe "Holy Grail" of Dev/Ops
The "Holy Grail" of Dev/Ops
 
Jenkins talk at Silicon valley DevOps meetup
Jenkins talk at Silicon valley DevOps meetupJenkins talk at Silicon valley DevOps meetup
Jenkins talk at Silicon valley DevOps meetup
 
Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)
Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)
Source Control with Domino Designer 8.5.3 and Git (DanNotes, November 28, 2012)
 
[Mas 500] Software Development Strategies
[Mas 500] Software Development Strategies[Mas 500] Software Development Strategies
[Mas 500] Software Development Strategies
 
Continuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon OttoContinuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon Otto
 
Introducing Yeoman 1.0 beta
Introducing Yeoman 1.0 betaIntroducing Yeoman 1.0 beta
Introducing Yeoman 1.0 beta
 
TDD for joomla extensions
TDD for joomla extensionsTDD for joomla extensions
TDD for joomla extensions
 
Getting Started with the OpenNTF Domino API
Getting Started with the OpenNTF Domino APIGetting Started with the OpenNTF Domino API
Getting Started with the OpenNTF Domino API
 
Blugsphere2011 dev
Blugsphere2011 devBlugsphere2011 dev
Blugsphere2011 dev
 
The Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms ProgrammingThe Art of Evolutionary Algorithms Programming
The Art of Evolutionary Algorithms Programming
 
My "Perfect" Toolchain Setup for Grails Projects
My "Perfect" Toolchain Setup for Grails ProjectsMy "Perfect" Toolchain Setup for Grails Projects
My "Perfect" Toolchain Setup for Grails Projects
 
Makefile
MakefileMakefile
Makefile
 
Reproducibility in artificial intelligence
Reproducibility in artificial intelligenceReproducibility in artificial intelligence
Reproducibility in artificial intelligence
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.
 

Dernier

DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfOverkill Security
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdfSandro Moreira
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfOrbitshub
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKJago de Vreede
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistandanishmna97
 

Dernier (20)

DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 

X page developer

  • 1. XPages Developer Be more efficient and write better code
  • 2. Jakob Majkilde  Education: Data Engineer  Lotus Notes Developer since 1992 (release 2.1)  Certified administrator and instructor (early releases) and 8.5 Developer  Certified Scrum Master, Certified Java Developer  Founder of notesnet.dk  Blogs  XPages.dk  Lotusscript.dk  Majkilde.com  Book reader, because programming is a lot more than syntax …  Refactoring, Domain Driven Design, Clean Code, The Art of Unit Testing, Extreme Programming, Design Patterns, Working with Legacy Code, Psychology of Computer Programming, The Pragmatic Programmer, The Mythical Man Month, Effective Java, Mastering XPages, Portable command Guide, XPages Ext Lib, and more …
  • 3. Basic setup  As a developer you need to be ‘in flow’. An interruption and you will have to start all over  Use the fastest PC possible – a SSD disk is required  Work in a silent office (no phones). Disable email and skype popups  Max. 5 seconds from code to test = instant deployment  Build and run  Not: build, replicate, refresh design, sign …  You need at least Notes 8.5.3 to run XPages (but 9.0.1 is a lot better)  Do yourself a favor: use 2 (or 3) monitors  No matter what the admin says: You do need access and permission to install your own tools and software on your PC  The Programmer’s Bill of Rights
  • 4. Learn the DDE  Tweak it: http://xpages.dk/?p=1075  Memory settings in lotusnotesframeworkrcpdeployjvm.properties  vmarg.Xmx=-Xmx1024m  vmarg.Xms=-Xms512m  Use shortcuts  Open Type: Ctrl+Shift+T  Open Resource: Ctrl+Shift+R  Open Declaration: F3 (or Ctrl+Click)  Last Edit Location: Ctrl+Q  Rename: Shift+Alt+R  And of course:  Ctrl+D, Ctrl+M, Ctrl+F8, Ctrl+Shift+7, …  Use code templates!
  • 5. Use a local server  Local server  Build times will be too slow on a central Domino server (Notes uses a lot of network bandwidth)  XPages only works for one developer at a time  If you have a compiler error – then nobody else can build  SessionAsSigner requires one signer only  Only one debugger session at a time  You need access to the log files  You must be able to restart the http task at will  You need access (java.policy, ext folder, etc)  Don’t ever use a production server  Disable all tasks but HTTP  Update,Replica,Router,AMgr,AdminP,CalConn,Sched,RnRMgr,Catalog,Design,UpdAll,Statlog  Also recommended by Paul Withers and Nathan Freeman  The blagger’s guide to XPages Domino Administraion
  • 6. Source control is a must  If you are the only developer – then you could just replicate, but  Source control gives you  Full tracking and version control  When your boss asks: when, why, who made the change? You have the answer!  Shared code (across domains) / several developers  Branching  Make a hotfix to the current version and work on the new version on the same time  Backup  Delete or refactor code. No problem – you can always go back  With two developers, both having there own local server  How do you think Notes handles replication conflicts?  Answer: newest change will win – the older is lost.  Solution: Source Control (e.g. git)
  • 7. Source control  We use git, SourceTree and Bitbucket  It’s all free, but other options are available too  But, keep making manual backups of your files in the beginning – there is a learning curve!  Tips  Use a .gitignore file  Handle line breaks with ‘Autocrlf = true’ – we had problems in a mixed Windows/Mac environment  See David Leedys video, Per Henrik Laustens presentation or my blog entry: http://xpages.dk/?p=690. Best practice here (pending)
  • 8. Source Control Settings  Preferences, General, Workspace:  Refresh Automatically: Yes  Build Automatically: Yes  Auto build no longer changes the signatures  Encoding: Default (Cp1252)  Because that’s what others do  Preferences, Domino Designer, Source Control  Automatic Import/Export: No  Auto build is required  Use Binary DXL: Yes  important that everybody does the same  Notice:  The auto refresh doesn’t work on network drives. Do a manual refresh (F9) from Package Explorer Think ‘Auto Refresh’ is required when using ‘Auto import/export’, otherwise strange things might happen if the ODP is not in sync with the disk. Yes to ‘Auto refresh’ – but not with the ‘Auto import/export’ as this will start an indefinite refresh/rebuild loop
  • 9. Source Control Tips  On-Disc-Project  Prefix the project name with ODP or GIT  Makes it easier to distinguish them from your nsf files  Make a folder for the project  And one (or more) sub folders for the nsf file(s)  Use Git Flow  http://nvie.com/posts/a-successful-git-branching-model/  New project  Enable Git flow  Make a initial commit  Then start coding
  • 10. Unit testing  In the book “Working Effectively with legacy code”, Michael Feathers wrote:  “Legacy code is simply code without tests”  Pros  Better Design / better structure  You can change your code without breaking it (refactoring)  10 more reasons here  Bottom line: better code with fewer bugs in less time !  Links  Unit testing in XPages with JUnit: http://xpages.dk/?p=1162  The Art of Unit Testning  Unit testning: Why bother?
  • 11. Reuse  Lots of great open source code on the internet  OpenNTF.org  XSnippets  XPages Designer Import Tool: http://xpages.dk/?p=1098  ExtLib  Domino API  Apache.org  The FREE Java toolbox you didn’t know you had  File handling, String handling, Validators, Office Integration (POI), PDF generation (FOP)  Beware of the security settings: http://xpages.dk/?p=1373  Code everything in Java using Design Patterns and MVC (more on frostillic and Pipalia)
  • 12. Tools from OpenNTF  Debug  Debug Toolbar  Log File Reader 2.0  Log  XPages OpenLog Logger  Profiling  XPages toolbox  XPages Masterclass (video series)
  • 13. Keypoints  Local development server  Source Control  Unit Testning  OpenNTF & Apache
  • 14. Need help?  Contact the ‘Gang of four’  Jakob Majkilde: majkilde.dk  Per Henrik Lausten: phl-consult.dk  John Dalsgaard: dalsgaard-data.dk  John Foldager: izone.dk