Let’s guess the trend of IT Tech in the next decade. Part.1

Preface

I supposed to write this blog post by the end of the last year, but it was delayed.

These words are just IMHO. And you’ve already been familiar with these words.

XML

About 10 years ago, XML is considered to be one of top 10 technologies that most programmers should master. Today XML is still the most important basis for cross-platform/language/system/blahblah message exchange/interpret. Meanwhile, JSON is becoming more and more popular in Web age for its lightweight. But in enterprise domain and business critical scenarios, XML related technologies provide these feature: flexible (better than JSON), open, robust (better than JSON) and compressible. (one important example: Office Open XML format .aka. ECMA-376, it’s continue evolving along with Microsoft Office products in these years)

Parallel

I’m not talking about cloud. I’m talking about desktop parallel computing. With more and more multiple core CPUs are filling the market, the old programming style will be changed a bit.

The change will involve new compiler, new library (OpenMP for C/C++, .NET FX 4, etc), new language (someone may mention Erlang), and the most important, new programming model or thinking.

Managed

Managed languages like C# and Java will eat more market share from traditional ones. In the next ten years, we may see Native IL support CPU or its work-like-a-product prototype say hi to the world.

Script languages will get benefits from technologies like DLR from .NET. We have seen JPython/IronPython, JRuby/IronRuby, Groovy/PowerShell (well, this pair are not so suitable to compare), and we’ll see more.

Mobile

Netbook? UMPC? PDA Phone? We’ll enjoy a mobile life. From the next generation mobile, we may get more affordable next generation mobile data fee(beyond 3G, LTE), much fast dl/up speed, better signal coverage.

Designers and manufacturers will produce more powerful mobile device, and the meaning of “mobile” will be extended to many devices. More scenes in SF novel/movie will come true.

At the same time, IT system will be more friendly to mobile device. For example, better support for small screen, one hand operation, reader mode, etc.

Universal

I’m talking about OS. We’ll have more choice when choosing OS, Windows, Linux, Mac, BSD…. but they will talk to each other much more smoothly. With Microsoft’s open promise on interoperability, other OS and products can talk to one of the biggest market share holders’ products. People can see their different desktop/server can talk to each other more happily than before.

It’s a bit late (1:26AM, GMT+8), Ill try to finish the list in recent days and post it as Part.2

idle bot

#define WIN32_LEAN_AND_MEAN

#include

#include

#include

#include

DWORD GenerateSleepMilliseconds()
{
unsigned int range_min = 560; // 5 minutes
unsigned int range_max = 8
60; // 8 minutes
DWORD u = (DWORD)(((double)rand() / (RAND_MAX + 1) (range_max - range_min) + range_min)1000);
return u;
}

int main(int argc, TCHAR * argv[])
{
DWORD sleepms = 0;
HWND handle = FindWindow(NULL, TEXT(“魔兽世界”));
if (handle == NULL)
{
return 1;
}

srand( (unsigned)time( NULL ) );

while (true)
{
    SendMessage(handle, WM_KEYDOWN,VK_SPACE, 0);
    SendMessage(handle, WM_KEYUP, VK_SPACE, 0);
    sleepms = GenerateSleepMilliseconds();
    printf_s("Sleep %d milliseconds.\n", sleepms);
    Sleep(sleepms);
}

}

A Wordpress broken link helper

Just an example.

For wordpress ppl who changed their perm link.

postmeta, $wpdb->posts WHERE ID=post_id “.
“AND YEAR(post_date) = $year AND MONTH(post_date) = $month AND DAYOFMONTH(post_date) = $mday “.
“AND post_name = \”$post_name\” LIMIT 1”;

$id = (int)$wpdb->get_var($query);
$link = get_permalink($id);
if ($link) wp_redirect($link, '301'); // Permanent redirect

$query = "SELECT ID FROM $wpdb->posts WHERE ".
    "YEAR(post_date) = $year AND MONTH(post_date) = $month AND DAYOFMONTH(post_date) = $mday ".
    "AND post_name = \"$post_name\" LIMIT 1";
$id = (int)$wpdb->get_var($query);
$link = get_permalink($id);
    if ($link) wp_redirect($link, '301'); // Permanent redirect

$link = "/$year/$month/$mday/";

if (strstr($_SERVER["HTTP_USER_AGENT"], "Mozilla") === FALSE) // if it's not a user
{
    wp_redirect($link, '302');
}

?>

The permant link changes, however broken link helper can’t solve it automaticlly, it will redirect you to the date archive page. It would be nice if you can report broken links to feuvan#feuvan.net.

Corresponding nginx configuration block:


server {
listen 80;
server_name blog.feuvan.net;

root /home/feuvan/wwwdata/blog;
index index.php;
if (-e $request_filename) {
break;
}

rewrite ^/index.php/(.+)$ /index.php?q=$1 last;
rewrite “^/([0-9]{4})/([0-9]{2})/([0-9]{2})/([^\d].|\d+[.^-]).html” /brokenlinkhelper.php last;
#rewrite ^/(.+)$ /index.php?q=$1 last;
rewrite ^/ /index.php last;

location ~ .php$ {
fastcgi_pass unix:/tmp/php.sock;
}
}

Hope it helps.

2009: A dynamic future of C#

70s coders learn C, Pascal, COBOL(one of the best IT jobs in economic crisis)
80s coders learn C
90s coders learn C++, Java, Delphi
21-century (long time no see this hot word during 1999-2001) coders learn C#?

  • A homemade rumor by anonymous craven

On PDC 2008, Anders, former architecture of Turbo Pascal, Delphi, Visual J++, currently the father of C#, gives us a presentation “The Future of C#” about what new features C# 4.0 will have. The demo “Compiler as a service” is really cool. Think about the prompt “C# >”.

Mads Torgersen, C# Language PM gives a public released document on C# Future site, describes four main new features:



>
> ##### Dynamic lookup
>
>
Dynamic lookup allows you to write method, operator and indexer calls, property and field accesses, and even object invocations which bypass the C# static type checking and instead gets resolved at runtime.

>
> ##### Named and optional parameters
>
>
Parameters in C# can now be specified as optional by providing a default value for them in a member declaration. When the member is invoked, optional arguments can be omitted. Furthermore, any argument can be passed by parameter name instead of position.

>
> ##### COM specific interop features
>
>
Dynamic lookup as well as named and optional parameters both help making programming against COM less painful than today. On top of that, however, we are adding a number of other small features that further improve the interop experience.

>
> ##### Variance
>
>
It used to be that an IEnumerable wasn’t an IEnumerable. Now it is – C# embraces type safe “co-and contravariance” and common BCL types are updated to take advantage of that.

My comments:


features
benefit
side effect















Dynamic lookup
dynamic (runtime type detection) versus var (compile time type inference) introduced in C#3.0.
No handwritten reflection codes any more.
No IntelliSense when programming.
Difficult to defend unknown runtime exceptions, errors.
Named and optional parameters
ease function call of COM interop like VSTO, etc.
Named parameters looks Pythonic. But maybe Jim like this?
COM specific interop features
based on previous two new features, it’s easier.
The biggest benefit: no runtime PIA more!
N/A? Time to migrate old workaround code.
Variance
more friendly
as above.

These new features certainly relies on new .NET framework. At least, dynamic is not a language sugar like var.

Overall, C# is becoming more and more free-style language, combined compile-time and run-time power. It’s worthy to take a look at what C# will be if you are a C# developer or even a Java, C++ lover. Write less, do more. That’s the best value of the C# evolution, IMO.