Monday, December 8, 2014

The similarities are amazing.

I got laid off not too long ago (not bad, 4 times in almost 40 years and twice I asked to be laid off) and I started to use Salesforce to track my job search. It is a sales process after all. Then I started looking under the hood and found that Salesforce is not just a CRM.  You can build many different kinds of applications with Salesforce, just like Domino. You can use a drag and drop interface to create simple forms and views, build relationships between different document types, do field validations, and even use simple formulas to perform calculations. And there is a more powerful scripting language to add some automation or workflow. Sound familiar?

But wait, there's more. This easy to use interface means the person that knows some Excel formula's is now a 'developer'. And these newborn developers don't know what a development environment is, much less source code control, so changes are made in production with the resulting occasional loss of productivity while corrections are made.  It is so easy to create new applications that it is hard to keep track of what is being used. And have you ever seen an out of control security model where admins don't make changes for fear of breaking someone's access?

But the similarities between Salesforce and Domino do digress. Many of you are looking forward to going to Connect shortly, There you are expecting maybe 10,000 attendees, and hoping more than half are not IBMers. Well, Salesforce just had their big trade show called Dreamforce, and there were 140,000 attendees.

Another difference is if you go to your favorite job search site and look for Domino developer positions and then search for Salesforce developer positions, let me know what you find.

Monday, March 24, 2014

Source code control is like turn signals

Everyone has access to the tools, but most people use them wrong! A brief example - when people are on the on ramp and need to 'merge', they put on their turn signal. They aren't changing lanes, so what's the point?  And that is probably the last time they use their signals, including when they exit the highway. This is the most critical time to use them, to indicate to drivers behind you that you are likely to slow down in the travel lane to reach the exit ramp speed.

Anyway, source code control is misused just as frequently. We all have seen the application with design elements named 'Copy of...' or worse 'Another Copy of...'  We also have seen design elements with a date after them. This is NOT source code control. Go to you primary business application and click on the Create menu item. What do you see? Artifacts that some developer forgot to click the do not show in create menu box. How about the Actions menu item? How many actions show up that you wouldn't want a user to try? How about View, then Go To...? All of those 'extra' views get indexed, taking up resources - both CPU and disk space. Multiply that by the number of replica copies and you get the idea.

Now, knowing that I was a Technical Director at Teamstudio, you might think I would be advocating for a source code control system like Teamstudio CIAO, but you'd be wrong. That is an excellent tool but it is misused as much as turn signals! One of the things CIAO provides is design element locking. These days, that is less of an issue because of the decline in the number of teams of developers. And how does this get misused? Check out a design element and never check it in! You get no history of the changes you make along the way, so no real benefits.

Maybe you prefer an open source product like Git. That's great too, but you have to configure it and use it.

All I'm suggesting is something as simple as making a design only copy of the database before you start making changes. Now you can just make your enhancements because you now have snapshot of the design elements before you started making changes! Even better, this can be reduced to a single button that also stores the copy in a database, getting it out of the file system in the process.

If you want to know more, contact me. My email these days is jkingsley.ma at gmail.com.

Tuesday, March 4, 2014

Introductory special offer

After 22 years of Domino development, I find myself once again working for myself.  And do you know what that means?  No corporate overhead, no middlemen taking a cut for my work.  Which means I can offer lower rates than ever.  In fact, to introduce you to what I can do, for the month of March, I am offering my services for half my normal rate.

Why should you use me?  How do you know me?  Maybe you attended one of my sessions at a user group meeting, including MWLUG last year.  Maybe you were in one of my training sessions or demos during my time as a Technical Director at Teamstudio.  Maybe you have read my blog before - such as the time I hit the What's Hot corner on PlanetLotus.  Or maybe you attended one of my webinars, including the one I did with Rocky Oliver.

So if you have some enhancements or maybe bug fixes that you have been delaying because of rates, this is the time to act.  I have done work for clients in many states, and can VPN to any network.  I even had one client send me an encrypted laptop to access their network.  If you prefer to have someone on-site, I am available for travel, but that costs extra.

If you want to discuss your situation further, contact me by email - jkingsley.ma at gmail.com

Wednesday, August 28, 2013

And the correct answer is...

Last time I wrote about Designer Help.  One reader correctly pointed out that if I wasn't so lazy, I just had to add the word 'formula' to my search string.  An even better answer came from Julian Robichaux at his session at MWLug last week.  It is to set the search scope.


It is not real intuitive, but click the link, select 'Search only the following topics', click 'New', name your list, and select only the stuff you want.  I always wondered how items for Workbench and Sametime showed in my search results.

Monday, August 19, 2013

This is not a trick!

Go to Help Contents with your Social Edition designer client and enter '@Member' into the search box.  The old, familiar, formula language reference is the 15th entry on the third page!  And why did I notice this?  I use Help all the time.  I mean, does the value or stringlist come first?  Depends on the function.  And whats the difference between @IsMember and @Member?  If I had to remember all this, I might not have room to remember my wife's cell phone number, which is pretty important.

So have you noticed the reformatting of the help file?  It looks like a lot of work went into this, but I wish they spent more time improving the run time error handling engine.  I mean, really - "Object variable not set"? Can you please tell me what variable?  And they same for "Type mismatch".  Although I do this so often I tend to find this pretty quickly.  And here is where the help files could be improved - the examples are too simplified.  They use constants in a lot of places where real developers might use a variable.

And I know everyone is focusing on xPages, but I still work with a lot of clients that have traditional Notes apps, and need to have small changes or even big fixes.  So, I still use help on a regular basis so I appreciate any changes, and keep them coming.

Wednesday, April 24, 2013

I am sorry I am a user...


Because someone can get a patent for 'slide to the right' to unlock.  My Android phone used to be 'slide down' to unlock to get around this patent.  I guess too many people slide their phones in their pockets and 'butt dialed' too many people so now it is 'slide up' to unlock, meaning my phone is now in my hand.  All of this is completely arbitrary, non-intuitive, and in no way inventive or unique!  But to be safe, I have filed a patent for a motion sensitive method of unlocking a phone which involves a one finger salute.  I am going to be rich!  It is only a matter of time before you can just wave at your phone, or point at it, or whatever, to unlock it, so I am just getting ahead of the curve.

My real point?  The 'X' to close a window on Microsoft machines is on the top right, and on the top left for Apple machines.  WTF?  Did studies show too many users closed their windows when they were trying to get the Edit or File menu?  A user interface should be designed for consistency so users don't have to think about how to accomplish a task.  Is it a button?  An action menu item?  A tool bar button?  What does that icon mean anyway?  All I am saying is spend a few minutes thinking about your buttons and actions.  Does 'Close' do a save and close?  How do I get out of this document? Why is it different than all the rest?

This is one of those issues dating back to the early days of Notes.  Hitting ESC closes a window.  So does clicking the 'X' on the top.  So do I need to include an action to close a document?  Well, if you do it for one form, you have to do it for every form.  Consistency is all it is cracked up to be.

Make it easy for your users to accomplish the task your application is supposed to help them achieve, and everyone will be much happier!  It is not Notes that sucks, it is your UI!

Friday, January 25, 2013

And for those of us not going to Connect 2013...

Which pretty much means this won't apply to anyone who reads this.  In my experience, the people who need the most help don't tend to seek it out in either blog posts, PlanetLotus.org, any of the forums or at user group meetings.

In any event, I was recently asked by a client why I sent him design changes in an NSF versus an NTF.  This is a topic I dealt with rather frequently when I was a Technical Director at Teamstudio.  Many people think it has to do with design inheritance, but it doesn't.  The biggest differences are an NTF will not show up in an 'open database' dialog box, hiding it from every day users.  Also, any scheduled agents will not run.  And lastly, design elements in an NTF can not be previewed in a web browser.  Which all make an NTF a great way to manage design changes.

But from an inheritance view point, that is controlled at the database level by the fourth tab on the properties dialog, indicating either inherit from template or it is a template.  At the design element level, it is controlled by a setting in the design tab of the elements properties.

At design refresh time, either manually invoked or by the Design task, databases are refreshed at the database level by the inherit from setting, and then at the design element level.  And as was the case with my client, I was making modifications to the mail template, and wanted to be sure the process was repeatable for the next release of Domino.  So my changes where in a database that could be an NSF or NTF (but best practice says design elements should be in an NTF).  These changes were used to refresh design elements at the element level in the mail template.  This results in a cascading design refresh situation - the template gets refreshed from the custom design element database, and then the user mail files get updated by the mail template.  Note that this element level inheritance is not inherited.  So, the user mail files get ALL their design changes from the mail template, not some from the template and some from the custom design element database.

And in a final comment about design inheritance, a review of what databases are being used in your environment (a common precursor to upgrades, server consolidation, or migration from Notes), needs to include design element level inheritance, and not just database level inheritance as shown in the database Catalog.

I usually recommend a manual refresh of the template from any updates I send, and then allow the design task to refresh all the user files.  This is the cleanest way to ensure updates take place in a controlled manner.

I hope this helps.  And if you are going to Connect 2013, have a great time!

Thursday, November 15, 2012

We learn from our mistakes

But can we learn from others mistakes?  Absolutely.  Let me give you some examples.

Adobe Acrobat takes forever to load every single piece of functionality known to man, and then let's you view the one document that you wanted to see.  It takes longer for Acrobat to load than it takes me to get the information from the file I was looking for.  And apparently it is so buggy that you get an update every single day.  Now, this is all historical, and may have changed because it was these issues that led me to remove all things Adobe from my system.  Yes, I have been Adobe free since '03!

Lessons to be learned?  First, the initial response time sets the tone for your interactions with users.  Look at you applications.  Opening a document shouldn't take minutes.  Do you have a massive PostQueryOpen that initializes every possible variable?  Try initializing them just before they are used.  Same thing for your action buttons - do they do a lot of initialization before showing a dialog box?  Users don't notice or care about small delays after they answer the dialog, because the system is now doing something they asked it to do.  Just let them tell it first.

Second lesson, and I see this in Notes shops everywhere, just because you can make a minor change very rapidly doesn't mean you should.  Users don't really like constant changes.  They would much rather have a set expectation when changes are going to be made available.  Every Monday is probably a bit excessive, but you need to balance the expectations for when I can get this fixed versus the rapid application development that Notes is famous for.

Here is another set of mistakes that we all should learn from.  I have Verizon for my cell phone, internet, cable, and home phone.  Every single interaction I have with their applications is PAINFUL!  They have an app for my phone that let's me control my DVR's.  When I start this app, like Adobe, the first thing it does is load up the TV schedule.  Why on earth would I want to see the TV schedule on my phone?  I can't watch TV from there, so why would that be the first thing that they do?  What I do is click on the DVR tab.  Every time.  Is that so hard to remember?  Use a cookie, or a per user profile document.  I talked about this before - it is real easy to track what users do to identify commonly used features, and features that are not even used.  The gamification aspect comes from rewarding them for reaching milestones, like closing their 100th To Do.

Their web experience is just as painful.  After I sign into their site, they pop up a message box trying to get me to buy FIOS.  I already HAVE FIOS and you should know this because I signed in!  Don't ask your users for information you should already have.  The misery continues when I go to view my account.  The first thing I get is spinning wheel, spinning wheel, spinning wheel and I finally get entertainment news!  I pity the fool who gets his news from Verizon's web page!  They may have that set as their home page, but I only go to that site when I am forced to.

The lesson here is you need to know what your users are doing.  This is a combination of tracking their activities and plain old walking around and watch them use you application.  When you see them struggle to perform a task or even find a function, you know you have some work to do to improve that.  I watched a user do something to 10 documents, and it took forever.  I knew that the operation was only changing one field, so it shouldn't have taken that long.  When I looked at the code, I discovered several thing.  First, it was intentionally designed to only allow a maximum of 10 documents at a time.  And guess what?  This function was rarely used because it was so painful to use.  There were no consequences to not performing the function, and it was hard to use.  The other thing I found is that the action had a ComputeWithForm on a very complex form.  Come on people - only one field was changed.  We need to help our users be productive, and stop stifling them with arbitrary processes.

To finish up, I generally don't generalize.  And I know Verizon is a large company, but they seem to have a systemic lack of knowledge about what their users are doing.  I do know that we were talking to one division within Verizon to get them to implement source code control.  The developers response was it takes too many clicks!  And that would get in the way of their rapid application deployments.  Just sayin, schedule your updates.

Thursday, October 25, 2012

Big Iron and Big Pipes are here!

So let's consolidate some servers!  With the powerful servers and higher bandwidths available today, it makes sense to look at combining several servers into more central locations.  This can reduce costs for maintenance of older boxes, facility costs, and improve overall performance as less time is spent replicating databases between multiple servers.

I recently worked with a client on a consolidation project and want to share some observations.  Their strategy was to build the new servers and, before they moved users to the servers, wanted to test the performance of the central servers.  We used the Server.Load capability that comes with Domino.  This has been around for awhile (I worked with it's predecessor, NotesBench, 15 years ago).  It is an engine that has several scripts that can be used to simulate thousands of users.  It has two basic modes - initialize the environment and running the workload.  The initialization phase is key.  After all, simulating several hundred users is pretty useless.  The challenge of several thousand users is creating that many mail files and populating them with data.

Here is the critical take-away - when running the workload tests, there is a built in delay between each user session which makes sense.  Aside from me, I don't know many users that go flat out all the time.  And this delay is a random number.  The problem is during the initialization phase, you are not collecting statistics, so you don't need to 'simulate' real users, just create the mail files.  But this delay can be up to 15 minutes.  So, doing the math, creating several thousand user mail files with up to 15 minutes between each user can take days (and yes, do use multiple workstations to attack the server).  So, please, help yourself and reduce this delay.  What you need to do is take the built-in initialization script, copy to the clipboard, paste into Notepad, CHANGE THE DELAY, and save the custom script.  Here are the first few lines


* N85 Mail Initialization Workload
* Script to initialize databases for NotesBench N85Mail
* Pause a random interval (0-15 min) so multiple processes are staggered well.
pause 0-900000

Remove at least three zeros from that pause line.  You will be so much happier with the results.

A couple of other comments about server consolidation projects.  A good strategy is to bring up a brand new server.  This means that users will have to re-point their mail files to the new server.  Consider renting a tool like Marvel Client from Panagenda to make this change easier.

Secondly, why 'consolidate' a database that is not being used by a person?  The problem with the activity number in the Catalog is that it considers any activity as using the database.  This activity could be mail being deposited in a database or a scheduled agent running against the database.  Neither of these 'activities' represent a person.  So, while you are ordering the new hardware, consider an approach offered by someone like Inner Ring Solutions.  They have a tool which identify's who is using a database; meaning server, agent, or user; and how often.  So, a database that is not used by users is a candidate to be retired, not consolidated.  Likewise, a database (not mail file) used by 10 or less users could probably be replaced with some other solution, or be advertised to users as an underutilized benefit.  My experience from my days at Teamstudio is that up to 75% of databases in a long standing Notes environment can be deleted because they are not being used.  A large part of this inactivity can be easily identified by looking at you Catalog.  I have a Catalog tool that will identify such things as databases (not templates) with no documents.  Databases with 'test' in the title or file name.  Databases with a year in the title or file name (think 1998 receipts).

If you want more information on your server consolidation project, contact me.  I've been there and done that before, so I can help reduce the pain of your project.

Tuesday, October 9, 2012

Back in the saddle!

I am so happy to be back working with customers on Lotus Notes development projects!  My 5 years at Teamstudio was a terrific experience (and I would have paid them to do what I did).  But I mostly worked with other developers, and they were always afraid I was trying to sell them something.  But honestly, having worked with Notes for as long as I have, I know the short-comings and why you need tools like Teamstudio, Ytria, Panagenda, etc.  And the prior 7 years I worked for another vendor that nobody heard of which is why I stopped working there.  We sold a very targeted product and were only talking to customers to get them to buy something.

But now, I am back to doing projects that people actually want.  And people are very creative!   And having   had to deal with the state of the economy the last several years, everybody is trying to do more with less.  Everybody has that one little tweak that will solve a whole bunch of headaches.  And those are the kind of challenges I relish.  So, I am back in business.  Contact me if you want another opinion!

Thursday, August 2, 2012

It's official!

That small window of opportunity to get my services without any corporate overhead are over.  This week I started working for Greyduck Technology.  Oh, you can still get my services for that project needing extra resources, or even a second opinion/review of your applications and development environment and practices.  It is just that now a portion of my time goes to Greyduck.

I have some great projects already in the works, and am looking forward to working with a company that now has 100 years of Lotus Notes experience on board.

So, stay tuned, and say hello if you see me at your user group.

Tuesday, July 10, 2012

It takes more programming skill to...

fix someone else's application than to write one from scratch.  At the same time, looking at another developers application will expand your own skill set.  Here is what I mean.  When you stick to your own applications, you tend to stick to what you know.  Your first loop may have been using a counter and GetNthDocument.  Who knew about getfirst - getnext?  And if you looked at some of my later code, the initialize routine only had one line -

Call Main.

(while it might look efficient, it was mostly because only a new subroutine would get the code block that had all my dims in it.)

Looking at other applications will not just show you bad ways of doing things, but other ways of doing things.  When you find an application where everything is defined globally, you begin to appreciate why this is a bad idea.  Trying to understand why the previous developer did things the way they did requires a deeper understanding of coding practices than just writing something from scratch.

So, while Chief Architect may be an alluring title, don't be afraid to take on a less glamorous project involving 'continuing engineering' (my first job title out of college by the way).

And for a limited time, I am available to review your applications without any corporate overhead.  So, drop me a note if you want to take me up on this.

Tuesday, June 19, 2012

Finding unused views

I recently talked about identifying the views used by users. The bigger challenge is to find those views used programmatically. And, knowing what views are used by users doesn't really help get rid of views because you need a list of all the views in a database. This turns out to be very easy to get - all you need to do is use the NoteCollection class. Here is the relevant code to create a document for every view in a database.


Set nnc = db.CreateNoteCollection( False ) nnc.Selectviews = True Call nnc.BuildCollection If nnc.count > 0 Then noteID = nnc.GetFirstNoteId For x = 1 To nnc.Count Set doc = db.Getdocumentbyid( Noteid ) ' create doc for each element Set newDoc = thisDB.Createdocument() newDoc.Form = "Views" If doc.Hasitem("$Title" ) Then set typestring = doc.Getfirstitem("$Title" ) If InStr( typestring.text, "|" ) Then newDoc.Viewname = Left( typestring.text, InStr( typestring.text, "|" )-1 ) newDoc.Alias = Right( typestring.text, Len( typestring.text) - InStr( typestring.text, "|" ) ) Else newDoc.ViewName = typeString.Text End If End if newDoc.elementNoteID = noteID Call newdoc.Save(True, True ) noteID = nnc.Getnextnoteid( Noteid ) Next End if





This LotusScript was converted to HTML using the ls2html routine,
provided by Julian Robichaux at nsftools.com.

Once you have the list of views, you can now combine this with the list of views used or look in related databases to see who calls the view.  This last part is also very trivial if you use a tool like Teamstudio's Configurator to search all design elements for the view name and aliases.

Let me know if you are interested in this bit as well.

Wednesday, June 6, 2012

Gamification

Is simply a way to provide positive reinforcement to your users when they use your application the way you want them to.  Do you want them to click the Help button before calling you?  Do you want them to view the Open Actions view more often?  That's where gamification comes in.  The easiest way is to create a script library to handle your counting.  I also use per-user profile documents to track by user.  A simple subroutine would be like this


Sub counter( thing As String ) Dim s As New NotesSession Dim db As NotesDatabase Dim doc As NotesDocument Set db = s.CurrentDatabase Set doc = db.GetProfileDocument( "Counter", s.Username ) If Not( doc.HasItem( thing ) ) Then Call doc.Replaceitemvalue( thing, 1 ) Else Call doc.Replaceitemvalue( thing, doc.Getitemvalue( thing )( 0 ) + 1 ) End If Call doc.Save( True, True ) If ( CDbl( doc.Getitemvalue( thing )) Mod 100 ) = 0 Then MessageBox "Thanks for using " + thing + " for " + doc.GetItemValue( thing ) + " times", 48, "Congratulations" End If End Sub



This LotusScript was converted to HTML using the ls2html routine,
provided by Julian Robichaux at nsftools.com.

Then, in the Click event or PostOpen event for the view (or form or whatever), simply use the script library and add a call to this routine, passing the name of the function (thing) that you want to track.  You can get real creative with this, extending the number of times before a second pop up or whatever.  You can also add in time periods - say for the last month.  It is very low overhead (compared to all the other extra code you might have inherited) and the profile documents are very efficient.

In a related manner, you can use this technique to find out what views users are using.  Simply pass in a view name and use a global profile document for all users.  This is a very powerful way to identify views that users aren't using anymore as candidates for deletion.  This works for user views.  Next post I will describe a technique to use for all those hidden views.

Sadly, this code needs to be added to every view, but I think the results are well worth the time.  I did this for an app with over 200 user views and was well on the way to removing a lot of them.  Maybe someone else has a technique for injecting this code in every view using DXML?



Tuesday, May 29, 2012

You're paying how much for that server?

Like your cable bill, the internal cost of your servers tends to get bloated over time.  When was the last time you checked your bill?  I was working with one customer whose charges for servers was over $600 K.  Upon looking at the bill, they were paying for servers that were not Domino servers, and paying for servers that didn't exist anymore.

That is a start, but what is the next step?  A good way to consolidate servers is too look at the databases that are being used.  And the key thing is to look at databases not being used by people.  The unfortunate part of the activity reported by the Catalog is it lumps all activity together.  So, you can have a mail file that shows 'activity', but it is simply the router dumping spam in that mail file.  Likewise, you can have an agent running in a database that users don't access.  Thus, activity, but no users.  The good news is that you can use the Activity Logging feature of Domino to generate useful information.  The information provided by Domino is not real useful by itself, but I have a tool that can consolidate the information and give you the information you need to identify databases not being used by people.  Let me know if you want more information.

With this list in hand, you can start to identify servers that can be eliminated by consolidating the databases on fewer servers.  And when you start to consolidate servers, you should think about a tool like Panagenda's Marvel Client that can update all your users desktops to point to the changed server for the databases.


Thursday, May 17, 2012

Coding tip for those copy and pasted fields

You know how the first paste gets you the same field name with an underscore and number added to it?  I have seen some really ugly code when someone wants to programmatically iterate over all the fields.  Things like checking a counter, or one time processing for the first field and then a loop for the rest of the fields.  All of this can be greatly simplified if you just go back to the first field and add an underscore and zero to the name.

So

Product
Product_1
Product_2

becomes

Product_0
Product_1
Product_2

etc.  Now you just loop through all fields starting with zero.  And if you come across this in an existing application, use a tool like scanEZ from Ytria to change all the existing douments.  It is well worth the time for this simple fix.


Friday, May 11, 2012

Oh the things I've seen

I was doing a web training session for a customer recently.  Since I know the user interface for the tool, I let the customer do the driving because it helps them become familiar with the interface, and the other attendees try to find the correct button before the person doing the work.  All in all this has worked real well for me to keep web attendees involved in the training.  So, the first step is to open one of their databases in designer and there it was.









and so on, perhaps twenty 'different' forms altogether.  This is a form of version management and way too common in Notes shops.  When you see this in forms, you know it happens in views where it is a really bad idea.  With forms, they don't take much space, but every view has an index that must be maintained.  It also means you might have things on Create menus or Action menus that you didn't anticipate.

So what do I mean by version management?  It is a way to track the changes in your design elements.  And it is a very good idea to track changes in your designs for many reasons.  Version management is one component of Source Code Control.  Ah, yes.  So that is why you need source code control.  People talk about it,  people tell you how to set up Git or Mercurial, but they don't tell you why you need source code control.

One of the other things you typically get with source code control is a tool to tell you what has changed.  Without printing a Design Synopsis for each of the forms.

So look for these features in your source code control system - it will really improve you development environment.

But let's go further.  The difference between these forms was several labels were changed.   This is another classic example of design meets data.  The data has now become part of the form.  This is bad because whenever the data changes, a developer is required to make changes to the database.  The whole database should be changed so that a new document was created, and the changed information entered on the document.  Use picklist or comboboxes to control the selections if you need to, but make it document level updates.  Now you are simply managing documents, not design changes.

I hope this was useful.

Welcome to my new blog

You may have seen some of my other posts under the Teamstudio blog.  Now that I don't work there, and have some time on my hands, there is still much to be added to the conversation.  And since I don't work for anyone, I don't need any disclaimers because the opinions expressed in this blog are my own.

So, what can you expect?  There are some tips on improving your development that I hadn't had a chance to put down on blog before.  I also will be looking into what are the pitfalls and resources for converting an R3 era application to an Xpage based web application.

So, come back often and add your thoughts.