Posts

Parallel to Lincoln's angry letters never sent concept...

With all that I read, hear, and see these days about folks (not excluding yours truly) expressing themselves, I sometimes wonder about President Lincoln's idea of writing but not sending letters .  For better or worse, there is certainly a sharp contrast between that and typical use of today's communication. I was not necessarily thinking of opinions, emotions, and perspectives although I do see the wisdom in the Lincoln's method of dealing with such issues. My issue, at least this time, was being stuck with a particular problem using a technology which is not part of my regularly used skillset.  The technology itself is irrelevant to my point so I won't name it here. I had struggled with a solution after a bit of reading the documentation, searching for and modifying some similar examples, and experimentation.  The time I had put in was actually very little because I was simultaneously working on other parts of the solution.  That's another way of saying I wa...

Minishift on HyperV

Image
Although I would not consider myself as a heavy user of Windows, I believe I need to try to meet the challenge of supporting those running Linux, MacOS, and Windows. I recently ran into an issue running Minishift on Windows 10 and Hyper-V.  I suspect regular users of both of these technologies might already be aware of what tripped me up but I thought I would document it here just in case someone needs it.  In case you're not aware of it, Minishift is a very nice project that allows a developer to easily run OpenShift , also known as OCP or OpenShift Container Platform, on a desktop computer. Overall, I had a nice experience installing Minishift on a Windows 10 computer running HyperV but once I stopped and restarted Minishift, and had a new ip address address assigned to the VM, the instance would no longer start.   Now if you're doing any Docker development on your computer and you move around a good bit or perhaps you're on and off a VPN, you probably know...

OpenShift 3.x - deleting users

I have heard Scott Hanselman say  it's more efficient to blog about topics instead of emailing or otherwise writing in a way which cannot be search easily.  Looking back through my blog, I have done this some over the years but not nearly enough.  I should also admit I have googled for issues for which I could not recall a solution and found my own writings. ...now for the topic at hand: I have fumbled through this particular operation despite the fact that it's document here .  I have installed OpenShift 3.x a number of times now.  Given that this involved configuring and testing various combinations of features I have the need to delete users now and again.  When deleting and OpenShift user, it's import to delete the user along with the identity, at least as of this writing. oc delete user myuser oc delete identity htpasswd_auth:demo Also, recall you can get users and identities with the appropriate "oc get" commands. oc get user oc ge...

Firebase experience - done

Technically speaking, this issue has been resolved but I am not sure I or the support folks fully understand what went wrong.  Ultimately, as I understand it, the number of free applications on my account was increased and I was then able to transition a project from the original Firebase platform to the new one. Billing has been and is still enabled on my account so I don't know why the increase of free projects was necessary but it worked. The tech support person was polite, persistent and ultimately successful. Now I am trying to recall which of the new features was the original impetus for wanting the upgrade. ;) Happy coding, Carl

Firebase experience update

While the issue described in the last post is not yet resolved, I have had some very nice email exchanges as well as a conversation via Google Hangouts with a Firebase tech support person.  Apparently despite the fact that I am registered as paying for some Google services, I am bumping into something related to the free limit and tech support needs to work that out with the billing folks. In the meantime, I will make certain an app or two has billing activated and see what happens.  As I told the tech support person, I believe Firebase is good technology but I am caught in a crack between the legacy and current releases. I do hope this issue is not existent or made easier for others. Happy coding (and getting access to technology), Carl

Firebase experience

Image
I started with Firebase before Google bought the company.  It's definitely a cool technology but as it sometimes happens support is not always great from big companies. In trying to move an app from the "legacy platform" to the as-of-Google-IO-2016 new platform.  This process seems like it would be simple enough because they built a nice UI which ultimately takes you to an import option. When I click on the Import button for any of my apps, I get the message I have captured below. I have had several tech support email exchanges for the past month or so.  They are always polite, sometimes apologizing for my trouble but not necessarily quickly (day, two, or more between emails). The bottom lines is 1) it's not fixed...yet and 2) I don't think one can rely on such and call it support. I have a credit card on file with my Google account (I continue to experiment with various Google services) but I have been told this may have something to do with me relyi...

Artifactory and Docker

A quick reminder to myself (and anyone else who may miss this) about setting up a Docker repository in JFrog's Artifactory online service.  As of now, this page , has a "Click to expand" link under the "Working with Artifactory Online" section. The text there explains that there's a special pattern to be followed for naming the repository.  It's this information that I was missing in order to get a repository up and available for use. Here is an excerpt from those instructions: First, you need to create a new Docker V2 repository by the name  dockerv2-{local/remote/virtual}.  HTH, Carl

Opening OpenShift

Docker has occupied a good bit of my free time in recent months.  In addition to Docker and related technology, all things cloud seem to have really exploded in a great way. On all things cloud, I highly recommend The Cloudcast  podcast.  In case you are not aware, this is well produced, first-class production about cloud computing.  So far it seems to be a very well balanced technology mix and it has also reminded me of how competitors in the technology space can learn from and respect one another...when they try. Lately, OpenShift has, once again, been very much a part of my daily efforts.  Certainly I have used and been impressed with the prior release, but V3 and the move to Docker and Kubernetes under the hood was, in my opinion, an excellent move.  I am working with others on a couple of different OpenShift Enterprise (OSE)  installations but the hacker in me learns better when I play with the latest open source bits, as time permits. If y...

Docking some

Under the new technologies (at least new to me), comes Docker .  I have been playing with Docker on and off for a good bit now.  I don't think I really got it until JavaOne last October. I have created a couple of cool use cases since then that I think ultimately will really help our organization. My most recent find is the Informix image created by IBM which can be found here .  Now that I have a few containers up and running with some real data, I am trying to learn more about best practices for such use cases. Certainly getting the container running, importing a database, and running it is not difficult but specifically what the automation of all of the above looks like in production is not quite clear to me yet...but I think I am close. Happy DevOps-ing, Carl

REST from Boston

Image
Realizing it's been a long time since I (published) a blog entry, here's what I am up to at the moment...I happen to be in Boston to catch a Red Sox game and I have some down time. I am coding a REST client for the Domino Access Services which are nicely documented here .  This is one of those project that might take a throw-away effort or two before anything becomes of it but it's one that I think illustrates a couple of other nice projects. It seems to me that over the years, Spring is one of those technologies that folks love or very strongly dislike.  Personally, I think it's like most solutions: if you apply it when it makes sense, it's good stuff.  Forcing technologies that don't fit a problem is asking for frustration. If you're coding in Java and need to consume a REST web service, the Spring RestTemplate is worth a look . Another library I have used several times lately is OWNER   If you Java application utilizes properties, check it out...

JavaOne 2014

It was nice to get back to San Francisco for another JavaOne.  This year did not surprise me in any way with announcements but it did feel like a JavaOne filled with energy and enthusiasm.  I think getting Java 8 out and accepted was the primary reason but there are other significant ones. First off, being a NetBeans fan, I very much appreciated NetBeans day and sessions throughout the conference in which it was mentioned and utilized.  While I have known my way around Eclipse for years (and I have used Intellij), when I tell folks I prefer to use NetBeans I get an occasional strange look or question but that's becoming less so. If you don't know about NetBeans, I suggest downloading and giving it a serious look.  If it's the choice of James Gosling and guys who write code for NASA, how can you not check it out?   Geertjan Wielenga, the guy I consider the face of NetBeans, was very visible at JavaOne/NetBeans Day this year (as were quite a few others from t...

Five Favorite NetBeans IDE features

Image
Thinking about it earlier today, I have been using NetBeans before (or after actually) it was called NetBeans.  I say after, because I remember using Forte but it was called NetBeans before and after Forte.  To put that into some perspective, some years ago I was at a JavaOne (2002?) at a Meet the Forte Tools Experts session.  NetBeans has come along way since those days but I recall seeing a lot of promise which has been a reality for a long time now. The first thing I liked, and still like, about NetBeans was that it has a familiar look.  This may be because I was a long time Delphi and JBuilder user, both Borland IDEs, and NetBeans was, at least to some extent, inspired by Delphi's IDE style and functionality.  NetBeans feels natural to me and I think it is generally very approachable for new developers. Out-of-the-box functionality is my second reason for liking NetBeans.  I install the full version of NetBeans on OS X, Linux, and Windows and I am ...

End of a run and a new favorite?

I just came across a relatively new podcast called The Web Platform Podcast   The Web Platform Podcast is hosted by Erik Isaksen  ( @eisaksen )  and  Christian Smith ( @anvilhacks ). While I there are a few regular technical podcasts I try to make time for, I have been looking for something like what I think this is/will be ever since  The Java Posse  slowed or stopped, I am not sure which. The guys from the Java Posse had a unique blend of current technology, Java/JVM, humor, and overall production quality.  Joe, Tor, Dick, and Carl set the bar pretty high in my mind but like many good things they sometimes come to an end.  [I realize it's been some time since Chet replaced Joe but there have not been too many recorded episodes since then.]  I don't mean to discount the Roundup sessions because some are very good but they are sometimes hard to hear. I do hope The Web Platform Podcast both lives up to it's deep dive of "...'all things' w...

Themes for NetBeans

I have no idea how long this site has been around or how I missed it until very recently but I am glad I found it.  If you like NetBeans but would like to change the colors to match another favorite IDE or editor, there's a chance someone has already done it.  Check it out here Happy editing, Carl

JNLP: note to self

Java security was a hot topic in 2013 and I think it will continue to get some attention as tooling catches up to the newer requirements.  Signing the JNLP for Java Web Start programs is now required. The Java Web Start maven plugin does not yet sign the JNLP file but there is an outstanding issue which I imagine will be resolved before too much longer. In the meantime, this blog entry  and this stack overflow question and answer  may be all you need to get your JNLP signed correctly. The way I read it, you have two choices. First you can create a template file which should be named APPLICATION_TEMPLATE.JNLP in src/main/resources/JNLP-INF and wildcards are permitted.  This is nice if you have the need to deploy your application from more than one server. The second method involves creating a file named APPLICATION.JNLP also in the src/main/resources/JNLP-INF folder.  This file must match the application's jnlp file exactly. Don't forget to mo...

Glassfish JNDI settings

Image
Recently we had the need to add some configurable settings (such as user credentials) in a Java EE 7 application running on Glassfish 4.0. An example method to read the values might look like this:     private String getUserProperty(String property) {         String result = "";         Properties properties;         try {             InitialContext context = new InitialContext();             properties = (Properties) context.lookup("jndi/userinfo");             result = properties.getProperty(property);             context.close();         } catch (NamingException e) {         }         return result;     } Setting the values via the Glassfish console is achieved via Resources -> JNDI -...

NetBeans 7.4 recent projects

Image
Recently I had the need to remove one project from my recent projects list in NetBeans.  The problem was I had opened a very large project which was causing the    I found a few references to where one might find the file which contains the recent project list for older versions of NetBeans but they seemed to be a little dated.   The file I wanted to find and edit is called projectui.properties I happen to be on a Mac so that file could be found here: ~//Library/Application Support/NetBeans/7.4/config/Preferences/org/netbeans/modules I opened the file with a text editor and looked for the project name in the openProjectsDisplayNames entries.  Each of the entries include a dot followed by a number at the end to make them unique.  Once I found it, I noted the number and deleted that line.   Next I removed the corresponding entries in the openProjectsIcons and openProjectsURLs sections as well. I have a cou...

LibreOffice

I was recently asked about Mac/OS X software which can read and write WordPerfect format files.  As a not-so-regular but long-time OpenOffice user, the OpenOffice/LibreOffice debacle immediately came to mind.  There were numerous articles and blogposts written about the situation including a good bit of FUD.  The net effect on me is that I don't immediately know which one to recommend, assuming such a solution is otherwise in the best interest of the user. Ultimately I tested LibreOffice 4.1.4 on a couple of handy WP files I had handy and it worked well enough for my own needs.  [The latest version of OpenOffice I had installed would not read WordPerfect files but I believe I have used a filter to do so in the past.] The trick, however, seemed to be actually downloading a current copy from the LibreOffice site .  Perhaps I caught it at a bad time, but I had to try three mirror sites before I could get anything close to a reasonable download speed or worse ...

Complex JAX-RS

Working with JAX-RS to create a REST web service, I recently had the need to accept a List of a complex type as a parameter.  I was not able to find a complete example but I did read some Jersey documentation which I had not looked at in quite some time.  I read the  Jersey Parameter Annotations  section. The issue I was running into was the lack of a constructor for the complex type I wanted to pass in a list as a parameter to a REST web service method.  The documentation made me realize that I did not have a constructor which accepted a single String parameter from which an instance could be properly created. I also had some trouble with JSON marshalling/unmarshalling.  This may be a topic for another time but for now I solved it using the ObjectMapper from Jackson. Ultimately I put a trivial demo app together which is available here .  The application was created using NetBeans 7.4 as a maven web app to run on Glassfish 4.0 for convenience. ...

Out-of-the-box

The Intellij  IDEA IDE from JetBrains is one of those tools I have wanted to like for years now but it seems I am coming at things from a different perspective and so far it has not worked for me. I take it for a spin now and then (purchased licenses several times over the years to go beyond a short evaluation) and I thought the recent release of 13 signaled it was time to try it again. I downloaded the free Community Edition.  I decided to create a JavaFX application as my first action.  I tried it on a MacBook which happen to have a recent build of Java 8 on it.  IDEA found the JDK (this may have been from a previous installation) OK but the app would not run. The Fatal Error that greeted me after I clicked the Run button was:  unable to find package java.lang in classpath or bootclasspath My correction was to remove and add back the SDK.  (File -> Project Structure -> SDKs)  I'm not sure how extreme this might be considered by IDEA lo...