10Oct

Who’s Suing Whom In The Telecoms Trade?

I just came into this graph and I was speachless....

 

whos_suing_whom

Posted in Personal

29Sep

Hadith Of The Day RSS Service

About

With this service you get Hadith Nabawy on daily basis using RSS feed, The hadiths are taken from http://hadith.al-islam.com/ randomly and it includes sanad and maten and also it links to the original hadith n the website.

 

History And Credits

This was a compination of ideas of some brothers including:

  1. Firas Kamal.
  2. Abdelmonam Kouka
  3. And me :)

Status

This is the initial release and it has support to Arabic Hadith only, but a future plan is to have all languages available on http://hadith.al-islam.com/ supported.

 

How To Use It

  1. You can browse it online from 
    1. Sabily.org - The RSS Link
    2. my website - The RSS Link
  2. You Can use Mail clients Feed readers (i.e. outlook, evolution and thunderbird).
  3. You can have it on your desktop (using Yahoo desktop gadgets, Google Desktop, Screenlets, Apple Rss Reader ).
  4. You can have published on your blog or website dynamically.

Posted in Personal

29Sep

Logging with OSGi and knopflerfish

In the previous post Getting started We had prepared our Target platform to run on Equinox and tested it, also we noticed that the logging is not working so today we will configure it on both Equinox and Knopflerfish which is my favourite as it has a very easy to use GUI, which enables developers to easily work with it :)

Now log4j.properties is a resources file like any other resources, the thing is in an OSGi environment you can not inject resources unless you used a fragment to do so. a Fragment is an empty project that has it is own META-INF directory that contains a MANIFEST.MF file to configure the fragment. now we have two options to make a fragment either we do it without a src folder just resources directly or we do make an src folder and put resources in it, now some would say that we don’t need the src folder as we are not going to write any code in the fragment, while this is true you need to know the fact that adding a fragment without src folder will work as expected on Equinox but it wont on knopflerfish, on the other hand making the fragment with src folder that contains the resources will be picked in the expected way by both Equinox and knopflerfish(please note that am not working on felix not yet, but I’ll update this info when I test it).

to sum it up we are going to make a fragment that will deliver resources data for a bundle(in our case it is a log4j.properties to org.apache.log4j),  and we are going to make sure that this bundle will be working correctly on both Equinox and Knopflerfish. So lets get started!

  • We will make a Fragment project, go to:

File –> New –> Other –> Plug-in Development –> Fragment Project

fragment

I will call it Log4jConfig , keep the create a java project checked as deiscussed erlier and change the Target Platform to an OSGi framework and choose Equinox!

log4jconfig

now we will configure our fragment as shown in the following pic! and note that we can only add one host for each fragment, I have chosen “org.springframework.osgi.log4j.osgi” now click finish.

screenshot-new-fragment-project

Now in the src folder make a new file and call it log4j.properties, I have configured one log4j. your workspace should looks like this:

log4jproject

If you take a look at our target folder you will see that we have two bundles provides log4j “org.springframework.osgi.log4j.osgi” and “com.springsource.org.apache.log4j” and both of them exports the “org.apache.log4j” which will make a conflict when trying to run the project! to solve this we need to deactivate the second one as our fragment is already hosted by “org.springframework.osgi.log4j.osgi”, to do that go to run configurations and un select the the “com.springsource.org.apache.log4j” from the target platform.

run

click run and you should see logging on your console!

logging

now we need to test on knopflerfish:

  • To deploy the log4jConfig fragment right click on it and click Export:

plug-in Development –> Deployable plug-ins and fragments

and click next and in the directory choose the OSGi-Target project root. and click finish.

screenshot-export-1

Refresh you OSGi-Target and you will find a new folder called plugins containing a JAR file called log4jConfig_1.0.0.jar

exported

now open Knopflerfish and follow the instructions:

  • add the log4jConfig_1.0.0.jar to it by

File –> Open bundle from file

  • make sure that it is status is installed not resolved. (if it is resolved click on the refresh button).
  • as in first step add the following bundles from our target folder:
  1. aopalliance-1.0.jar
  2. com.springsource.org.aopalliance-1.0.0.jar
  3. com.springsource.org.apache.commons.logging-1.1.1.jar
  4. commons-logging-1.1.1.jar
  5. log4j.osgi-1.2.15-SNAPSHOT.jar
  6. spring-aop-2.5.5.jar
  7. spring-beans-2.5.5.jar
  8. spring-context-2.5.5.jar
  9. spring-context-support-2.5.5.jar
  10. spring-core-2.5.5.jar
  11. spring-osgi-annotation-1.1.0.jar
  12. spring-osgi-core-1.1.0.jar
  13. spring-osgi-extender-1.1.0.jar
  14. spring-osgi-io-1.1.0.jar
  15. spring-osgi-mock-1.1.0.jar
  • start them all and make sure to leave the “spring-osgi-extender-1.1.0.jar” to the end (last one to start). you should see the logging on the Knopflerfish console:
  • If you want to turn off Knopflerfish make sure to stop “spring-osgi-extender-1.1.0.jar” as if you don’t when you start Knopflerfish next time logging wont work! because the status of the log4jConfig_1.0.0.jar will be resolved and not installed.

screenshot-knopflerfish-osgi-desktop-knopflerfish

Posted in JAVA

29Sep

Spring DM-OSGi Getting started

Am using STS as an IDE which is basically eclipse but preloaded with plugins to fit this kinda job! So I’ll be talking about it (every thing should work just fine on any other eclipse). To day I’ll talk on how to prepare the environment to start an Spring DM-OSGi project. we will start with creating a target-platform for the project, which means the set of jars that will be the backbone to run my project.

  • Open your IDE and make a new project by going to

File –> New –> Project…

new-project

we will use a plain project for the target-platform name it OSGi-Target and click finish.

osgi-target

  • Now we will extract the OSGi-Target JARs using Maven (a quick maven tutorial can be found here) I have prepared my pom file and you have to make sure to change the following tag with your own value:

<taget-platform.root>
/home/fadi/Programs/STS/workSpaces/OSGi-Series/OSGi-Target/target
</taget-platform.root>

create a new folder on the project and call it target

target-hir

Am using m2eclipse plugin for maven integration. to run the file Right click on the file:

Run as –> maven build…

in the goals field make sure to right package

screenshot-external-tools-configurations

Click run and maven will download and prepare your target folder you should see something like the following if every thing goes fine!

maven-build

Now refresh your target folder and you should see the newly installed JARs!

Now we need to make sure that STS/eclipse will run this platform when we make our first bundle!

  • Go to :

Window –> Preferences –> Plug-in Development –> Target Platform

change the location to match your target folder that you made earlier…

screenshot-preferences

click reload and you will see the 22 JARs in your target folder being displayed.

  • We can test our platform now by going to Run-configuration and creating new OSGi Framework, lets call it Target!

screenshot-run-configurations

click run and you will see that you have a warning on the console says that you don’t have a logging appenders declared(this is what we are going to fix in the next post), we can check our work by typing on the console “ss” which will give us the status of our Target:

screenshot-java-osgi-target-pomxml-springsource-tool-suite-1

That’s it for now and next post we will configure log4j using a fragment.

This is an on going Series and I hope to find some interested people who can help me in it :)

Posted in JAVA

23Sep

Cool themes for your ubuntu GNOME desktop

I just found a project that aims to provide complete themes for gnome desktop (i.e. GDM, GTK, Metacity, Emerald, Icons and wallpaper) which are very cool :) the project is called Bisigi whatever that means!

any way there is like 10 complete sets at the moment but there is more to come :) to install on ubuntu 9.04 you need the following:

1 – Add the key for the repository

Open a terminal and do:

gpg --keyserver hkp://keyserver.ubuntu.com:11371 --recv-key 881574DE && gpg -a --export 881574DE | sudo apt-key add -

2 – Add the repository

Add those lines at the end of your sources.list (always in a terminal):
sudo gedit /etc/apt/sources.list


## Thèmes du projet bisigi
deb http://ppa.launchpad.net/bisigi/ppa/ubuntu jaunty main
deb-src http://ppa.launchpad.net/bisigi/ppa/ubuntu jaunty main


3 - Install Themes

Then open a terminal and do: (this command install all themes. If you want to install only one theme, go look here)
sudo aptitude update
sudo aptitude install zgegblog-themes
or click on apt://zgegblog-themes


showtimebalanzan-binfinity-b wild-shineexotictropical bamboo zenstep-into-freedomsunrise aquadreams

Posted in Ubuntu

28Jan

Manarat: the code name of Sabily 10.04

Assalamo alaykom,

Sabily team is proud to announce the code name of Sabily 10.04: Manarat

Manarat is the plural of the Arabic word Manara which mean in English and other languages Minaret:

http://en.wikipedia.org/wiki/Minaret

Welcome Sabily Manarat :)

Manarat

Posted in Ubuntu