Saturday, January 10, 2015

Four Lessons That Taekwondo Has Taught Me


It's my belief that everyone should do something outside of their comfort zone from time to time. There's no great thrill in doing something that you always knew you could do. You really experience life when you take on something where you are not certain of your ability to succeed.

When my son was 13, my business travel had fallen off and because I had the time to do something organized with him, I signed the two of us up for Taekwondo classes.

For the first while, we attended a class right after the senior black belts.  I'd watch what they did and had great doubts that I'd ever be able to do that. (I was mid-40s, initially in moderately poor shape, and not very flexible.)  For the time, I decided to focus on what I could do, which was the first upcoming test - I was doing this to be with my son, so the long term picture was secondary.

This began a journey of struggling to be ready for the next test.  It was generally challenging but that next test looked mostly achievable.

Fast forward 4 years, and I was looking at the black belt, and I knew I could do it! It would be tough, but it would be achievable!

Since then my son moved on, but I've stayed in Taekwondo.  This last year (2014) just one week before Christmas, I tested and passed my 3rd Dan Black Belt.

The experience has reinforced four things for me that I believe have helped me in all areas of my life:

It Pays to Look Ahead: 

Matthew and I at each test would watch what the people at the next belt level had to do.  We'd also watch them while we were practicing alongside them leading up to the test.  That way we knew what we would need for that next test.

We also attended a black belt test when we were still about 5 tests away from getting our own black belts.  There were things that were part of the black belt test that were not standard for a regular colour-belt test.  This was an eye opener for us, and valuable information.  Whenever you plan to do something new and different, it pays to ask lots of questions and do some research. Then plan what you will do to prepare.

Teamwork is Powerful: 

There is something powerful about teamwork.  When people really work together, 1+1 is greater than 2.  2+2 becomes greater still.  There's a dynamic that makes a group more powerful than just an individual, and up to a certain size, which seems to be dependent on the activity to some extent, the more team members you have that are really focused on getting results the more powerful the effect.

This requires the team members to have a common goal and works best in sports like martial arts, where (apart from sparring) team members are not competing with each other, but are all working to help each other.  That's a lot like many teams I've worked with in business situations, where we are all working to a common goal and seeking to help each other achieve our various objectives so that we can all win.

Taekwondo fosters the principles that support this type of teamwork.  The master and instructors of the school I attend, S. C. Kim's Taekwondo in Burnaby, BC, Canada are strong advocates of these attitudes and life-skills.  In the best companies that I've worked for, those same principles have existed to differing degrees and have been critical to the success of those projects!

Strike "Can't" From Your Vocabulary:

The word "Can't" has no place in Taekwondo, unless you have an injury, and even then, you will be given alternate things you can do.  In Taekwondo, you are not competing against the next student, but really you are competing against yourself. The battle's in your head and heart far more than in your body.

Even when I am sparring, it's less important to me that I get more points than my "opponent" but rather that I learn and improve myself.  I expect my opponent to do the same.

I guess if I was sparring in a competition with someone from another school that would change a bit, but in our school we all work to better both ourselves and each other.

When you are competing against yourself, the limitation is not what another person is doing, it's usually believing that I can do better than the last time.  It's getting that level of focus that will take me to the next level.  Sometimes it's about taking that focus home so I do the workouts and stretches I need to do in order to succeed.  When my limitations come in (injuries, lack of flexibility, etc...), it's often about finding a way to improve my technique so that the quality of what I deliver still improves despite the physical limitations

I'm now mid-50s and my body has some definite limitations - but my technique still has room to improve, so I'm still improving!  I've had lots of opportunity to say I "can't", but I always strive to change that to a question: "What other options do I have to improve?"

In short, there's always room for improvement for all of us!

Always Strive for More:

The final lesson that I'd like to share with you is to never stop growing.  There's always more to achieve. A black belt is not an end-point as much as it is a door to another chapter of your growth!

When I got my first Dan black belt, I felt a bit lost at first. There's a big time gap between first and second Dan, so it felt like there was nothing short-term to strive for. This was an important opportunity for me to realize that I could set myself personal interim goals. I didn't need to have someone else tell me what the next test was - I could make that test whatever I felt would challenge and improve me!

While there are other principles that are reinforced by Taekwondo, these four lessons are the ones that stand out for me, and that seem to resonate throughout both my work, my volunteering and my personal life!

I hope that this little post has given you some encouragement to step out and try something different to better yourself!

Thursday, December 23, 2010

Merry Christmas from FusionWare Integration Corp.



Well, another year has come and almost gone! We’ve been quietly busy getting ready for big things in 2011, while continuing to support our customers. We just wanted to take a moment to wish all our friends and customers a Merry Christmas and a Happy New Year!

Click on the link below to get a Dickensian perspective of where we’ve been and where we’re heading:

http://www.fwic.net/NewsInfo/MerryChristmas.aspx?s=bsts

Saturday, November 27, 2010

More readable version of blogs

I've been looking at my blogs here, and noticed that they are not being converted very well. These are actually poorly transfered copies of my real blog, which is much more readable (and has more entries, too.)

My real blog site is http://sototallybc.blogspot.com

I'll continue to keep a copy here, but the better copy is at that link.

Sunday, January 31, 2010

This blog has moved for now

For the time being, my new blog posts about software will be hosted at the FusionWare Integration Software blog site at: http://www.fwic.net/NewsInfo/FusionWareIntegrationBlogs/tabid/163/BlogID/3/Default.aspx.

In June of last year, the original founders of Liberty Integration Software, and later contributors to the software assets of FusionWare Corporation formed a new company to support their former customers and carry on the tradition of providing technology solutions to enable users of high-captivity legacy platforms to extend their investments with W3C standards and BI solutions from the leading vendors of these technologies. We bridge IBM i (AS/400) and Multivalue (PICK) systems to Web and BI technologies from Oracle, IBM, Microsoft, Business Objects, Cognos and many others.

Monday, May 11, 2009

Twitter Limitations

Before I do part 2 of my Twittering from U2 series, I thought I should explain some limitations of this technology.

First, you are limited to 140 characters. Actually, this is not a big deal as you can usually indicate status pretty effectively in a lot less than this, and longer strings tend to be slow to process, anyways.

Next up, there is a limit to the number of tweets you can do in a day or hour. As near as I can tell, these are the current limits:

  • 1,000 total updates per day, for your account.
  • 1,000 total direct messages per day, for your account.
  • 100 API requests per hour, for your account.

Then there are follow limits. Here is twitter's own commentary about it:

http://help.twitter.com/forums/10713/entries/14959

The entry is from last Nov., but I could not find a newer one.

You can request white list status and these limits will disappear. Note that the limits on follows are a bit more complex, and they are quite controversial. I found this link:

http://www.marrubiumwriting.com/?p=296

Interesting stuff. Note that whitelisting is not likely to happen for an automated app. Twitter is a social networking site and they are free, which means they can't afford to take bandwidth from a ton of high-volume commercial apps. Low volume notification of status stuff is probably OK, and especially if you are personally monitoring it, it falls more or less within the confines of a social networking use.

So, to summarize:

If you are thinking about using Twitter to automate something between systems, you need to find something where timeliness and reliability are not an issue (our next blog will address some of that), you need something where you are not talking about high volume. And for now, you probably need to avoid those parts of the API that involve following other Twitter accounts, unless you can keep the volume very low.

Monday, May 4, 2009

Twittering from U2: How and Why? Part 1

This is the first of several posts, where I plan to indicate how and why one would access Twitter from a U2 (Universe or Unidata) system.

For those who don't know what Twitter is, I'll provide two links that will help you to understand it. Wikipedia has a good explanation here: http://en.wikipedia.org/wiki/Twitter And here is Twitter's own page explaining what they are: http://twitter.com/about#about

So, if you've read these links, or if you're already familiar with Twitter, you've realized that this is primarily a social networking application, but that people have found other uses for it.

So, for starters, why would you want to do this?

Several uses that might be of interest to a U2 programmer include:
  • Sending messages from a system and being able to monitor them elsewhere. A powerful and simple publish/subscribe model (with some limitations).
  • Keeping customers or prospects aware of promotions, events and offers.
  • Filtering Twitter Searches programmatically, to provide a short-list of interesting messages.

There's bound to be more, but that's a good starting point.

Next, I'm going to show how to get/put updates from/to Twitter directly from a UniBASIC program on Universe on *nix. The same concept will work on Universe on Windows, Unidata on anything and for that matter, any MultiValue (PICK) platform that lets you run a cmd line application and capture the results.

To get the maximum reusability, I've done much of the UniBASIC code as subroutines, effectively an API that you can call.

I've created a directory named "TWITTER" as a subdirectory in the same directory as your account VOC resides. In actual fact, I created a type 19 file called TWITTER (DIR file type in Unidata), which automatically created the TWITTER directory for me, but we won't need the U2 file pointer at this time. I use this directory as a scratch area, a place for the java classes that I use. On non-U2 systems you might need a MultiValue file called TWITTER and a directory called TWITTER.

The java components that I use are a command line java program called FWTwitterDirect.java and an open source library that I found referenced on the Twitter developer pages, called jtwitter.jar. You can see more about this library at http://www.winterwell.com/software/jtwitter.php. Our java file is listed below:



import java.util.*;
import winterwell.jtwitter.*;

/**
* FusionWare Twitter Direct
* Copyright (c) 2009 FusionWare Corporation
* This code is released as open-source under the LGPL license.
* This code comes with no warranty or support.
* The LGPL license text can be reviewed here:
* http://www.gnu.org/licenses/lgpl.html
*
* To see info about our Twitter Gateway that provides for guaranteed
* delivery of automated tweets, filtering of incoming tweets, and more
* See FusionWare Twitter Gateway (TRILL) at http://www.fusionware.net
* Phone: 1-866-266-2326 or 604-777-4254 or email info@fusionware.net
*
* This class is a command-line utility to interface with Twitter from within
* Legacy LOB systems.
*/
public class FWTwitterDirect
{
final static char LOW_VM = (char)29;
/**
* @param args
* Syntax comes in two forms:
* Get:
*
* java FWTwitterDirect userId password
*

* Put:
*
* java FWTwitterDirect userId password "Update text"
* (Note last parameter should have quotes if it contains spaces.)
*

*/
public static void main(String[] args)
{
try
{
if (args.length == 2)
{
// Get
Twitter twitter = new Twitter(args[0], args[1]);
twitter.updateStatus(args[2]);
}
else if (args.length == 3)
{
// Put
Twitter twitter = new Twitter(args[0], args[1]);
List statuses = twitter.getFriendsTimeline();
Iterator it = statuses.iterator();
while(it.hasNext())
{
Twitter.Status status = (Twitter.Status)it.next();
System.out.println(
status.user.screenName + LOW_VM +
status.user.name + LOW_VM +
status.createdAt.toString() + LOW_VM +
status.getText());
}
}
else
{
// No good
System.out.println("Invalid Syntax:\njava FWTwitterDirect userid password [\"text\"]");
System.exit(2);
}
}
catch (Exception e)
{
e.printStackTrace();
System.exit(1);
}
}
}


The syntax for the command, when run from the directory where your VOC resides, and with no CLASSPATH environment variable set, is as follows:



java -classpath TWITTER:TWITTER/jtwitter.jar FWTwitterDirect userId password ["text"]



Note that if the text contains spaces you'll need quotes around it. If you omit the text, we retrieve the last 20 tweets for the user and the user's friends.

Now for the UniBASIC API code:



SUBROUTINE FWTWEET.DIRECT.API(DIRECTION, USERID, PASSWORD, TEXT)
*
* Author: Robert Houben
* Version: 1.0
*
* FusionWare Twitter Direct
* Copyright (c) 2009 FusionWare Corporation
* This code is released as open-source under the LGPL license.
* This code comes with no warranty or support.
* The LGPL license text can be reviewed here:
* http://www.gnu.org/licenses/lgpl.html
*
* To see info about our Twitter Gateway that provides for guaranteed
* delivery of automated tweets, filtering of incoming tweets, and more
* See FusionWare Twitter Gateway (TRILL) at http://www.fusionware.net
* Phone: 1-866-266-2326 or 604-777-4254 or email info@fusionware.net
*
EQU TRUE TO 1, FALSE TO 0
EQU AM TO CHAR(254), VM TO CHAR(253), SVM TO CHAR(252)
EQU LOW.VM TO CHAR(29)
EQU LF TO CHAR(10)
EQU CR TO CHAR(13)
*
CMD = 'sh -c "'
CMD = CMD : 'java -classpath TWITTER:TWITTER/jtwitter.jar '
CMD = CMD : 'FWTwitterDirect '
CMD = CMD : USERID:' '
CMD = CMD : PASSWORD
IF DIRECTION EQ "PUT" THEN
CMD = CMD : ' '
CMD = CMD : '""':TEXT:'""'
END
CMD = CMD : '"'
EXECUTE CMD CAPTURING TEXT
CONVERT LF TO AM IN TEXT
CONVERT CR TO "" IN TEXT
CONVERT LOW.VM TO VM IN TEXT
LOOP
WHILE TEXT[LEN(TEXT),1] EQ AM DO
TEXT=TEXT[1,LEN(TEXT)-1]
REPEAT
*
RETURN
*
END


Note that DIRECTION is passed in as either "GET" or "PUT".

For PUT, you must provide the value of your tweet in the TEXT variable. Remember to keep it to 140 bytes or we will truncate.

For GET, TEXT will be overwritten with a dynamic array containing up to 20 attributes. Each attribute is a tweet from the user themselves or from their friends, in date/time order, with the first one being the newest. For each line, it will be divided into multivalues where they are laid out as follows:

Multivalue 1 is the Twitter user name of the user that sent the tweet.

Multivalue 2 is the Twitter user's display name.

Multivalue 3 is the datetime of the tweet.

Multivalue 4 is the text of the tweet.

So, here is an example program that uses the API. Note that while this program is interactive, you can call the API from a program running in a phantom.



*
* Author: Robert Houben
* Version: 1.0
*
* FusionWare Twitter Direct
* Copyright (c) 2009 FusionWare Corporation
* This code is released as open-source under the LGPL license.
* This code comes with no warranty or support.
* The LGPL license text can be reviewed here:
* http://www.gnu.org/licenses/lgpl.html
*
* To see info about our Twitter Gateway that provides for guaranteed
* delivery of automated tweets, filtering of incoming tweets, and more
* See FusionWare Twitter Gateway (TRILL) at http://www.fusionware.net
* Phone: 1-866-266-2326 or 604-777-4254 or email info@fusionware.net
*
EQU TRUE TO 1, FALSE TO 0
EQU AM TO CHAR(254)
*
PRINT "Enter user id":
INPUT USERID
IF USERID EQ "" THEN STOP
*
PRINT "Enter password":
ECHO OFF
INPUT PASSWORD
ECHO ON
IF PASSWORD EQ '' THEN STOP
PRINT
*
LOOP
PRINT "Enter update text ('.' to retrieve)":
INPUT TEXT
UNTIL TEXT EQ '' DO
IF TEXT EQ '.' THEN
DIRECTION="GET"
END ELSE
DIRECTION="PUT"
END
CALL API.FWTWEET.DIRECT(DIRECTION, USERID, PASSWORD, TEXT)
IF DIRECTION EQ "GET" THEN
ACNT=DCOUNT(TEXT,AM)
FOR A=1 TO ACNT
LINE=TEXT<A>
IF TRIM(LINE) NE "" THEN
NAME=LINE<1,1>
DISPLAYNAME=LINE<1,2>
TIME=LINE<1,3>
MSG=LINE<1,4>
PRINT "NAME=":NAME
PRINT "DISP=":DISPLAYNAME
PRINT "TIME=":TIME
PRINT "TEXT=":MSG
PRINT
END
NEXT A
END
REPEAT
STOP
*
END



So, here are the pros and the cons:

On the pro side, you don't need any additional infrastructure, you can do everything from UniBASIC. We could extend the class file to provide different types of retrievals, in addition to the GET retrieval.

On the con side, your Universe server has to have Internet access (possible security issues), any temporary failure on Twitter's part will result in an error and a lost communication, and when you pull back tweets, you have to do your own parsing.

In my next post, I'm going to be removing the cons using FusionWare Integration Server with our Twitter Gateway technology preview. The new product is named FusionWare TRILL ™ (Twitter Reliable Intelligent Live Link).



Thursday, April 23, 2009

Open Source Web Store for System i

I've been working with a user on replacing their current web store with one that actually integrates with their System i POS system. Their old one printed an order form off, and they had to pick up the printer output, manually check inventory, grab it, complete the order, then notify the customer. If anything went wrong, they had to notify the customer. It was all asynchronous, which is not what most customers expect from a web transaction.

This is not a new task for us. We've done this for other customers in the past. You typically need to access two things: Data and Logic. Raw data is typically not too hard to get at. Logic is a bit trickier. Our customer was price concious (who isn't, these days), so we looked at ways to reduce costs for them.

One way we did this was to go with a lot of open source software.

osCommerce is an open source web store product that uses MySQL as its database. We've found a way to hook the calls to the DB and, where relevant, pull/push data from/to the POS system through PHP web service calls.

In some cases it's data that we process directly, such as inventory levels for product availability. But in other cases we provide a web services layer that calls directly into RPG programs, allowing for the POS to process order completion, including credit card validation and all that fun stuff.

We have an amazingly simple process for creating a web service that calls an RPG program, using the FusionWare Integration Server Designer.

The customer is installing osCommerce, on top of Apache and PHP, on top of Linux, on commodity hardware. They are using more commodity hardware to run the FusionWare Server on, which enables them to keep the load off the System i (we could run there, but most System i apps are running pretty full load). The end cost is a fraction of what IBM quoted them for a WebSphere and Global Services-based solution.

We've been doing this kind of data/logic integration for web sites since about 1995, when we had two customers start using web servers (One used Netscape, one used IIS) to put up web stores. These were custom jobs. They came up quickly with minimal functionality, then more was added over time. With products like osCommerce, you can quickly and easily bring up a full-featured web store, saving you the effort and pain of gradually creating this presence and getting it right. Now, with FusionWare, you can bring the freedom of open-source osCommerce to your System i POS system.

For anyone who is going, we'll be at the COMMON trade show next week in Reno. Booth number 214.