Sunday, November 24, 2019

What is an Eclipse or STS Workspace?

What is a workspace in an Eclipse-based integrated development environment (Eclipse, Spring Tool Suite, etc.), and how do you use it? For all of the documentation on Eclipse, including configuring workspace settings, nothing in the docs explains the basic concept.

Background and Structure

There are situations when a programmer needs to have multiple projects open at the same time because there may be dependencies and/or need to be worked on in parallel. Some IDEs require multiple copies to be open, but Eclipse allows the programmer to work on multiple projects in a single instance of the IDE.

Saturday, April 7, 2018

Renewing a TLS Certificate for IIS HTTP and FTP

A existing TLS certificate for IIS may be renewed without creating a renewal request, by having the issuer provide the updated certificate using the original public key. The example here uses GoDaddy as the issuer.

Part 1 - Install Intermediate Certificates

Godaddy provides a zip file with the new certificate and one or more intermediaries. Extract the files and install the intermediaries using the Certificates snap-in for MMC. In some servers you can get directly there by searching for "Manage Computer Certificates." If that doesn't work open the Microsoft Management Console (MMC):

Friday, March 30, 2018

Grails Cannot Build Ellucian SSB Application

Applies to Banner 9 and Grails 2.5

After cloning a Banner 9 SSB app and adding the plugins, it will not compile! The underlying problem is that in some cases Grails looses the core repository when it is trying to install some dependencies. These are examples of messages that may indicate this problem:

| Error An error occurred installing the plugin [markdown-1.0.0.RC1]: Unable to delete file C:\Users\Administrator\.grails\2.5.0\projects\SelfServiceBannerGeneralEventManagement\plugins\markdown-1.0.0.RC1\lib\remark-0.9.3.jar

Thursday, January 25, 2018

VS Code and the Node Version Manager

nvm is not compatible with the npm config "prefix" option: currently set to "/usr/local"

We can fix it! Jump to the end if you just want to know what to do, the middle explains why you need to do it.

This error was especially difficult to run down, which is why it warrants documenting it here. Ultimately it was a combination of how Node.js is installed, the Node Version Manager (nvm), a feature of the bash shell (3.6.2) in MacOS High Sierra, and that Visual Studio Code starts an integrated terminal with a login shell that triggered it. I have not explored any other Mac systems, and Linux systems could be affected as well. Similar behavior likely means the same problem is occurring.

Thursday, October 5, 2017

Normalizing SDKMAN Across Development Computers

Why do we need this?

sdkman is a great tool for a single-source management of software development kits for multiple frameworks. Providing a consistent location for SDKs is a priority when projects are being shared across multiple development computers, either by just copying the folders or using repositories like Subversion and Git.

The location of SDK dependencies is kept in the project files defined by the development tools, like Eclipse and IntelliJ Idea. If the project is shared or checked in or out of a repository, the last person to check it in will commit their own personal settings. Then the next person to check it out has to change the settings to match their computer, and those are what get checked back in.

Thursday, September 28, 2017

Grails Development FAQ

Updated October 10, 2017

This is a growing list of frequently asked questions (FAQ) that I encounter teaching Groovy & Grails, with an eye toward Ellucian Banner XE Self-Service development. While many of these questions are Grails specific, a few pertain to the JetBrains IntelliJ Idea IDE that I use in class. Check back to see if the list has grown bigger:
  1. Can I open multiple projects in the same window in IntelliJ?
  2. Why doesn’t my Grails classrecompile and reload in the development server?
  3. Changes to my controller and domain classes compile and work. So, why do I get random errors in the run window, often a NullPointerException, sometimes related to scaffolding?
  4. I already have the browser open on the application page that I want, how do I stop IntelliJ from launching a new page for the application if I restart the development server?
  5. Hibernate with the H2 database writes an awful lot of log messages to the Grails console!
  6. If I use respond in the controller, where is the model data in the view?
  7. Where is the model data? I can’t find it when I dump out the request in the GSP!
  8. If I create a new domain instance from the params map, the id property is not set! And, the same thing happens if I try to copy the properties from one domain object to another. What is happening?
  9. Do I need to convert a string id from the params map to an integer before using get?
  10. How do I fix the Grails SDK? It changes every time someone checks in the project!
  11. I change the Grails SDK, and now IntelliJ Idea says that Groovy is not configured!
  12. null id in ... entry (don't flush the Session after an exception occurs)
  13. Why does saving a new domain object flush database changes?
  14. On a Mac I can't see ~/.sdkman to get to the Groovy or Grails SDKs?

Tuesday, September 5, 2017

Banner 9/Grails 2.5 Development Problems and Resolutions

Updated 3/29/2018

This is a page of random problems and solutions encountered using Grails 2.5 for Ellucian Banner XE (9) Self-Service development. As new problems are resolved, they will be added to this list ordered by the resolution date.

20180329 Grails cannot build SSB app

Grails cannot install the plugins needed to build an SSB application. The problem often is the repository configuration, see the blog post Grails Cannot Build Ellucian SSB Application.

20171005 module not found: org.codehaus.groovy#groovy-all;2.4.4

This is a grails 2.5.5 issue. Make sure that you are using Grails 2.5.0 for Banner development. Grails 2.5.5 was a bad release where projects are configured to use Groovy 2.4.4, but it shipped with Groovy 2.4.5.

20150910 JavaLaunchHelper has Multiple Definitions

This one shows up in Apple MacOS, but not in Windows. In Java 8 the class JavaLaunchHelper is implemented in both the JDK java command and in the libinstrument.dylib library. Since they both seem to be exactly the same, the message is just an annoyance that cannot be squelched.

20170902 Grails Throws a NullPointerException on Recompile & Reload

After a file is changed, such as a controller, Grails notices the change, recompiles, and reloads the file but throws an error similar to this: ERROR plugins.AbstractGrailsPluginManager  - Plugin [controllers:2.5.0] could not reload changes to file.

Update 2017-10-09: this problem has appeared for me on Linux as well. This problem has only appeared for me on Microsoft Windows systems: when a class is recompiled and reloaded, a NullPointerException is thrown, often by the AbstractGrailsPluginManager. The class is actually recompiled and reloaded, so it was not clear exactly what the problem was. Sometimes the error originates in the scaffolding system, even when the application does use scaffolding. There are plenty of comments around the Internet about disabling forked execution, but only one comment clarified why.