Pages

Friday, March 18, 2011

Mercurial with IIS and Active Directory

Here is a 4-part series that explains how to set up Mercurial on IIS, using Active Directory for authentication and authorization:

http://www.endswithsaurus.com/2010/05/setting-up-and-configuring-mercurial-in.html

After implementing the security with IIS/AD and Mercurial, Keyring extension can be enabled in TortoiseHg so that you do not have to type in username/password combination every time a request is made to the server. Aside from enabling the extension, add something like this to your repository settings:

[ui]

username = your_username

 

[extensions]

mercurial_keyring =

[auth]

default.schemes = http https

default.prefix = your_serwver.local/path_to_hg

default.username = your_username

 

In [auth] section, "default" refers to the name of the remote repository which is, in this case, default.

Thursday, March 17, 2011

Free IT (and Development) Books

A reminder about a very useful collection of free IT-related ebooks at Devx.com:

http://www.devx.com/ebook

Covering topics like latest technologies (cloud), software development, IT management, security, ITIL etc. A few useful guides I've used for reference in everyday work like

  • Breaking down software development roles

Tuesday, March 01, 2011

Richness of Communications Channel

I often refer to this graph when talking about different media and communications channels. It is an important one in many different aspects. Here is the link to the whole article, and the chart is below. Originally, it appears in many texts about Scrum and Agile practices.

Monday, February 28, 2011

Running SpecFlow Tests

We are setting up SpecFlow tests, in a BDD approach, before generating the code to satisfy the user stories (features and scenarios). Data layer is generated with Sharp Architecture.

The first error that pops out when trying to run the tests is

 ----> NHibernate.HibernateException : Could not create the driver from NHibernate.Driver.SQLite20Driver.

  ----> System.Reflection.TargetInvocationException : Exception has been thrown by the target of an invocation.

  ----> System.IO.FileLoadException : Mixed mode assembly is built against version 'v2.0.50727' of the runtime and cannot be loaded in the 4.0 runtime without additional configuration information.

   at FluentNHibernate.Cfg.FluentConfiguration.BuildSessionFactory()

To sort this out, check this linked article. Adding those few lines to your nunit-console application configuration file does the trick.

After this, see here how to set up running SpecFlow tests from Visual Studio and automatically generating the report.

Thursday, February 24, 2011

Import DDL Types for SQL Server 2008 into Enterprise Architect

While not difficult, adding new DDL types into Enterprise Architect is not quite straightforward. I needed SQL 2008 types added separate to existing SQL 2000 and (later imported) 2005.

The Data Modeling page (link) on Sparx site states that the DDL types can be downloaded from the Resources page. Head there and, under Data Modeling Data Types, download the XML file for SQL 2008 (or click directly here).

Once you download the XML file, go to Tools -> Import Reference Data in the Enterprise Architect. Select the downloaded file, then select the name in the list that appears later and click Import. That should be all there is.

Now, when adding a new table in the Data Model, SQL 2008 is available as a DB type, together with all the DDL types.

Wednesday, February 23, 2011

Redmine & Backlogs - "Updated by {{author}} {{age}} ago"

I just installed Redmine Backlogs plugin in order to display the burndown chart for issues in Redmine. However, the issue pages started showing "Updated by {{author}} {{age}} ago", as well as other template keys instead of real values.

Thanks to a discussion at 

http://www.redmine.org/boards/2/topics/11000

the solution seems to be some incompatibility in i18n gem for Ruby. The solution is to remove 0.5.0 of i18n package and install an older one. Here is the post that helped:

"I had a similar issue after installing a plugin that required the i18n gem which resulted in my unintentionally upgrading i18n to 0.5.0. When I rolled back to i18n 0.4.1 it solved the issue for me. Here were the commands I used:

gem install --no-rdoc --no-ri i18n -v 0.4.1

In order to make sure I had 0.4.1 available on my system, and then:

gem uninstall i18n

And then select the newer version of i18n that it is necessary to get rid of (in my case it was i18n 0.5.0), then restart Redmine.

I can't guarantee this is going to help, but in my case it did."

Sunday, January 30, 2011

Scrum Tuning, Presentation

A great presentation on Scrum by Jeff Sutherland, Ph.D, held at Google on December 7, 2006.

http://video.google.com/videoplay?docid=8795214308797356840#

Friday, January 28, 2011

Battery Tips for Android

Having had a great battery life with my phone initially and then dropping to less-than-a-day battery life, I spent some time reading the advice and trying some of that out. I have to admit that having a very good battery life initially happened because I had immediately disabled all the Location and Network functions after I got the phone. I did not have data on my plan so I did not need the networking. Also, there was not too many applications nor widgets installed and active.
After adding a whole bunch of applications (and, the worst of all - a whole bunch of task managers that are real battery vampires) and adding the data plan, the battery on my phone lasted only a few hours. The main reason for this was identified in being LauncherPro. With having that as my default home, the battery would be drained in a matter of a few hours. I noticed the system also got terribly slow. Applications would crash and the performance was just a pain. I haven't figured out where the conflict was - whether it was some of the widgets or background services - but removing LauncherPro and bringing back the default (Tw) launcher and home screen seemed to bring things back to (the new) normal.
Then I monitored the CPU and battery usage and haven't really found any further good suspects to eliminate. However, here are some tips that make sense to me, in general, so I added them to my phone practice:
  • Set the screen brightness to minimum. Possibly, use widget as a switch between brightness off (indoors) and auto brightness (outdoors). Widgetsoid's slider shows the actual percentage amount while the default slider for brightness does not. I found out my brightness was at 7% instead of 1% so I finally managed to set it to minimum.
  • Use Autostarts to actually disable startup items rather than kill them after they are started.
  • Remove widgets that consume CPU but are not absolutely necessary. I used to use widgets as mere shortcuts to the full application so replacing the widgets with actual shortcuts helps. Found Widgetsoid, a great widget app that consumes very little CPU/battery and allows access to most options I need.
  • If using Launcher Pro, do not use updating icons (Gmail mail count, SMS count, etc.). I decided to switch back to the default TwLauncher for peace of mind.
  • If disabling location finding via GPS, you might as well disable the same using cellular network.
  • DO NOT use task killers unless you really need to. There are several wonderful applications that will display the CPU usage and even monitor it over time (I recommend Usage Timelines, SystemPanel, & Android System Info). Use this for a period to identify hogs and eliminate them. Then stop monitoring and leave the application management to Android. That's why it's there.
    Note: If you keep killing apps, they tend to get started by certain events. There is an app that can show you all the event hooks in the system (I think it is Austostarts that does this, as well). So, you save battery by not killing those apps.
  • Uninstall the applications you are not using but that keep starting themselves every now and then. Different events will trigger different applications so, if you don't need them, the best option is to uninstall. Keep the apk package handy if you ever need them later.
In regards to network, my preference is to turn the network on only when I need it. Usually by using widgets to start the 3G connection and auto-sync. Then I let the apps update whatever they need to and/or use the Internet and then disconnect when I'm done. Also disable background network traffic as I hope applications will understand this and not send network request when network is offline. Still need to monitor usage for a bit longer to confirm how this affects battery life.
Edit: Although I disconnect 3G when not using it, I don't go into trouble of disabling the whole background communication. Things seem to work well. One observation I'd make is that it would be good to uninstall the applications that are not really used as there tends to be a lot of services and applications running in the background and, sooner or later, they *do* consume power and CPU cycles because they *are* checking and doing something. Monitoring the CPU usage displays that clearly.
Edit, 2011-01-28: After applying these tips, my phone has been alive and well on a single battery charge for 5 days and 5 hours and the battery is still at 15%. I have used it as I would normally - phone calls (over 42 minutes), taking photos, uploading to Facebook, checking emails in the morning and sometimes during the day, checking the web site for train schedule, checking GPS location, browsing online maps, missed calls, SMS messages, etc.
I still use widgets for 3G traffic, calendar, todo list, Financisto, and 8 Widgetsoid switches and indicators.
After finding how to rearrange icons in the application launcher, I started utilizing application shortcuts instead of numerous widgets for running the apps. Some of the apps I'm actively using are now located on the first two screens of the app launcher and others are accessible by tapping the widgets.
There is over 250 applications installed on the phone. It takes eternity just to list them. Use Android System Info for checking installed packages, uninstalling, etc.
2G network is being disabled overnight with Tasker and turned back on in the morning. The phone is also being used as a wake-up alarm in the morning with Alarm Clock Plus.
Before this session, I've depleted the battery completely and then recharged fully without turning the phone on in the meantime.
And, at the end, the phone is Samsung Galaxy S. :)
Edit 2011-01-30: The battery made it to 7 full days!

Update: Check out related post - Zeam Launcher improves battery life on Android.

Tuesday, January 18, 2011

VoIP Test Call

Just did the first proper SIP phone call from the Galaxy S to test out the quality and data usage. 

The call quality was pretty decent on my end. I could hear the other side well in duplex mode, there was no echo, and the whole experience was quite pleasant. There were initial quirks on the very beginning after the connection has been established but that went away after about ten seconds or so.

For the other side, the quality of connection was not as good as it was for me. They could hear echo and their own voice. This really affects the conversation, at least for me. I can't stand hearing myself repeating what I just said. However, in this case the conversation went pretty smoothly.

So, CSipSimple justified the praises other people had for it. The data usage for a 13:04-minute conversation was somewhere around 6.5 MB. It is hard to say because I did not note down the actual amount of data used before the call. It was somewhere in the range of 15 MB. And, at the end of the conversation the usage was at 21.55MB. That is pretty decent usage amount. As in the data usage is negligent - about 0.5MB per minute of duplex conversation.