Oracle Java and Oracle MySQL

Ever since news broke about the surprising takeover of Sun Microsystems by Oracle Corporation, people have started discussing the future of some of the important platforms in this context. This is what I think:

The Future of Java

Oracle is not traditionally a framework platform company. Sun, on the other hand, is the creator of one of the most widely used application frameworks – Java. So what happens once this takeover is done?

  • Oracle continues innovating in Java: This is fairly possible – however may be unlikely. After all for Oracle, Java is more of a application platform that they use rather than something they contribute to.
  • Oracle kills off Java slowly: This is very unlikely as they do have something that is used by a large number in the developer community and is also a competitor to Microsoft’s .NET.
  • Oracle makes Java completely open source under the GPL*: this is something that I see as very likely. Not only will they win a ton of brownie points with the FOSS folks, but to a great extent get rid of the development and maintenance overhead of keeping Java fully internal.

* Java is quite open sourced already. However as the FAQ states, there are still a bunch of things that remain to be opened.

The Future of MySQL

This is where I see more of an issue. After all, MySQL was a competitor in the same space (or at least, that’s what MySQL followers claim). So will Oracle continue to develop and support MySQL? If they do, not only will they have different “divisions” competing with each other in the same space, but also will need to provide an “official” migration path forward.

As I see it, MySQL as a “brand” will probably go away in a couple of years. Oracle will incorporate some of its features into the lower end database platforms it currently offers. Open Source “forks” of the last MySQL version to be released will come up and try to take up the place let vacant by its departure.

Others

Solaris, though now fully open source, has not really got the momentum of something like Linux. And I don’t see Oracle changing that too much. I think Oracle will downplay the Solaris significance and slowly end it mercifully. However…

Sun’s cloud computing initiative on Solaris combined with Java and the Oracle database make it a powerful stack – quite enough to compete with the Amazon and Microsoft Azure platforms.

It’ll be interesting to note the reactions from companies like IBM, HP, Microsoft and others to see what they think of this as well.


Tags: , , , ,
Categories: Development

9 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Changing Aspect Ratio for Videos

If you use a large LCD HDTV for watching movies you might come across a situation where you might see black bars around your playing video. Vertical bars (pillarboxing) or horizontal bars (letterboxing) are caused by wrong encoding of videos for the aspect ratio of your widescreen television. I was having this issue with a number of older DVDs that I ripped to watch on my HDTV. There are a few different ways to correct these.

Usually the playing device (DVD player, Media Tank, etc.) should take care of this if the encoding has least anamorphic encoding on. If this is not there, you will not see the aspect ration getting corrected automatically.

You can try and re-encode the video using Super or AutoMKV to the correct aspect ratio. This will require a while in case you have a number of videos to correct but will give the best possible conversion.

The third way is probably the easiest – at least when it comes to converting Divx videos. There is a small utility called MPEG4 Modifier that you can download. This utility changes the AVI header to match the widescreen format that you wish. Take a look at the screen below:

mpeg4modifier  Simply select the Display AR to 16:9 and save

The important thing to remember is to change the DISPLAY ASPECT RATIO and not the PIXEL ASPECT RATIO for the conversion. The PAR changes the aspect ratio of the pixels comprising the video whereas the DAR only changes the header so that the video can be auto-sized in the player.

If you wish to convert a bunch of files, there is a command line version of the application as well available from the same link as above. However, there is one difference between the GUI and console version. The latter doesn’t have an option to modify the DAR, only the PAR.

Since source code is available for both, I downloaded the one for the console app and added the calculations required to use DAR from the GUI version of the app. I take NO credit for any of these calculations – all of it goes to the original author of the program. The program is now compiled in .NET 3.5SP1 for x64. You can now convert an AVI file from the command line like this:

mmcl.exe –-dar 16:9 in.avi out.avi

Simply run the console app to see the different options. You can download the binaries and source code below:

MPEG4 Modifier Console: Source x64 x32 (coming soon)


Tags: , , ,
Categories: Development | Movies | Tips

7 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Managed Win7 Taskbar Enhancements

Windows 7 has a ton of new enhancements right there in the Taskbar itself. A quick list of them includes:

  • Unified Launching and Switching
  • Jump Lists
  • Destinations
  • Tasks
  • Thumbnail Toolbars
  • Icon Overlays
  • Progress Bars
  • Notification Area
  • Interactive Thumbnails

Your applications too can start using these features’ in them if you want. The documentation for these are available at MSDN here. The only issue is that this is currently possible only with un-managed APIs – COM & Win32.

So what happens if you’re a .NET WinForms/WPF developer and want these features in your applications as well? Well, fear not there is a way out. There are two open source projects that allow you to use the Win7 taskbar enhancements in your managed code applications as well.

The first is a project on CodePlex called Windows 7 TaskBar Extensions. This is a new project with only a few things currently implemented but seems to be heading in the right direction for a small, lean implementation of the Taskbar features in .NET.

The second is a much more comprehensive project called very simply “Windows 7 Taskbar”. This is based upon the excellent Vista Bridge library and offers all the features that are currently possible. There are a number of sample applications as well that demonstrate many of the different features. The only part that didn’t work for me is creating Jump Lists.

So if you’re a Windows application developer and want to add the new features of Vista and Windows 7 into your application, Vista Bridge and these other two libraries are surely something that you will want to try out.


Tags: , , ,
Categories: Windows 7 | Rave | Development | Windows Vista

6 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Writing FOSS During the Recession

A few months back I had written a post on how FOSS might suffer during the period of recession. My point was that FOSS depends on contributions – whether in terms of actual donations of resources mostly on their free time (code, writing, design, etc.)  or in terms of money. However in this time of extreme recession the world over, contributors will probably have much more important things to do.

  • If a contributor (developer, technical writer, designer) already has a job, he/she is probably going to work twice as hard to keep that job – maybe working extra time and taking on more responsibilities – reducing time to contribute to FOSS.
  • If a contributor is out of a job (whether out of college or been laid off), he/she is going to be busy making ends meet and looking for other employment. In such a case, contributing to FOSS is probably going to be last thing on their mind.

Now, it seems that others are thinking the same – including A Sr. VP of Novell and ex-CTO of the Linux Foundation, Markus Rex. In an interview recently said exactly the same thing.

Q: What are the challenges you see for the business moving forward?

I perceive a challenge always as an opportunity. It gives us the opportunity to change to a better way from the way things have been done in the past.

The other thing is in both Europe and the US the rise of the unemployment rate is something that is rather unprecedented. The open source community to a certain degree is dependant on the willingness of people to contribute. We see no indication that anything might change there, but who knows? People need something to live off.

“Something to live off” is right. We’ve already heard about the stagnation in main stream products like OpenOffice.org. We’ll probably see more such things happen soon – a little sad I would say. A lively discussion on this is going on over at Slashdot on this topic.


Tags: ,
Categories: Linux | Development

3 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Mixed Mode Bi-Directional Transactional Replication between SQL 2000 and SQL 2008

A recent project I am involved in requires us to demonstrate a bi-directional replication setup between SQL Server 2000 and SQL Server 2008. There are a few gotchas one needs to be aware of while doing something like this.

First off, make sure that the SQL Server 2000 server has the latest service pack installed. Next, on the SQL Server 2008 server, open up the Distributor properties and add the name of the SQL Server 2000 server. Give a strong administrative link password when prompted.

Now, on the SQL Server 2000 server, configure distribution. Make sure you specify that the Distributor is running on the SQL Server 2008 server. (Note: if the server is already configured as a distributor and has a number of publications, read this MSDN article to see how it can be changed.)

Next comes an important part before you add publications from a SQL Server 2000 database to a SQL Server 2008 database. For each article (read: table) that you wish to publish on 2000 and subscribe on 2008, you need to have 3 stored procedures on the subscriber database – one each for INSERT, UPDATE and DELETE.

That is, if you have a table tbl2000 on SQL Server 2000 that needs to be published to a subscriber database called tbl2008 on SQL Server 2008, the SQL Server 2008 database needs 3 stored procedures called say, sp_ins_tbl2008, sp_upd_tbl2008 & sp_del_tbl2008. (Note: normally, the publication script can create these automatically when you give the schema_option=0x02 in the sp_addarticle procedure. But for some reason, it doesn’t seem to work across 2000 and 2008 scenarios that I tried.) These stored procedures basically insert, update and delete the records in the subscriber (on SQL2008) database.

So, to create a publication, you will need to NOT use the publication wizard that you get in SQL 2008. Instead, use a generated publication script and for each sp_addarticle line that you have in it, make sure that the @ins_cmd, @upd_cmd & @del_cmd parameters point to the appropriate stored procedures and run it on the SQL Server 2000 server. Once this is done, go ahead and create a subscription to SQL Server 2008’s database normally.

For the other side (that is, SQL Server 2008 to SQL Server 2000), normal publish-subscribe rules apply and work fine.


Tags:
Categories: SQL Server | Tips | Development

12 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Charting in ASP.NET 3.5

Microsoft recently released a new set of chart controls for Windows and Web forms for .NET 3.5 SP1. However, to install and use them in Visual Studio you need to download and install a minimum of two different downloads and an optional third.

The first one is the main update for .NET 3.5SP1 available here. If you need Visual Studio 2008 SP1 support you need to install the add-on from here. If you need the full documentation, download and extract the file from here.

Once these are setup, you can add the Chart control from the Data group in the Toolbox. Add a data source, set the series data points in the properties and you are done. Quite easy to start creating dynamic charts on your site without any expensive 3rd party solution.


Tags: , ,
Categories: ASP.NET | Development | Rave

20 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

A great time to be a Computer Science student in India

As is usual to a slightly long post, I start with a bit of historical context. In the days back when I was a student in school, computers were a fairly new thing. I was lucky to have started early on BBC Micros and having access to the Internet waaaay before most people had heard of it thanks to growing up in one of India’s premier universities. In school, our PCs, PC-XTs and PC-ATs were major drool points for us geeks.

However, software was another issue. A few of us loved programming – but access to software was fairly impossible. Getting Turbo Pascal and Turbo C++ was quite difficult and it was usually from a (friend-of-a-friend)^n from where we would (ahem) make copies to try out our pieces of code. I remember writing (literally) entire programs on sheets of paper with dry run notations on the side for each variable for each pass and then go type it out in school to try out some new stuff that I had “created”.

These days however, access to software is much easier. Unfortunately, professional quality software is usually quite expensive and for a student in India, typically out of their budget. This is where Microsoft’s recently announced DreamSpark initiative comes to their rescue.

DreamSpark allows students in India to download or get a DVD of most of the Microsoft programming and designing stack for FREE! All a student needs to do is register at the site, get their student status verified and they can get access to the free download and go and simply pick up the free DVD from any of the over 200 locations in India and start using it.

And what is it that they get for free? The list includes:

  • Windows Server 2003 Standard
  • Visual Studio 2008 Professional
  • Visual Studio 2005 Professional
  • SQL Server 2005 Developer
  • Expression Studio
  • XNA Game Studio 2.0

Remember that these are FULL versions of these products, without any restrictions (time or uses) for FREE.

This means that computer science students can now start working with professional level tools right from the start. Also, if anybody uses the “Open Source is best for learning programming” argument, this is no longer true. The Microsoft programming stack is so much more productive and now is accessible by any student in India and all for free to. I wish this was available to me when I was in school too.


Tags: ,
Categories: Development | Internet | Microsoft | Rave | SQL Server

27 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

The Economic Depression vs. FOSS

This post actually started out as a comment on a Slashdot story about how the economic downturn is going to (negatively) impact free and open source software. As expected, the comments had a ton of ayes and nays – both sides having their merits. My thoughts about this are like this:

  1. The economic downturn is going to affect everyone – including people who are passionate about writing free software. Are you single or do you have dependents (wife, kids, parents, etc.) who depend on your livelihood? In this case, would you as a developer rather work for a commercial vendor (who pays you something) or an OSS project where you are a contributor and the possible future fame (no fortune) is the only incentive? (Unless of course, you were born with a silver spoon and write code only as a passion.)
  2. If you were the owner/major stockholder of a company would you depend on a software project that’s been written in the garage of the developers or with a company which has fairly good stocks as well as a few billion dollars in liquid funds? Think about which one is more likely to close shop and disappear. Would you want to be stuck with a product running your critical LoB application which has no future?
  3. The argument that since you do have the source you can modify it is fallacious. What if you’re not a technical company? You will need to hire programmers to modify the application which can turn more expensive very quickly.
  4. What if the main argument was that it would be cheaper to get the free software than a commercial one during an economic downturn? Again, see point 2 as well as that commercial OSS projects have the same or more TCO of offerings from commercial vendors. Most commercial OSS projects are in the same price range (they call it “charging for services”) as commercial closed source ones.
  5. Commercial vendors also give a pay as you need and monthly/yearly model of software purchase. All you need to do is talk to the sales/marketing team of the vendor to avail of this – with guarantees on the software (and company – very important during this economic phase). This means that you can spread out the cost of the software over many years and still get the benefits of a solid company backing and software.
  6. People who claim that developers can continue to write code for OSS only see part of the picture. What about all those people who are not technical but yet have a whole bunch of stuff to contribute to software – QA, designers, technical writers, software packagers,etc. Will all of them also be willing to work for free/peanuts?

Although I do not foresee the end of OSS or even want it to happen, these are hard questions that not only contributors to OSS but also companies who rely upon them must think about seriously. What do you think?


Tags: ,
Categories: Development

6 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Paste-&-Go with Internet Explorer

Recently a fellow MVP, Omi, created a Firefox 3.0 extension called Paste-&-Go which allows users to copy a URL and paste it into the browser and have it open up automatically. You can download this excellent extension for Firefox here.

However, quite a few people asked for something like this in Internet Explorer. and I was surprised that many people are not really aware of the cool extensibility features of Internet Explorer called IE Browser Extensions. I had written an article for PCQuest quite a while back and also give a few “extensions” for IE for download at its forums. You can download a small set from here.

Sadly this above set does not really support pasting URLs from an external source – such as Notepad. Also, the Firefox extension only allows a single URL, while I wanted to do it for multiple URLs and open all of them up instantly. I posted on the MVP alias that I’d probably get around to writing the code during the upcoming Dussera holidays.

But I did manage getting 5 minutes free (while my son watched Disney’s Chip-‘n’-Dale) and that’s basically how much time it took to go ahead and create a browser extension for Internet Explorer that does the above. You can set this up yourself too on Internet Explorer 5 or above (including the IE8 Beta 2).

  • Open Notepad and paste the following code into it.Save the file as as HTML file, say, c:\Windows\Web\Paste-n-Go.htm
<HTML>
<SCRIPT LANGUAGE="JavaScript" defer>
clip = window.clipboardData.getData("Text"); 
UrlArray = clip.split("\n");
for(i=0; i<=UrlArray.length; i++)
    window.open(UrlArray[i], "paste"+i);
</SCRIPT>
</HTML>
  • Open Regedit and browse over to HKCU\Software\Microsoft\Internet Explorer\MenuExt
  • Right-click the MenuExt key and select New > Key
  • Rename the newly created key to Paste && Go
  • Double click the (Default) entry on the right pane for this new key and set the value to the location where you saved the file you created in step 1, say, c:\windows\web\Paste-n-Go.htm
  • Right-click the right pane and create a new DWORD (32-bit) value
  • Rename the new key to Contexts and set its value to 1. Your registry should look something like this now.

image

  • Copy a bunch of URLs from Notepad or another browser window

image

  • Open a new Internet Explorer window and right-click anywhere in the content area and pick Paste & Go from the context menu

image

  • This will open the URLs you copied in a window each – quite handy when trying copy a bunch of URLs someone has linked to in a forum post or a list that you have

Currently this doesn’t open the URLs in different tabs – haven’t figured that one out yet. If you know how, do leave me a note and I’ll make the required change.


Tags: , ,
Categories: Development | Tips

6 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed

Saving Changes in Table Design in SQL Server 2008

One of the new things that happens in SQL Server 2008 is that it prevents saving table structure changes that require the table to be dropped and re-created. While this is a great feature to prevent accidents from occurring, on a developer machine it can be quite frustrating. This is the dialog you get when trying to make changes in a table design.

image

Unfortunately, this dialog doesn’t tell you where to turn this feature off! Clicking on the small “?” on the title bar does get you to a help page that tells you how to do it.

Anyway, the place to do it is Tools > Options > Designers > Table and Database Designers > Prevent saving changes that require table re-creation. Turn this option off and you will be able to save the tables again.

image


Tags: , ,
Categories: SQL Server | Tips | Development

28 Comments
Actions: E-mail | Permalink | Comment RSSRSS comment feed