Jul
2
Here is my tentative syllabus for CSC-315, Fall 2014. The text book has not yet been defined, but this will give you a sense of the material we will cover.
IMPORTANT NOTE: for this class, you will do your programming using Visual Basic in the Visual Studio.NET 2012 IDE. This is a Windows-based development environment. I have seen students run Visual Studio on their Mac computers atop a Windows emulator, but it is incumbent on you to get it to work. Alternately, the classroom should have VS 2012 installed on every computer.
Jul
1
After a fair amount of research, experimentation, and poking around, I have finally found a way to return a Domino object (such as a NotesDocument, NotesDocumentCollection, or NotesDatabase) via a Web Service.
Now that I figured it out, it struck me that it’s not something that I’m likely to use because the DXL (Domino XML Language) markup is more complicated than I need. The only scenario I can imagine at this point is if you have a remote Domino server needing a Domino object that is accessible only via a Web Service.
Anyway, it’s worth documenting the process here so I can revisit it later.
For the purpose of this illustration, my code will open the Domino Directory (formerly, the “NAB”) and return the first document found in the People view. It includes some basic error trapping.
Here’s the code:
Public Class co_NotesDocument ' name of the "Port Type Class" ' note that %INCLUDE "lsxsd.lss" is defined in Options ' recommended Web Services tool: SoapUI from soapui.org Public Function getNotesDoc( aFault As WS_FAULT ) As String On Error Goto errHandler ' define basic Domino objects; note the "New" for session Dim s As New NotesSession Dim dbNAB As NotesDatabase Dim viewNAB As NotesView Dim doc As NotesDocument ' special object for exporting the Domino object ' as a DXL thingie Dim exporter As NotesDXLExporter ' instantiate Domino objects for the Notes Address Set dbNAB = New NotesDatabase( "", "names.nsf" ) Set viewNAB = dbNAB.GetView( "People" ) Set doc = viewNAB.GetFirstDocument() ' Define exporter object for current document ' alternately you can define the input document with ' Call exporter.SetInput( doc ) Set exporter = s.Createdxlexporter( doc ) ' return the string of text that is the DXL by assigning ' the Export() method's output the function's name getNotesDoc = exporter.Export( Doc ) Goto Done errHandler: ' If you are using OpenLog.NSF (highly recommended), log ' the error information with LogErrorEx(). This is for ' internal use only (by the Domino developer) ' Call LogErrorEx( "Error " & Err & " in line " & Erl _ ' & ": " & Error$, "ERROR", doc ) ' define the return properties for the fault object ' this is deliberately generic for external users of ' the web service so it reveals less information about ' your infrastructure ' assign actor an arbitrary name; maybe substitute calling user Call aFault.setFaultActor( "CLU Web Service" ) Call aFault.setFaultCode( 1200 ) ' arbitrary fault code ' arbitrary and generic error message returned in the web service Call aFault.setFaultString( "Sorry, this program encountered an " _ & "unexpected error. Ask your app developer to check the logs." ) ' must do this or the fault is NOT returned Call aFault.setFault( True ) Resume Done Done: End Function End Class ' ===================================================================================
Keywords: Returning a NotesDocument from a Web Service, IBM Notes, Lotus Notes, IBM Lotus Notes, IBM Notes Web Services, How to return a Domino object via web service
Jun
22
Yes, I’m late to the party, however…..
I’m finally beginning to create Domino Web Service providers. (If you’re not family with the IBM Lotus Notes/Domino environment, you need read no further.)
I have located several good reference pages by Julian Rubichaux, but still felt like there was some information missing that I couldn’t seem to locate, so I began a series of experiments.
As a result, I’ve begun compiling a summary of thoughts and standards for my environment, some of which I’ll mention here.
Don’t put any code in your web service. Instead, have your web service class inherit from a class defined in a script library. This class in turn inherits many standard elements from a base class in another script library. While it means you have to go through a couple of extra steps to refresh the service, it means you are able to employ code reuse on a massive scale. It also means you get better “Intellisense” capability (or whatever IBM calls it).
Define standard classes for your common return values, especially arrays, lists, date/time things, and NotesDocuments, and include them in the base class mentioned a moment ago.
Develop and use a standard error handling approach for all errors. In my case, I leverage Julian’s OpenLog.NSF tool for capturing errors internally, but return a generic error to the web service so as to hide any details about our underlying data structures. I have augmented Julian’s code so that it generates a “cascading log” entry, similar to a stack trace, that shows the call history of the problem area. This helps me debug the problem in my code.
Give serious thought to security. I’m still trying to figure out how to pass Domino credentials into a web service, but I’ve come up with a fairly robust work-around in the meantime. Perhaps I’ll describe it another time, but since it relates to security, maybe not right away!
There’s a lot more that I still need to explore and develop. I’ll update this entry as time allows.
Note: my environment uses Domino version 8.5.3 but I think these guidelines are generic enough that you can use them from version 7.0.1 on.
Recommended free tool to use when testing Web Services: SoapUI. It saves you from having to debug two halves of the web service puzzle at the same time.
Apr
16
Jan
26
Here’s how to solve that problem.
Exit Notes.
Locate Notes.INI. (It used to be under c:\lotus\notes\ — not under data — but newer versions install under a different location.)
Find a line with AddInMenus
If the only item listed is for Adobe Acrobat, then comment out the whole line with a semi-colon
If there are other add-ins in the line, duplicate the line, then comment it out, then modify the one still active by removing the Adobe reference
Restart Notes to confirm it’s gone.
Comments are off for this post
Jan
15
Each time you turn around, there’s another news story about compromised passwords and computer security. Just recently we’ve learned of massive breaches at Target, Neiman Marcus, Adobe, and Cupid Media (the OK Cupid dating site people.)
An important thing to remember is to use unique pass phrases on every web site so if one site gets compromised, the others aren’t.
For example, if the Adobe data dump revealed your password of “I-Like-CLU-in-2014″ to the bad guys, they will try to use that same password on your banking site and could rob you.
Some people resist using multiple passwords because they’re a pain to remember.
Here’s a suggestion — not perfect, but will do for the majority of sites — that will help keep things reasonably safe, while still making every password unique, yet memorable.
Given some baseline pass phrase (more than just a password) that only you know, such as the aforementioned “I-Like-CLU-in-2014″, append a site-specific suffix mnemonic to it. For example, your pass phrase for the Wells Fargo web site might be: “I-Like-CLU-in-2014.WellsFargo” while you might use “I-Like-CLU-in-2014.Target” for the Target web site.
If a “black hat” puts eyeballs on your pass phrase they may recognize the pattern, but in my opinion that is highly unlikely. When they harvest 40 to 70 million IDs and passwords at a time, they’re gonna write programs that test your credentials against other sites, not humanly scan each one individually.
As a side note, I recommend using a different e-address for each site you access. Unless you have some technical savvy and your own domain, this might be problematic. However, you can use a service such as offered by SpamGourmet.com to generate anonymous e-addresses that are site specific. I’ve had about 95% success with Spamgourmet.com addresses. In only a few cases (Redbox and the City of Phoenix are two that come to mind), the vendor blocks, drops, or ignores those addresses even though they are valid.
Lastly, it’s old news but I’ll repeat it anyway: make your pass phrase long enough that it’ll be hard to guess, with a mix of letters (upper and lower case), numbers, and punctuation.
Yeah, it’s all rather a pain in the okole, but replacing your credit cards, recovering stolen funds, or trying to repair your credit history is a much bigger pain.
John
P.S. I was directly affected by the adobe.com breach. After the breach I began receiving phishing e-mail from Russia. Fortunately the messages went to my SpamGourmet address, so I just disabled that one address without affecting my other logins or addresses.
Comments are off for this post
Sep
3
Here’s an interesting idea about using The Human Body as Touchscreen Replacement from the Nielsen Norman Group, experts in the usability field.
Aug
22
I have selected Murach’s Visual Basic 2010 by Anne Boehm as the textbook for CSC-300 for both the fall semester and the BDP winter term.
Addendum of 13 May 2014: Murach now has a VB 2012 edition available. Based on student feedback, the jury is still out regarding its continued use. It’s not that they think the book is bad, but rather that they tend to refer to my lecture notes instead, going to the book only for specific lookups.
Aug
8
Here’s a quote from an excellent article by Andrew Pollack about the importance of going beyond the simple capturing of requirements:
When I'm brought in to work on a significant development project as the lead, the first step is to sit down with the client and understand not just the requirements, but the goals behind the requirements and how the work they're asking for will impact the people using system. My job, at this stage is to use my experience to anticipate the unseen requirements, the potential problems, and the unintended consequences of the changes they're requesting. I do this through asking questions and getting them to walk me through both the current process and the updated process. If we have the right people in the room -- not just the project managers but also representatives of people who use the systems daily -- then during this phase they realize how the real world use differs from the project plan paperwork. We're able to adapt the plan and build what they need. Spending the right money up front on this kind of analysis prevents the kinds of disasters Cringley is pointing out.
The full article is not about requirements capture per se, but the quote above is relevant to my classes in Systems Analysis and Design and Visual Programming.
Jun
14
For my upcoming CSC-300 students in the Fall 2013 term:
I haven’t yet completed the new syllabus, but I thought I’d share the one I used last year so you can get a sense of what we’ll cover in class, nor have I selected a text book yet.
There will certainly be some changes to the syllabus because my previous classes were one night a week for four hours instead of two days a week, but I’m sure you’ll get the idea of the rough schedule.