Winds of Change

May 27th, 2008

Though I cannot go into detail at this point in time, an amazing opportunity has presented itself to me. If the cards fall correctly, my name will appear in the credits of a mass-produced computer game in a year or two. If that endeavour proves successful, then my software development career will take a turn toward greener pastures.

Stay tuned…

Don’t Panic

May 26th, 2008

My last day in Japan was an extended 36-hour affair which was spent immersed in an adventure which was a notable mix of serenity, dash, blistered feet, “Don’t Panic!” and funk.

I’ll start with the funk part. If it were somehow possible, I would apologize to everyone who had to sit near me on Northwest Airlines Flight 386 from Detroit to Boston. I was the Grandmaster of Funk and not in a musical way. This funk was not the result of this previous week’s new menu selections. No, this was just a good old-fashioned sweat-fest brought on by me almost missing my flight back home from Japan.

Perhaps, I should start at the beginning.

The Plan

No battle plan survives first contact with the enemy. And I have seen the enemy and he is me. The plan was to get up early and go out for one last outing into Nara Park. My target: Kasuga Shrine

The shrine was a 2.7km walk one way. A little over a mile, true, but I’m a hiker. A hiker walking in Bass leisure shoes, but a hiker nonetheless. No sweat!

Since I still hadn’t bought any souvenirs yet, I would set out early after packing, get to the shrine, come back just in time for the shops to open at 9am, get back, pack the last few items, check-out and catch the 10am bus to Kansai Airport. I need to get that bus; the next one would depart at 12 noon and my flight leaves at 12:50pm.

The Presence

Finding Kasuga from the Hotel Nikko Nara is easy. Just walk straight, which I did. Eventually, the road goes uphill to a T intersection, where going straight becomes a gentle wide foot path beyond a torii.

Whereas the city folk in Nara proper left me pretty much alone, the gentlemen taking their strolls along this footpath greeted me with a “gozaimasu”, or “good morning”. I would have replied in kind if I’d known what they were saying. Instead, I simply bowed in recognition.

The park-like footpath continues across two cross streets, until it enters a more wooded area. The footpath remains wide and I continue.

The day’s length prevents me from going into much detail as this walk took place over 24 hours ago. However, I can remember quite a few details.

The close I got to Kasuga Shrine, the more of these inscribed stone lanterns could be seen along the path.

Up and up and up my stroll took me. The path brought me to staris and still I kept climbing. Meanwhile, a couple of nature paths were branching off to the side. I come to some Botanical Gardens, but they’re closed, so I keep pushing forward.

I finally reach the shrine proper, but it’s closed. However, a central courtyard is open and I go in and walk around. Within the space, is a 1000 year old tree, the subject of numerous ancient silkscreens. After looking around, I leave and continue following the pathway.

When I reach a point where I need to think about turning around, I spy a map and it shows a nearby side path which will lead me back from where I came. So, onward I go and take the side path right.

*sigh*

I’m in heaven.

There is a part of me that wants to iterate the obvious. I’m figuratively in heaven. Except, maybe not quite. Maybe it was the inate sacredness of the site, or the old age of the trees, or the total serenity of the place that set my soul to singing. I’m not really quite sure. But on that walk, in those woods, I felt it. The Presence. And I knew that I was not alone.

The Presents

Rejoining the main pathway below Kasuga Shrine proper occured much too soon, but I did have to go back. Unfortunately, I made excellent time returning to Nara proper. The souvenir shops were still closed. So, I went to the Starbucks in Kintetsu Nara station, ordered a venti mocha and people watched. It’s only 8:15am.

My plan is beginning to fray, however. After finishing my coffee, it’s still 8:45am. The shops are still closed, but now I have to go to the bathroom. I figure that I’m close enought to the hotel that I can walk there, do my business, walk back, shop, walk back, check-out and be done. As you can guess, it didn’t work out.

I underestimated the time. Let’s cut to the chase. By the time I was at the souvenir shop, it was 9:35pm. I still have to walk back, get my stuff check out and catch the bus. I checked out at 10am. I missed my bus.

Tennoji desu

While paying for my room, I explain my plight to the woman serving me and ask how much a taxi would cost. 25,000 yen, or $250.

Oh my.

She then offers that I could take the train to Kansai. I would take Nara to Tennoji, then switch to another train to Kansai. How long will it take? Hour and a half, she says. After quick calculation, I figure it’ll be enough time. Don’t panic.

My first near-mistake was boarding the 10:02 train to Osaka instead of the 10:17 train to Tennoji. Thankfully, I had already asked a gentleman on the platform about the train I was boarding and he got on to tell me to get off and get the next one. Close call. Don’t panic.

I get on the 10:17 train and listen carefully to the announcements on the PA. “Nara, Koriyami, Oji, Ryuhoji, …. Tennoji, …..”

At 11am, I hear “Tennoji desu”. My stop.

Missed It By That Much

I lug my stuff off the train, then try to find a map that I can understand, b/c my grasp of Hirogata and Chinese characters isn’t strong. Ah! Track 15 serves Kansai. I check the times. It’s still doable. Off I go.

When I get to Track 15, I see that there’s an 11:02 express to Kansai Airport. Perfect! Ummm, what does that 19 on the board mean? It seems to mean a boarding position. Where am I. 3. So, where’s 19? I walk to the right along the platform to find it.

I should have walked left. By the time, I figure it out, the express is leaving the station. Don’t panic. The 11:09 is heading to Kansai, too. It arrives and I get on.

Fast forward.

I arrive at Kansai Airport at 12pm. My flight is already boarding and I have yet to figure out this airport. International departures? That way, up the escalator and left and right and down this hall to a central area.

International departures are in either the North or South Wing. Uh-oh. Don’t panic. There’s a board. Northwest Airlines is in the north wing. Off I go.

Ah. There it is. The flight to Detroit is using D-6. And the 12:50 departure time has been changed to 12:40. I find the check-out desks. Ummm.. the area is roped off, but there are still some people working there. That can’t be good. I get in line and someone asks me what I need. Flight 70, I say. It’s 12:15.

She panics and enters extreme speedy mode. Come here, get out your passport, are you checking in any luggage, good, oh you checked in on-line, you needed to be here an hour before boarding. I know.

She prints out my boarding passes and sends me off.

More walking. My feet are killing me from earlier today. I can feel the blisters forming, but there’s naught to do about that.

A train? I have to take a little train to another part of the airport. Are you kidding me? My feet say, “It beats walking.”

Off we go. I have to have my carry-on luggage screened. Yadayadayada. Tickticktick. Where’s my gate? There it is. A-6. The end of the boarding line is still there. I run and take my place. Whew!

The Sweet Smell of Victory

I make it, but I’m a dripping mass of nastiness. The weather in Nara was near 80 and very humid. I was wearing a long-sleeve t-shirt with carpenter pants, decent gear for 60s in New England. After all of my running around Nara before taking the train, I was sweaty. After lugging my stuff across two trains and running across an airport, I was dampness personified… with an 11+ hour flight ahead of me.

So, as you can guess, I must have been pretty rank on the Detroit flight. Even the connection there had only left room for a 20 minute rest as I had to have my stuff screened getting off the plane and then screened again getting onto the different plane. Plus, I had to pass through customs & immigration.

But, I did it. I made it home.

My Week in Japan

May 25th, 2008

Three weeks ago, I was starting the second week of a two week vacation. The first week was spent in New Hampshire’s Lakes Region near Lake Winnepesaukee. The second week was going to be spent cleaning and organizing the house. On Monday, however, I got a call from my employer. They called to ask me if my passport was up to date. “No,” I answered, “it expired 9 years ago. Why?” Because MajorJapaneseCustomer™ was approaching a deadline in developing a $20K multi-function printer and was having a lot of problems using a piece of technology that I had invented. So, they wanted me to fly over there for a joint debug session in order to save the project.

On Tuesday, I went in to work in order to get the passport process started. My employer was going to use a passport expediting company in order to fast-track the paperwork. Meanwhile, my flight and hotel reservations were being made. The following week was spent waiting for my passport, ironing out the ever-changing hotel reservations and working on some of MJC’s™ issues before my flight on Saturday.

The flight was a lengthy affair. I spent an hour and a half flying from Boston to Detroit and 12+ hours flying from Detroit to Osaka’s Kansai Airport. I left at 12:05 pm on Saturday afternoon and arrived in Osaka at 6:30pm, Sunday. With Japan being over the International Date Line, I wound up losing a day after spending half a day in travel. I was scheduled to go into work at 9:30am the following morning.

The flight itself was uneventful. There was very little turbulence beyond the usual bouncing that occurs as the plane climbs or descends during a take-off or landing. Once we hit the cruising altitude of 39,000 feet, it was smooth.

Overall, the trip itself was a mix of culture shock, mind-crushing code diagnostics, pleasant surprises and complete serenity.

Hishida-san, from my employer’s Tokyo office, met me at the airport wearing a gray suit and a Boston Red Sox baseball cap. From there, we took a one hour bus ride to Nara, site of MJC’s™ manufacturing and development complex and my hotel. After we both checked in to our respective hotels, Hishida-san had to stay at a different hotel that first night due to limited availability, we met for supper.

“What would you like to eat?” he asked me.

Ah. The big question. I have always been a fussy eater and I hate seafood. In the days leading up to this trip, I had been dreading this moment. But, after such a long flight and finding myself in a different country with a different culture, I decided that I wouldn’t fight it. I could make this difficult and/or be scared of the unknown, or I could allow myself to be pleasantly surprised.

My answer: “I’ll leave it up to you. I’m willing to try anything.”

We went to a Japanese pub. The pub itself was upstairs and, once there, we took our shoes off and walked in. Our table was panelled off like the others and was low to the floor. It was Japanese. One pleasant surprise was the pit under the table so you could sit comfortably while sitting on the floor. We started with a glass of Suntory beer and waited for the first course.

The first course was sashimi. Raw fish. With chopsticks. Here we go.

It was excellent! Absolutely superb. And so began my love affair with Japanese food. Over the next few days, I would have sashimi, sushi, tempura and Japanese versions of Korean barbecue and Chinese noodles. All new and all excellent. I didn’t have a bad meal the entire time I was there.

I also tried sake. It was, again, excellent. On Wednesday, Hishida-san and I went to a more upscale restaurant and ordered three rounds of sake. Two were rice-based and one was based on plum leaf and they were each served in different glasses. They were delicious. On Friday, Takuya, a co-worker from our local office who does a lot of work in Japan, took me out to Kyoto for a night on the town. We went to a Japanese bar where I had another variety of Japanese food and two more rounds of sake. Tasty, tasty, tasty stuff.

I also found that my chopsticks technique improves with the amount of alcohol I drink. Go figure.

The work aspect started off poorly, but improved tremendously. The formal business culture of Japan, coupled with the language barrier, mixed with a nasty case of jet lag, left me barely functional. I spent the first day trying to learn the various nuances of the customer’s product and trying to rethink various aspects of my code. That night, the customers took us out to dinner, where I barely functional. My chopsticks technique was poor enough that I was given a fork. Without my asking for it. That hurt.

That Monday evening, back in my hotel, I felt lost and alone, in spite of Hishida-san’s welcome the evening before. The issues involved were difficult to solve and I felt like an outcast because of the language barrier. I was frequently left out of conversations, although some attempts were made by the customers to include me. However, my jet lag and the background din of the restaurant made even those attempts difficult.

I turned things around on Tuesday morning. Like Sunday evening, I vowed to not let it get the better of me. I got over the worst of the jet lag, though I would never get over it completely, and poured myself into the work. If I couldn’t speak Japanese, I would speak to them with the quality of my work.

The results were stellar. Not only did I fix the issues with my code, on Tuesday no less, but I also fixed two major bugs that were not in my area of expertise over the next two days. On Friday, Takuya returned to Nara from Tokyo to discuss our remaining role in the project. We finished by 3pm and then were asked to remain for an hour in order to meet with the general manager of the entire complex.

This was an unexpected honor. During my week there, I’d been working alongside MJC’s™ color scientist to fix the problems with the code. In addition, I’d met his boss and had met his boss’s boss. That is usually it. This time, though, the general manager of the complex was taking time out of his day to meet us. As Takuya said later, this never happens unless we royally screw up or do an exceptionally good job. I’m happy to say that we accomplished the latter.

As I mentioned earlier, Takuya brought me to Kyoto to thank me for a job well done. After walking around the city, Boston’s sister city as it turns out, we found a Japanese bar and ate a little and drank a little. The food and sake were excellent as always.

Takuya and I parted at the train station, where he took the Shinkansen back to Tokyo and I took the Kintetsu line back to Nara.

I was on Cloud Nine. After much pre-trip trepidation and a rough start to the work, I was able to meet and exceed all expectations, my own and the customer’s. My feet barely touched the ground during my walk through Nara back to my hotel. In fact, just to cap off the night, while walking down a covered street lined with shops and restaurants, I thought I heard someone behind me say, in English, “I think he’s cute.” Now, that comment might not have been meant for me, but I was the only foreigner there that I saw. So, yeah, I was on Cloud Nine.

Because of the nature of the trip, the sightseeing opportunities were limited. Still Hishida-san did his best to squeeze in some time for me. Early Wednesday morning, we took an early walk to Todai-ji Shrine before heading to MJC’s™ site. It was fabulous and quite ancient. The statuary and woodwork were exceptional. Unfortunately, I bought a cheap digital camera on this trip and the picture quality is quite bad. I may post pics later anyway.

While we were there, Hishida-san and I passed by a group of uniformed schoolchildren. After we passed, I suddenly heard, “Hello! Hello!” I turned and there were about 7 or so schoolgirls waving and saying Hello. I said Hello and waved back and they all giggled. I then turned to Hishida-san and said, “I guess I don’t blend in too well here.” He laughed.

Because Hishida-san was returning to Tokyo the next day and Sakamoto-san was coming to take his place as my interpreter, I was able to spend some time by myself on Thursday morning. After working on a bug in my hotel room early that morning, I set out for Kofuku-ji Temple, a 5-story pagoda-style temple. Hishida-san and I had walked there after our trip to Todai-ji, but it was closed. This time, I left later in the morning so I could get in. It was still closed, however. So, I walked around Nara Park a bit more before returning to my hotel room. Along the way, there were numerous school and Japanese tourist groups milling around. And, as happened the day before, numerous schoolchildren would yell, “Hello! Hello!” to me and giggle. It was very cute.

When I made the decision to turn back to the hotel during my walk, I had discovered a torii beyond which lay a nicely graded footpath. My hiker heart longed to hike beneath the torii and discover what sights lay beyond, but I dared not. I already had quite a ways to go to get back and I still had some work to do for the customer. So I reluctantly turned away.

Saturday, my final day in Japan and my day of departure, would find me back at the torii and in a mad dash to not miss my flight home. But that’s a story for another post.

Hergest Ridge

April 11th, 2008

Audiophiles will understand this post.

First off, I love the Internet. I love, love, love it. Yeah, it has its flaws. No doubt about it. But, last night the Internet allowed me to immerse myself in absolute musical heaven.

One of the interesting things about growing up in the environment I did was that, in spite of my non-musical abilities, I hung around with people who did. They were the band geeks. I was a chess/math geek. However, one thing that geeks have in common is a love of knowledge and a quest for the unknown. Band geeks love music; at least the ones I hung with. And so, I became a music lover as well.

I remember the first time I heard Mike Oldfield’s Tubular Bells. I heard it pure; free from its eventual association with The Exorcist. It was so different, so … awesome. Certainly like nothing that got radio airplay back in the day.

My father was an audiophile and, truth be told, I am an audiophile because of his influences as well. Being an electrician, he built his first stereo system from kits and parts. His tastes were nothing like mine, being rooted in classical and jazz, though I do now own a copy of Chick Corea’s “Return to Forever” CD because of him. So, after experiencing music like Tubular Bells as well as other varied genres of music, Moody Blues, Boston and the like, I asked my father for a stereo for my upcoming high school graduation gift. Together, we picked out the various components: Technics receiver, Pioneer turntable, &c.

As this was 1983 or so, the Technics receiver had analog tuning. The “needle”, which slid across a frequency scale by means of a dial, was a backlit piece of plastic. The lighting would turn green if the signal wasn’t strong enough and turn white when the signal was strong enough to be locked. It was a pretty cool piece of kit back then.

Anyway, after picking up Oldfield’s Tubular Bells, I browsed the record store looking for another Oldfield offering. There in the bins was Oldfield’s 2nd album, Hergest Ridge, another 2-track offering.

It was … absolutely outstanding. While it lacked the excitement of Tubular Bells, Hergest Ridge was a well-balanced moodily ambient piece interspersed with guitar riffs that complemented the overall mood. It was music that could be played as background, but that could also stimulate the mind when played back through headphones. It had aural textures, layers which fed each other and became more than the sum of its parts.

In short, I absolutely loved it. I nearly wore out the vinyl playing this gem over and over again.

Fast-forward to the late 80s, when CDs started becoming commonplace, I decided to trade all of my vinyl in for $$$ at a used record store and started rebuilding my music collection with CDs. One of my first purchases was Hergest Ridge.

What a disappointment!! Somehow, inexplicably, the mix had been changed. What had been a major musical treasure of overlapping complementary textures was now a cacophonous mess! WTF?!!!

Over the two decades since, I’ve tried and I’ve tried and OH GOD(!) how I’ve tried to get into and appreciate the new mix, but to no avail. In my humble opinion, it sucks in comparison. Musical layers which were in the background were now in the foreground and vice versa. It was like watching Star Wars, but with the colors inverted.

So last night, after trying to listen to Hergest Ridge once again, I decided to do an Internet hunt to see if perhaps my CD pressing was in error. Perhaps noone else had this problem and I could simply order a new one. I was clutching at straws.

First stop: Google. From Google, I went to the Wikipedia entry on the album. There, before my eyes, the mystery was solved. In 1976, Mike Oldfield remixed the album for quadraphonic stereo (an early attempt at surround sound) and released it as part of a boxed set called Boxed. Furthermore, he stipulated that this mix was to be the one used for any future rereleases. That’s why the CD is different. It’s using the Boxed mix. And the publisher’s hands are tied.

What?!

Why?!

(My Star Wars analogy was proving profound. Maybe George Lucas and Mike Oldfield know each other. *cough* Han shot first! *cough*)

From there, I followed a Google link to Amazon. There was a new 2000 remastered pressing of the CD. Hmmm…. Maybe….

But no. A reviewer there had the same lament as I did. It was the Boxed mix. “Don’t waste your money.”

I then followed yet another link to a “private” discography which mentioned an “original mix”. Turns out, a sound engineer by the name of Martin Bartošik, himself a huge Mike Oldfield fan, transferred the original vinyl recording to digital and then post-processed the resulting digital music to remove the pops and skips that vinyl produces.

Hope? Could there be hope?

Back to Google: “original mix hergest ridge”

A HA!!!!

After skipping past several bit torrent links (which I won’t use b/c I don’t want my system to be a download station), I finally found a blog entry with a link to where I could download the files.

  1. Download .rar file
  2. Download Unrar Utility for OS X
  3. Extract music
  4. Import into iTunes
  5. Listen

For the first time in over 20 years, I am finally, finally, finally listening to the original 1974 mix of Hergest Ridge.

Oh sweet music!!!……..

Gremlins

April 3rd, 2008

High tech devices can bring a lot of convenience to our lives, when they work. For me, last night showcased just how dependent we can become on such things.

Last night, my wife’s MacBook shut down unexpectantly. A subsequent attempt at a reboot displayed the “question mark folder”, instead of the monochromatic Apple logo. The last time this happened, her hard drive had turned itself into a brick. Luckily, I had backed up her important files to the new file server this time. Last time, she lost everything.

Two days ago, the Tivo stopped working. My wife said that it had entered an infinite cycle of rebooting, playing and getting stuck. After seeing it for myself, it looks like the hard drive on that beast is on the way out. It’s not a doorstop yet, which is good. It looks like there’s a bad sector where the software records the “live” buffer. Now, imnsho (in my not so humble opinion), the software should figure out that things are rotten in Denmark and find another spot on the disk to record the live buffer. If that feature is in there, it’s not working correctly. So the Tivo, while not completely dead, is unusable.

Three months ago, the XBox 360 stopped working. I get the “red ring of death” when I turn it on. My son is quite upset at this turn of events. Thank you Microsoft QA Department. Both of you.

In the short term, I fixed the Tivo issue by buying an a/v cable to run from the cable box directly to the a/v ports on the front of the tv, just so we could watch tv, even if limited to *gasp* real-time viewing only.

Today, I took the wife’s MacBook to the Genius Bar at the Apple Store. I was dead sure that the drive was kaput, but, lo and behold!, it wasn’t. A quick run of the Disk Utility app, fixed things on the drive and it seems as good as new. Deep down, I’m skeptical, but if it’ll allow me to make a newer backup as soon as I get home, so much the better.

The CDRW/DVD drive on it is a goner, however. I’d known this for quite some time, but my wife doesn’t install software nor does she listen to CDs on it. The Apple Store geniuses will replace the drive for $300+, but I balked at the price. I can do it myself, if need be. Mac OS X also allows users to share their CD/DVD drives so I can install software on the wife’s MacBook by using the DVD drive on my MacBook Pro and sharing it. No problem.

Since the Tivo has gone bonkers, after talking with some of the other geeks I work with, I decided to buy a new HD-capable Tivo. This one can support two CableCard tuners, allowing viewing on one channel while another channel is recorded simultaneously. I can even record two channels simultaneously while watching a pre-recorded show. Plus, it’s HD-capable. Plus, it’ll display HD content on a standard def tv through a variety of methods including letterboxing.

As for the original Tivo hard drive. Well, a Tivo is essentially a single-purpose Linux computer. The hard drive can be read by Linux computers and the files on the drive can be copied off. So we shouldn’t lose anything.

And the XBox? I have to call GameStop and see what my options are.

All in all, I got slammed by all three of the big computer-tech paradigms: Apple, Microsoft and Linux. The Apple one was handled free of charge in their store, minus the CD/DVD replacement. While the Apple replacement cost is annoying, my warranty had expired, there is a software workaround within OS X, so I wasn’t forced into paying for a replacment of limited usefulness.

The Linux fix involves a feature/machine upgrade, but I’m not going to hold it against the Linux paradigm. If I wanted to go through the effort, I could just replace the hard drive with a new one by copying the Tivo software and files onto the new disk. Hell, I could even put in a bigger hard drive, if I wanted to. However, with HD going on-line in a year or so, upgrading the Tivo now saves me from the effort later. Plus, the price on Amazon was outstanding.

The Microsoft issue scares me. I don’t expect it to go well at all. ‘Nuff said.

A Side Project

April 2nd, 2008

A friend of mine has decided to move her fiction from a fan fiction site. She asked me if I knew of a free place to host it and I offered her some of my web space. I also offered to design her new site as well. This will be my first all-Ruby site, the SpedPAC Rails fiasco notwithstanding.

The cool thing is that this simple site coding will allow me to investigate various strategies on how to implement Effluency 2.0.

Quick Notes

March 28th, 2008

I had to install the 32-bit MySQL engine to replace the 64-bit engine that I had installed last week. For backwards compatibility reasons, the Ruby script launcher, /usr/bin/ruby, was built as a 32-bit application and it will not interact with the 64-bit library supplied with the 64-bit MySQL installation. Now, the Ruby interpreter itself was built as a multi-architecture bundle and had 64-bit support within, but the script launcher wasn’t. I could have recompiled /usr/bin/ruby for 64-bit operation, but I decided that I wanted to continue to move forward with Crucible and not get sidetracked getting optimal builds for my tools. That’s one of those “sweater thread yanking” conundrums that inevitably leads to a sleeve falling off somewhere.

I’m not happy running suboptimal code, but I can be productive, which is more important.

Other news: the Tewksbury SpedPAC is in the middle of a huge reorganization. It’s been months since I resigned and they still have not taken control of the tewksburyspedpac.org domain from me. To make matters worse, the latest Rails installation on the server has killed the web site completely. I should disable it completely tonight.

Rails blows. Hence, Crucible.

Why does Rails blow? I’ll leave that for another post.

Crucible: New Territory

March 24th, 2008

Thanks to the folks at Creative Eyes, I have a new System Preferences applet that can start and stop the MySQL database engine very easily. MySQL either doesn’t have one of their own or it’s buggy.

Now that MySQL is up and running, I can get back to what I was working on before the Ruby/C binding interruption, although I still haven’t tried that yet with the new laptop. Maybe later this week.

I’ve decided to work on the core of the Crucible system: user and session management.

Knowing what I know about the version of phpBB that I use for the Barscape forum, each time a user logs on, they are assigned a random 64-bit number for their session identifier. Every subsequent interaction with the forum, updates a session database with information as to where they are in the system and when they requested a page. Here are some limitations that I want to get around:

  • if a user is inactive for more than 5 minutes, the system thinks that they are now off-line
  • if you login to the system from more than one tab in a multi-tab browser, only one login session is registered

The first limitation is annoying because it is a hack to enable a half-assed auto-logout feature. Some people don’t logout to kill their sessions. They just let them hang. If the system work this way, then people would be marked as online when they weren’t. On the other hand, they aren’t actually logged off, which means that if someone in an Internet cafe did this, the next person coming along could just use their still-open session.

The second limitation I find particularly annoying b/c there are times that I want to do two different things on the site at the same time. So, I use multiple tabs. However, as there is only support for one login, the second session clobbers the first.

There is another side effect to this: personas. At Barscape, some users have multiple accounts so that they can take on multiple role-playing personas. From an administration point of view, this is difficult to maintain. Not for the current users, who are civil, but from the point of view of having to support the general on-line populace, a lot of whom are trollish. Allowing multiple accounts per user makes banning a very difficult proposition. If you ban the primary account, the user could then use an auxiliary account to wreak havoc in the system.

Typing multiple personas to individual accounts would alleviate this administration headache, but without multiple login support these personas could not be used simultaneously.

Here is how I want the user/session system to work:

  1. Users that log in to the system get a unique and random 64-bit session key.
  2. Each login creates a new session. Session keys are tied to individual browser/tab views.
  3. During a session, a user can select which persona is active. This can be done on a session basis or a per-post basis.
  4. Users which interact with the system also have their session information updated.
  5. Every 4½ minutes, or 30 seconds before some account timeout triggers, a “ping” is sent to the server to tell the session manager that the user’s browser tab is still active. (People read/write fiction at Barscape. Reading and writing takes time.)
  6. User session states will have three states: offline, online and inactive.
  7. Session can be active, stale and expired:
    • Active sessions are those in which a user is interacting with the system
    • Stale sessions are those in which a user has successfully “pinged” the system 3 times.
    • Expired sessions are those in which there are no interactions and no pinging taking place.
  8. Stale sessions will require the user to re-enter their password to continue.
  9. Expired session will require a re-login.
  10. Users will be able to “lock” their sessions, requiring them to re-enter their password to continue.
  11. Crucible will feature an invitation-only system in lieu of open registrations. Anyone who wants to join can submit a request if they don’t know anyone.

Dynamic Libraries and Timing

March 22nd, 2008

I was able to build Mac OS X dynamic libraries last night. I built my Tools and Compression code and was able to run them successfully. I also built them as 64-bit code and it all worked swimmingly. I do need to tweak my hand-built porting tools, but now I have a better knowledge how things are done on Mac OS X.

I was also able to build and test the SFMT code that I’d been working on earlier. The test programs supplied with the code were able to give me more accurate results than what I could get on Windows.

For example, the SFMT test code could be built “standard” or could take advantage of the SSE2 vector instructions of the Intel chips. When I built two versions under Windows, the time to generate 100,000,000 random integers was around 230ms no matter what I did. Knowing that the code was going through two different code paths, I began to suspect that the time measurements weren’t accurate.

When I built the two versions under Mac OS X, the standard build took 837ms. The SSE2 build took 78ms. Seventy eight! That’s f’ing fast, and just the speed I want to have on the back end of a web services engine.

The next items on my Crucible list are to tweak my build scripts to better support cross-platform development, build my sfmt library and run comparisions between the pure Ruby SFMT and get back to the Ruby/C sfmt binding library.

Crucible Forges Ahead

March 21st, 2008

It took a bit of poking around today, but I was able to build a test web site on my MacBook. The key turned out to be faulty file and directory permissions throughout the directory tree. That and some Apache server configurations got in my way. Once I got past those hurdles, it was smooth sailing.

One of the tricky parts is that I am configuring the directory tree using .htaccess files. Now, I have total control over my MacBook and the main Apache server configuration file, but I don’t have access to it on DreamHost, my web services provider. Therefore, I need to build/test the proper configurations as if I didn’t have complete machine access. However, I did have to tweak a couple of the primary configurations. First off, I needed to build, install and load the mod_ruby plugin. DreamHost does this currently. The other was that I needed to AllowOverrides for my ~user web site, which is where I’m building the site. The out-of-box configuration had set this to None, which completely ignored my .htaccess files. Again, DreamHost sets this to All or somesuch, so this is something I could do w/o affecting the viability of my testbed.

Now that I’m back to where I was before buying the MacBook, I can forge ahead with development. Minus the Windows headaches.