PDF and PDF/A formats

The PDF format has experienced a success story on its way from being a quasi proprietary format that could only be dealt with using Adobe tools to a format that is specified and standardized and can be dealt with using open source tools and tools from different vendors. It has become accepted that PDF is primarily a print format and that for web content HTML is the better choice, which was not clear 15 years ago, when people coming from print layout who just considered themselves trivially capable of adding web to their portfolio just wanted to build whole web pages by just using PDF instead of HTML.

Now the format did change over time and there are always PDF files that use specific features that do not work in certain PDF viewers.

But there are requirements for maintaining documents over a long period of time. Just consider long term contracts that have a duration of 50-100 years. The associated documents usually need to be retained for that duration plus ten years. Alone the issue of storing data for such a long time and being able to read it physically is a challenge, but assuming that this issue is addressed and files can still be read in 110 years, the file format should be readable.

Now companies disappear. A lot of them in 100 years, probably even big ones like Adobe, Apple, Microsoft, Oracle and others. We do not know which companies will disappear, only that it is very likely that some companies that are big now will disappear. Proprietary software may make it to another vendor when shutting down the company, to pay the salaries of the former employees for some more days. But it might eventually disappear as well. Open source software has a better chance of being available in 100 years, but that cannot be absolutely guaranteed either, unless special attention is given to that software over such a long time. And if software is not maintained, it is highly unlikely that it will be able to run on the platforms that are common in 100 years.

So it is good to create a stable and simplified standard for long term archiving. Software for accessing that can be written from scratch based on that specification. And it is more likely to remain available, if continuous need for it can be seen.

The idea is a format called PDF/A, where A stands for „archive“, which is an option for storing PDF files over a very long period of time. Many cool features of PDF have been removed from PDF/A and make it more robust and easy to use. Important is also not to rely on additional data sources, for example for passwords of encrypted PDF files or for fonts. Encryption with password protection is a bad thing because it is quite likely that the password is gone in 100 years. Fonts need to be included, because finding them in 100 years might not be trivial. This usually means that proprietary fonts have to be avoided, unless the licensing allows inclusion of the fonts into the PDF file and unlimited reading. Including JavaScript, Video, Audio or Forms is also a bad idea. Video should be archived separately and it has the same issues as PDF for long term archiving.

Share Button

Indexing of Database Tables I (Primary Keys)

Any useful databases with non trivial amounts of data have some indexing mechanism in place that helps finding data based on some key values, because a full table scane or something like that is too expensive and too slow to do it often.

The most typical situation is having a key and one or more values behind that. This applies to relational and NoSQL databases.
Typical database access layers for programming languages like ActiveRecord for Ruby or JPA/Hibernate for Java favor the pattern of having one index column called „id“ that is numeric and gets successive values assigned when new entries are created.

This is good, because the id is always unique and it can be handled and stored efficiently, especially when being used for relationships between different tables. It is off course a good idea to think about the size of integers to use for this, so that the number range is not exhausted. Depending on the DB product this can produced automatically by the DB when inserting if the column is declared as identity column or autoincrement or something like that (MySQL, MS-SQLServer) or it can be created by using a sequence (Oracle, PostgreSQL). It could be considered to use just one global sequence instead of one per table, so the id is unique across tables, which might have some advantages, but it kind of unusual.

Another common approach is to use UUIDs instead of such numeric ids. They have the advantage of being kind of globally unique. They have 128 bits and there are two approaches for obtaining these 128 bit numbers. Some bits are used to express version and type of UUID, but most of them can be used for differentiating from other UUIDs. They can be generated using random numbers or using some identity of the current host combined with time stamp, counter and possibly thread and process numbers and filling some digits with random numbers… When having around a billion (German „Milliarde“, 10^9) entries, the probability of having a collision with a single additional randomly generated UUID is less than 10^{-27}. So the risk of being struck by a lightning is higher than the risk of getting a collision by creating the same random UUID twice, if the random number generator is really good. It is quite possible to build big systems based on that and run them for a long time without problems by duplicate UUIDs. If that is good enough or not is a philosophical question, but I prefer the other way and finding a way to generate a UUID that is unique across hosts in the current and expected future system environment. Quite honestly, I do not see the benefit of using UUIDs as ID fields and primary keys in databases, because the numeric IDs can be handled more efficiently and mechanisms of generating them uniquely are reasonably easy to implement.

It is often forgotten that data actually might contain internal unique keys that can be used. Often a autoincrement numeric ID is used as a primary key and these semantic keys are declared as unique constraint or at least with a non unique index to allow searching. This has the advantage that changing these values is possible by accessing only one table and without breaking referential consistency. But for large tables I do recommend to consider using these natural keys instead of the ID as primary key for the sake of efficiency. Serious databases can also deal with combined keys consisting of several columns that are unique only in their combination.

An obvious stupidity that I am only mentioning because I have actually seen it, is the concatenation of all the fields forming the logical primary key to some column called „HANDLE“ and using that as a primary key. A 40 year old junior developer with the authority of a senior lead architect could impose such a thing on the database of a project that I have worked in in the past and he could degrade the whole software by this, because it just wasted half of the database space and a lot of performance for a product that should have performed really well to be useful to its customers.

I would also resist the temptation to use something like oid in PostgreSQL or the ROW_ID of Oracle as key. These values can change when moving data to other table spaces or restoring a backup or even upgrading to another version of the DBMS product. They might be good for temporary use, probably within a transaction or within a set of closely related transactions occurring within a few minutes or hours.

Additional indexes are an interesting issue, which I might deal with in another article in the future.

Share Button

Microsoft laying off 18000 employees after announced loss


It looks like Stephen Elop’s und Steve Ballmer’s idea to take over the mobile phone branch of Nokia in order to bring MS-Windows as mobile operating system on the success road has failed and will be stopped now.
For the mobile phone branch that is now part of Microsoft, Microsoft-CEO Satya Nadella announced, that billions are deprecated and up to 18000 employees will be layed off. This will be more than half of the remaining former Nokia-employees, but also other parts of Microsoft will experience major lay offs. As an irony these layoffs will also include Stephen Elop.
On the other hand it looks like Nokia will get into mobile phone development again. The deal with Microsoft forbids that for a certain time, but that will end in 2016. Some expect that Jolla might be bought by Nokia in the future. Nokia will become a niche supplier, not more. The market leading position they had before Elop will not be regained and it is also unlikely that they become one of several major suppliers, which might have been a reasonable outcome without Elop. Their own production won’t come back to Finland, but will be given to the well known Asian manufacturing companies.
Such fusions and takeovers of departments always have their challenges. Company cultures tend to be incompatible and markets are used to a brand and will not easily switch to the new supplier. Taking over of Pentax by Ricoh has been relatively successful, as it seems, but in that case they have carefully worked on mainting the brand in an area where consumers are kind of sticky to their traditional brand. Microsoft did not go that road, but they deliberately changed a lot and thus lost customers who might have been loyal to the Nokia-brand. The strategy in these two takeovers was completely different.
Probably Steve Ballmer and Stephen Elop will be remembered as incapable managers for a long time, for first destroying Nokias core business and then losing billions on the takeover that was obviously the original intention behind the whole game.


Share Button

Microsoft entlässt bis zu 18000 Mitarbeiter nach Milliardenverlust


Wie es aussieht, ist die Idee von Stephen Elop und Steve Ballmer, die Mobilfunksparte von Nokia auszuschlachten und damit für MS-Windows als Mobiltelefonbetriebssystem einen Fuß in die Tür zu bekommen, nicht aufgegangen und wird jetzt gestoppt.
Für die durch Microsoft von Nokia übernommene Mobiltelefonsparte kündigte Microsoft-CEO Satya Nadella an, dass Milliarden abgeschrieben werden und dass bis zu 18000 Mitarbeiter entlassen werden sollen. Dies wird über die Hälfte der zu Microsoft gekommenen ehemaligen Nokia-Mitarbeiter betreffen und auch in anderen Teilen von Microsoft findet ein größerer Personalabbau statt. Auch Stephen Elop gehört übrigens zu den entlassenen Mitarbeitern.
Andererseits sieht es danach aus, dass Nokia wieder in die Mobiltelefon-Entwicklung einsteigen wird, zu dem Zeitpunkt, zu dem der mit Microsoft geschlossene Vertrag das erlaubt. Viele vermuten, dass irgendwann Jolla von Nokia übernommen werden könnte, wo viele ehemalige Nokia-Mitarbeiter gelandet sind und wo man für eine Nischenmarkt aussichtsreiche Ideen aufgegriffen und weiterentwickelt hat, die bei Nokia unter Stephen Elop abgebrochen wurden. Nokia wird sich als Nischenanbieter wahrscheinlich wieder einen kleinen Marktanteil sichern können, aber die Stellung als Marktführer, wie sie vor Elop bestand, oder auch nur als einer von vielen größeren Anbietern, wie sie vielleicht ohne Elop realistischerweise herausgekommen wäre, wird nicht wieder erreicht werden. Auch die eigene Produktion wird zugunsten einer Auslagerung an die üblichen ostasiatischen Elektronik-Fertiger kein Thema werden.
Problematisch bei solchen Fusionen oder Übernahmen von Abteilungen, ist dass sie oft nicht gut funktionieren, weil einerseits die Firmenkulturen verschieden sind und es so zu Reibungsverlusten kommt, die man sich in einem engen Markt nicht unbedingt leisten kann und andererseits ein Anbieter, der im Markt etabliert ist, nicht so einfach durch die übernehmende Firma ersetzt werden kann. Dafür muss man die Kunden erst einmal gewinnen und entsprechende Glaubwürdigkeit aufbauen.
Es hat ja solche Fälle gegeben, z.B. bei Kameraherstellern. Die Minolta Kamerasektion wurde von Sony übernommen und auch relativ bald aggressiv als Sony vermarktet. Sony hatte keine Glaubwürdigkeit für Kameras, außer natürlich für Video-Kameras, aber sie haben es sich mit interessanten Produkten und einer speziellen Nische erarbeitet. Für Spiegelreflexkameras hat Sony nicht den Namen wie Minolta, aber für kleine, leichte Digitalkameras, die zwischen Mobiltelefon und Spiegelreflexkamera positioniert sind, haben sie eine gute Stellung.
Pentax wurde von Ricoh übernommen, aber die Marke wird konsequent erhalten und gepflegt und noch als solche wahrgenommen. Auch da ist man nicht mehr Marktführer wie in den besten Zeiten, sondern ein stabiler Nischenanbieter, sofern man in diesem Markt so etwas überhaupt sagen kann.
Offensichtlich sind hier durch Missmanagement erst einmal viele Milliarden an Wert auf Seite von Nokia versenkt worden (und viele Mitarbeiter entlassen worden), dann ist aber die ganze Rechnung nicht aufgegangen und letztlich sind auf Microsofts Seite auch viele Milliarden versenkt worden, so viele, dass es auch in einer relativ großen Firma sichtbar und schmerzhaft ist. Steve Ballmer und Stephen Elop haben sich sicherlich ihren Ehrenplatz in der Liste der „Nieten in Nadelstreifen“ verdient.


Share Button

Conversion of ASCII-graphics to PNG or JPG

Images are usually some obscure binary files. Their most common formats, PNG, SVG, JPEG and GIF are well documented and supported by many software tools. Libraries and APIs exist for accessing these formats, but also a phantastic free interactive software like Gimp. The compression rate that can reasonably be achieved when using these format is awesome, especially when picking the right format and the right settings. Tons of good examples can be found how to manipulate these image formats in C, Java, Scala, F#, Ruby, Perl or any other popular language, often by using language bindings for Image Magick.

There is another approach worth exploring. You can use a tool called convert to just convert an image from PNG, JPG or GIF to XPM. The other direction is also possible. Now XPM is a text format, which basically represents the image in ASCII graphics. It is by the way also valid C-code, so it can be included directly in C programms and used from there, when an image needs to be hard coded into a program. It is not generally recommended to use this format, because it is terribly inefficient because it uses no compression at all, but as intermediate format for exploring additional ways for manipulating images it is of interest.
An interesting option is to create the XPM-file using ERB in Ruby and then converting it to PNG or JPG.

Share Button

System Programming on Linux and MS-Windows

Quite honestly I admit that I really love the Posix-APIs for system programming and even some Linux specific extensions to it. I/O, Locking, Semaphores, Shared Memory, Message Queues, Signals, named and anonymous pipes, Unix Domain Sockets, TCP/IP programming, Terminal I/O, pthreads and a lot more are very powerful and fun to program. I do discover some points where I regret why they have not done it better, for example the fact that almost all system calls return a value, which is interpreted in one of the following ways:

  • 0 means ok, -1 means a issue has occured, which can be explored by calling the errno-macro.
  • Values >= 0 are useful responses and -1 is indicating an error, which again requires calling errno.
  • A pointer is returned. If the pointer is NULL, this indicates an error and requires calling errno. Sometimes (void *)-1 or similar return values are also special.
  • pthreads-methods return 0 when successful or directly the error code otherwise.

Originally errno was a veriable, which had to be replaced by some weird macro construction to allow multithreading and remain backwards compatible.
I would find it most natural if there where an exception mechanism in place like in Perl, Ruby, Java and many other languages, which would transport the error information. C cannot do this, at least not without breaking the language standard. The pthreads way looks good as well. Returning a struct containg the value actually needed and the errorcode, which is 0 if everything is ok, would also be a good approach, whenever a real return value is needed, but arguable a little bit clumpsy in case of functions returning a pointer. Maybe providing a pointer to some integer variable as argument would be the way for this case, even though I find it kind of ugly to have „return values done by a parameter“. Semaphores are a little bit clumpsy to handle. And fcntl and ioctl are for sure overused instead of adding specific function for specific tasks. Reading a single character from a terminal or keyboard input without waiting for return is difficult, but at least logical.

Anyway, these issues can be dealt with and the power and elegance of the API is just great. The documentation is always available by using man pages that are installed on almost every system and by using great online resources on top of that.

So how does the win32- and win64-API look like? I mean apart from the religious questions like the lack of freedom? Most of the things can be done on the MS-Windows-APIs as well. There are some differences. First of all, all the code that uses system-APIs has to be rewritten. Very few typical POSIX-functions like open, close, read and write exist in the windows world as well to facilitate such a transition, but the general answer is like „it can be done, but the code has to be rewritten from scratch“. So programs that should run on both platforms and should do basically the same on both platforms need to encapsulate their system specific code, which might be anywhere between 20 and 50 percent of the code base, in specific files and organize their structure in such a way that the remaining half or more can actually be the same. It has been done by database products (PostgreSQL, mariaDB, Oracle, DB2), interpreters and compilers for programming languages (Ruby, Perl, Scala, Java, C#, F#, PHP), browsers (firefox, chrome), image processing software (gimp), office software (other than MS-office), web servers (apache) and many others and they do achieve the goal to be doing more or less the same on both platforms.

Now how does the Win32- and Win64-API look like? Obviously the code looks very different. Unimportant, but very visible differences are that function names are mixed case and start with capital letter instead of being smaller case with underscores. Parameters and variables are mixed case starting with lower case. The C-type system is not directly used, but all types are #defined in some header file and all capital, even pointer types. Some care is needed to understand how these types work together, because it is not as self documenting as the original C types, but really no big deal to get used to. A MS-specific C-extension does allow using some kind of exceptions, if that is good or bad is hard say. Function names are generally longer and have huge parameter lists with very long parameter names. When they are outdated, because more parameters or different behavior or 64-bit support is needed, often an 64 or an Ex is added to the original name to create a new name for the replacement function, retaining the old one as it is for backwards compatibility.

Shared memory can more or less easily be replaced by memory mapped files and that is what needs to be done on MS-Windows.

The named pipe of Windows kind of unifies the message queue, the unix domain sockets, the named pipes of Unix/Posix/Linux and even allows network communication within the local network. There have been linux specific extensions to Posix-pipes that achieve this unification, but not the network transparency, as well. Mutex and Semaphore work slightly differently, but can basically achieve the same results as Mutex and Semaphore on Posix. What is beautiful is that almost all operating system objects are accessed by so called HANDLEs which unifies many functions accessing them, but brings functions like WaitForSingleObject and WaitForMultipleObjects also some fcntl-like flavor, because it depends of course very much on the type of kernel object what waiting for it means. When being aware of this, it can be very powerful.

When looking for features that are really missing on one platform we observe immediately that MS-Windows does a mandatory locking on files by default and that such a mandatory locking does not at all exist in Posix or on Unix-like operating systems like MacOS-X, even though it does exist on Linux. Discussing this issue and how to deal with it should be worth its own article. In short, it is not as bad as it sounds, but the choice of the MS-Windows-guys to implement this feature in the way it is and to make it the default does look good.

The signals are missing on the windows side. This can be overcome by using Mutexes and Conditions to replace the communication part of signals, or to simply use HANDLEs to end a specific process instead of sending a signal, provided the permissions exist to do so.

Another painful omission is the fork. Most of the time fork is accompanied by an exec and exactly that can be doe by the CreateProcess in MS-Windows. Often we do like to share open files with the forked process and there are ways to do this, at least to some extent. But to use fork for creating a couple identical processes that run on the same code and data initialized once, which is sometimes a good idea, just does not exist on MS-Windows. It can be overcome by using threads and dealing with the issues of having to take responsibility for really separating the threads or by using multiple processes and memory mapped files for sharing that initial data structure.

The Win32- and Win64-APIs are documented quite well on some Microsoft-Webpage. I find the Linux-man pages slightly more useful, but both systems are documented in a way that it should be easy to find and use the original documentation and additional resources on the web.

Generally I would recommend all system programmers to have a look at the other world and how things work there. It helps enjoy and understand the beauty and power of both systems and probably maintain or even challenge the preference.

I have been teaching system programming for both platforms to college students and I enjoyed teaching and exploring these platforms with my students very much.

Share Button

Zukunft für IT-Freiberufler


Einige von uns arbeiten in der Informatik.
Und dort gibt es doch einige Modelle. Man kann bei der Firma, der man die Arbeit erledigt, direkt angestellt sein. Man kann als Freiberufler, also entweder mit einem speziellen Freiberufler-Status oder mit einer eigenen Ein-Personen-Firma für seinen Kunden arbeiten. Oder man kann als Angestellter einer größeren Firma für deren Kunde arbeiten. Vielleicht gibt es noch ein paar Hybridmodelle, auf die ich hier aber nicht eingehen möchte.

Ich habe alle drei Modelle kennengelernt und bevorzuge es, als Freiberufler mit meiner eigenen Firma zu arbeiten. Ich denke, dass die Menschen verschieden sind und so verschiedene Präferenzen zwischen diesen Modellen haben. Und für ein IT-Projekt ist es gut, Mitarbeiter mit verschiedenen Stärken und Erfahrungen zu haben und diese bekommt man am besten, wenn man mindestens Freiberufler und eigene festangestellte Mitarbeiter kombiniert. Diese interessieren sich in der Regel am meisten für den Erfolg des Projekts, während bei externen Mitarbeitern, die bei einer großen Firma angestellt sind, tendenziell noch eine eigene, oft nicht mit den Projektinteressen kongruente Eigendynamik des Arbeitgebers ins Spiel kommen kann, aber nicht muss. Ihr kennt sicher positive und negative Beispiele aus eigener Erfahrung: Z.B. werden in einer frühen Projektphase externe Mitarbeiter gebracht, die sehr viel können, vielleicht aber auch gute Verkäufer sind oder sich irgendwo in der Struktur des Auftraggebers etablieren. Wenn dann der große Auftrag unter Dach und Fach ist, werden überwiegend Berufsanfänger gebracht. Oder generell Personen, die eine enorme Loyalität mit ihrem Arbeitgeber mitbringen, weil das Modell, bei dem man dauernd unterwegs zu Kunden ist, bei dem dem Kunden ein hoher Stundensatz verrechnet wird und bei dem man selbst gemessen an diesem Stundensatz nur ein sehr mittelmäßiges Gehalt bekommt, nur für eine längere Zeit funktioniert, wenn diese Mitarbeiter eine sehr große Loyalität zu ihrem Arbeitgeber oder eine Scheu vor dem Risiko haben, selbst als Freiberufler oder Selbständige zu arbeiten. Genau das kann auch einmal gut sein, um ein Team mit verschiedenen Leuten zu haben, die sich gegenseitig ergänzen, wenn es das Team vielfältiger macht. Je nach Lieferant kann man bei diesem Modell auch Leute bekommen, deren technisches und fachliches Wissen sehr gut ist. Auch das habe ich gesehen und man sollte sich als Auftraggeber genau anschauen, mit wem man zusammenarbeitet, damit sowohl die Firma als auch die Leute, die tatsächlich im Projekt mitarbeiten, gut sind. Mit kleineren Firmen macht man oft bessere Erfahrungen als mit internationalen Großkonzernen, aber es gibt gute und schlechte Beispiele in allen Kombinationen. Um aber ein gutes Mischungsverhältnis von verschiedenen Charakteren zu haben, wie es dem Projekt dienlich ist, ist es gut, bei den „externen“ Mitarbeitern mindestens teilweise auch auf Freiberufler zu setzen, die selbständig arbeiten und nicht bloß Kapazitätsplanung und Checklisten für Qualifikationen anzuschauen.

Eine gute Mischung aus internen und externen Mitarbeitern, gerne auch mit einer großen Mehrheit von „internen“, ist auch für ein Projekt vorteilhaft, weil es einerseits die Flexibilität gibt, die Teamgröße zu variieren, ohne Entlassungen vornehmen zu müssen. Es sollte auch für die Loyalität der internen Mitarbeiter förderlich sein, wenn Entlassungen eher die Ausnahme als die Regel sind. So wie interne Mitarbeiter die Strukturen, Anforderungen, Kunden, IT-Systeme und die verwendeten Werkzeuge über die Jahre sehr gut kennengelernt haben, ist es auch gut, dass „externe“ relative viele Firmen von innen gesehen haben und vielleicht Dinge sehen, die einem nicht mehr auffallen, wenn man sie seit Jahren gewohnt ist, die aber doch Verbesserungspotential bieten. So kommen auch neue Ideen ins Team.

Nun sehe ich, wie die Entwicklung in der Schweiz läuft und höre davon, wie sie in Deutschland läuft.

In der Schweiz wird es auch immer schwieriger. Es gab einige Schikanen, die man als „Kollateralschaden“, als „Kleinigkeiten“ oder auch „als gezielte Verhinderung der Konkurrenz durch Kleinfirmen seitens im Parlament gute verankerter Großfirmen“ interpretieren kann. Ich lasse das einmal offen.

Man muss in der Schweiz die Mehrwertsteuerfrage und die Frage der Sozialversicherungen regeln. Das sind Henne-Ei-Probleme. Um als Firma Mehrwertsteuer abrechnen zu können, muss man Kunden haben. Den Kunden muss man eine Rechnung schreiben und darauf muss entweder eine Mehrwertsteuer mit Mehrwertsteuernummer ausgewiesen sein, die dem Kunden nicht wehtut, wenn er selbst eine Firma ist, weil er sie weiterverrechnen kann, oder man weist sie nicht aus und hat dann das Problem, wenn man nachträglich mehrwertsteuerpflichtig wird. Das lässt sich lösen, wenn man der entsprechenden Stelle schreibt, dass man Kunden oder auch einen großen Kunden hat und gerne die Mehrwertsteuer bezahlen möchte, denn letztlich wollen die ja gerne das Geld einsammeln. Bei der Rentenversicherung und den anderen Sozialversicherungen ist es schwieriger. Die bekommen das Geld sowieso. Wenn man für die selbständig ist, dann zahlt man Arbeitgeber- und Arbeitnehmeranteile. Wenn nicht, zahlt der Kunde die Arbeitgeberanteile. Für die Abrechnung mit einem Kunden ist es schlicht unmöglich, eine Rechnung zu stellen und den Hinweis zu geben, dass man noch nicht weiß, ob irgendeine andere Stelle später noch Arbeitgeberanteile von Sozialversicherung einsammeln wird. Die Kunden gibt es dann schlicht und einfach nicht. Als Bäcker oder Maler hat man in der Regel schnell so viele Kunden, dass einem die Selbständigkeit abgenommen wird und keine Sozialversicherung wird beim Bäcker herausfinden, wer dort alles Brot gekauft hat, um den Kunden jeweils ein paar Franken Arbeitgeberanteile abzuknöpfen. Als Maler sollte man im ersten Jahr einfach ein paar kleine Kunden haben und nicht einen riesigen Millionenauftrag wie das Anstreichen eines Hochhauses, dann ist das auch gut. Als IT-Freiberufler hat man aber eher Projekte, wie das Anstreichen eines Hochhauses, wo viele Leute, interne Mitarbeiter des Kunden und man selbst und vielleicht auch andere „externe“ mehrere Monate oder gar Jahre an einem Projekt arbeiten. Es gibt Leute, die es geschafft haben, mit einer Einzelfirma als Freiberufler bei der Sozialversicherung als Selbständige anerkannt zu werden, aber das ist die Ausnahme. In der Praxis hat man zwei Wege, um diese Situation aufzulösen. Entweder lässt man sich bei einer Vermittlerfirma oder bei einer anerkannten Firma eines Kollegen temporär zu Konditionen anstellen, die komplementär zu dem Auftrag sind und umgeht das Problem auf diesem Weg. Leider bestehen einige Auftraggeber sogar auf diesem Modell. Das andere Modell, das letztlich interessanter ist, ist es eine eigene GmbH oder AG zu gründen und bei dieser angestellt zu sein. Dann ist auch alles sauber geregelt. Anders als in Deutschland kann man in der Schweiz kaum der Rentenversicherung entgehen, sie ist aber auch nicht so exzessiv ausgelegt wie in Deutschland, sondern zahlt eher eine Minimalrente, was die Höhe der Beiträge weniger schmerzhaft ausfallen lässt. Die mit dem Einkommen korrelierte Rente bekommt man in der Schweiz durch die sogenannte zweite Säule, auch Pensionskasse genannt, wo man ein Guthaben anspart, aus dem dieser zweite Teil der Rente gespeist wird.

Nun muss eine GmbH in der Schweiz ein Eigenkapital von mindestens 20’000 CHF haben, aber man musste nur die Hälfte einbringen. Die andere Hälfte musste man als Gründer nur garantieren, das heißt im Falle einer Insolvenz bis zu 10’000 CHF aus dem Privatvermögen aufbringen, um Schuldner zu bedienen. Später kam eine Änderung, dass man die 20’000 CHF von Anfang an komplett liefern musste, aber auch alle, die mit 10’000 gegründet hatten, die anderen 10’000 nachliefern mussten. Das klingt nicht so schlimm, letztlich war aber der bürokratische Aufwand recht hoch und erforderte ca. 1-2 Tage Arbeit und Gebühren, die mehr als ein Drittel der 10’000 CHF auffraßen. Letztlich ließ sich das mit Geld und Zeit bewerfen und war gelöst. Ebenso eine andere Änderung, die sogar nachvollziehbar war. Alle GmbHs und AGs brauchen eine Buchhaltung, die von jemandem mit entsprechendem Knowhow gemacht werden muss. Das ist normal und in allen Ländern so, die eine seriöse Wirtschaftsordnung haben. Große Firmen müssen diese Buchhaltung einer Revision durch eine weiter Buchhaltungsfirma unterziehen, bei kleineren ist das nicht nötig. Auch das ist sinnvoll. Früher war es so, dass man bei GmbHs grundsätzlich annahm, dass sie „klein“ sind und bei AGs, dass sie „groß“ sind. Das wurde dann korrigiert und Größe wurde nach rationaleren Kriterien gemessen. Nun musste man als GmbH aber aus der Revisionspflicht, die man erstmal aufs Auge gedrückt bekam, aussteigen, was wiederum ein größerer bürokratischer und finanzieller Akt war.

Die nächste Hürde war die Personalverleihbewilligung. Dafür muss man einen Antrag stellen, der etwa 46 Seiten lang war, und 50’000 CHF als Sicherheit hinterlegen, die man erst ein Jahr nach Verzicht auf die Personalverleihbewilligung zurückerhalten kann. Größere Firmen müssen die gleichen 50’000 CHF hinterlegen wie kleinere, nur wird sie bei größeren Firmen durch eine Garantie ersetzt, weil man diesen ohne weiteres glaubt, dass sie 50’000 CHF jederzeit aus dem Hut zaubern können. Auch diese Hürde lies sich mit Geld und Zeit bewerfen und überwinden. Und sie wurde nachträglich sogar wieder etwas abgeschwächt, allerdings in der Form, dass große Kunden trotzdem auf der Personalverleihbewilligung bestehen und dass manche Kantone sie nicht mehr gewähren, da sie ja nicht mehr nötig sei.

Jetzt bleibt zu hoffen, dass nicht eines Tages eine neue Schikane auftaucht, die sich schlicht und einfach nicht mehr realistisch überwinden lässt. Das faktische Berufsverbot für freiberufliche Informatiker. Ich möchte gerne viele Projekte sehen und die Flexibilität des Freiberuflers haben. Und ich kann mir nicht wirklich vorstellen, bei einer großen Firma angestellt und als „externer“ für Kunden zu arbeiten und mit dem Interessenkonflikt zu leben, loyal zu meinem Arbeitgeber zu sein und dem Interesse des Kunden und des Projekts zu dienen.

In dem Fall werde ich mir ein anderes Land in Europa suchen, wo ich weiterhin in der von mir bevorzugten Form arbeiten kann. In der Hinsicht bin ich flexibel und ich werde dann auch schnell die Sprache lernen, wenn ich sie noch nicht kann.

Share Button

Future for IT-Contractors


Some of us are working in IT.
And there you can finde some working models. You can work directly as employee of the company whose work you are doing. You can work as contractor (freelancer), with one of several slightly different setups, depending on the country. Or you can work as an employee of a larger company that lets you work for its customers. I am just briefly mentioning that some hybrid models exist.

I have worked all three models and I prefer the second one, working as contractor via my own Ltd-company. I think that people are different and have different preferences. And for staffing IT-projects it is good to have team members with different strengths and experiences that form a great team and not just resources that add up to the estimated number of person days during the project duration. It is good to combine permanent employees of the company doing the project and contractors. They are usually interested in the success of the project, while external team members employed in larger organizations often, but not always, bring in some own dynamic about interests of that organization that are not necessarily so congruent with the interests of the project. I do know positive and negative examples of this. For example have I seen that they bring in highly qualified people in an early phase, negotiate high rates and later replace them with juniors. I even heard of a case where such a company had to provide a couple of hundred people and brought a team consisting partly of office workers who had never done software development and who just edited program files in a way they were told by their more experienced team members by email. They did learn how to use the editor. Often they also bring people with good marketing skills to do the further acquisition during time paid by the customer. Generally working for this model requires an unusually high level of loyalty to the employer, so that working in another team, seeing the company getting relatively high rates, getting relatively low salaries (depending on the company, off course) will be continued for a longer period of time. It can be a reluctance to take risks or it can be loyalty or conservativeness or some combination. This is not a bad thing by itself, but building a team of people who are all too similar in this aspect could be suboptimal. Some organizations do send technically highly skilled people who are there employees. I think it is good to see who is actually joining the team and to make sure that the company sending them and the actual team members are good and trustworthy. Usually smaller companies tend to be better than international corporations for this, but good and bad examples exist in all combinations. To have a good mix in the team it is useful to have at least some contractors working for themselves among the external team members. Going through checklists of qualifications and capacity planning against some estimations is not enough.

A good mixture of internal and external team members, which can very well be with a majority of internal employees, is a great chance. It helps being flexible about the team size without having to do layoffs, which are neither common nor popular in Europe. For the loyalty of the permanent employees it is good if layoffs are a rare exception. Long term employees usually know the structures, the requirements, the customers, the IT systems and the tools very well because they have been around for several years. External team members have seen relatively many teams and companies and projects and have seen things that might not ring a bell for long term team members who have gotten used to certain things. So they can bring in new ideas for improvement and new knowledge.

I do observe how things in Switzerland are evolving and I am hearing some things about Germany. The problem is always that in other areas a contractor status is supposedly used to give employees suboptimal conditions and the government tries to stop this. In IT the contractor status is a good thing and works well and there are enough opportunities to become a permanent employee for those who prefer that. But if rules are formulated in a wrong way they make it very hard to be working as contractor.

In Switzerland it is getting more complicated. Some changes can be seen as „collateral damage“ or even „minor annoyance“ or as „effort by larger companies with good political connections to eliminate competition by smaller companies“. I leave that open for interpretation.

The VAT (sales tax) and the social insurance (retirement, unemployment etc.) needs to be addressed. This can be a chicken-or-egg-problem. To be able to pay VAT and to have a VAT number it is necessary to have some customers that justify the effort to provide a VAT number. Sending invoices with VAT usually does not hurt customers who are companies themselves, because they can pass it to their customers. Doing invoices without VAT is ok too, but becoming obliged to pay VAT later creates a problem because no customer wants to pay VAT on invoices that have already been settled. And nobody likes invoices with a text that says that the VAT-issue is still open and the amount to be paid might change later… Such customers simply do not exist. This is quite easy to overcome by just estimating the total amount of the invoices and writing a letter to the VAT organization prior to sending the first invoice. If the money in the start phase is not too scarce, the first invoice might even be delayed by a few weeks for this. In the end of the day the VAT-organization loves money and opportunities to get more of it.

The social security is a harder one. In Germany almost all contractors leave the social security system which is not very attractive and not very fair. In Switzerland at least the retirement system is slightly better and harder to leave, so the issue is more about finding a way to be part of this system and to work legally. Being an employee, the company and the employee pay half of the social security, respectively. Having ones own company implies paying both parts. If this company is not accepted by the social security organization, the customer is considered to be the employer and has to pay that half. This is a bad basis for sending invoices and if the status is not clear it is again almost impossible to have customers. Nobody likes working with a contractor if there is a possibility that the social security organization with come and collect some employer-half for some payments in an unpredictable future. This kind of customer simply has not been invented yet. Being a baker or a painter is no problem. Enough customers exist anyway, unless the business is a total failure. Nobody will find out who has bought bread and collect employer-parts for social security from the customer basis of the baker. If the painter does some smaller projects and not the really big million dollar contract for painting a skyscraper in the first year, things should be fine too.

Being an IT contractor the typical projects are more like painting a skyscraper. Many people are typically working on IT projects for many years and the contract might be extended for a year or two or in some rare cases even longer than that. So showing multiple customers in the first year can be hard, even though some smaller side projects, like trainings for other customers for a week or so, can help. Some people have managed to get this company status from the social security organization without incorporating their company. But in Switzerland that is an exception. In practice two ways are really working. Either you have to incorporate your company and get the social security issue resolved automatically by that or you have to become temporary employee of some intermediate company, usually the one who helped to acquire the contract. Conditions can be complementary to the contract and transparent.

There are basically two common ways to build a corporation in Switzerland: GmbH and AG. The GmbH requires a capital of 20’000 CHF (just think of around 18’000 EUR or 25’000 USD, but rates may change drastically). It was only necessary to bring have of that. The other half was only guaranteed by the founder, who had to provide another 10’000 from his money to pay debts of the company in case of bankruptcy. Later this was changed and the other 10’000 had to be added, which was reasonable by itself. But the bureaucratic effort was around one or two days and the fees ate up more than a third of the money. Was that necessary? Another change, that was in principal reasonable, was to change the size rule for more complex book keeping. Large AGs need another organization to check their book keeping while small GmbHs need only a professional book keeping. Small AGs where treated like big AGs and big GmbHs like small GmbHs. This was changed and the criteria became some metric about the size instead of the AG vs. GmbH-status, which makes sense. But it required some effort to opt out of the „big company pattern“, which was again expensive and time consuming.

The next step, a few years later, was the necessity to get a „Personalverleihbewilligung“. The paper work was around 46 pages and 50’000 CHF needed to be deposited as guarantee. Big companies have to deposite the exact same amount of money. It is for paying the salaries of the employees in case of failure. But this could be solved with time and money. Now it is hard to get the „Personalverleihbewilligung“ at all in some cantons, but in Switzerland companies play the game of moving to the most favorable canton.

There is always some risk that another problem is invented for small companies that cannot reasonably be dealt with. The factual prohibition for IT consultants working as contractors to do their job. I want to see many projects. I want to have the flexibility. I am willing to take the risk. But I do not want to become employee of a large organization and deal with the conflict of interest when loyalties with my employer and my projects conflict. I want to help the projects succeed.

In that case I will look for another country in Europe that allows me to work in the way I prefer. I am flexible with this and I will learn the language, if I do not already know it.

Share Button

Scala Days 2015

I have visited Scala Days 2015 in Amsterdam.
As usual, I took the night train to get there and back.

Creative Scala

Prior to the conference we did a training session for Scala beginners together with underscore. Some volunteers, including myself, joined the effort and so we were actually more teachers than students. It was fun.

Talks I listend to:

Monday 2015-06-08

* Monday-Keynote: Scala – where it came from, where it’s going / Martin Odersky

Tuesday 2015-06-09

* Tuesday-Keynote: Life Beyond the Illusion of Present / Jonas Bonér
* GraphX: Graph analytics for insights about developer communities / Paco Nathan @pacoid
* Meerkat parsers: a general parser combinator library for real programming languages / Ali Afroozeh @afruze & Anastasia Izmaylova @IAnastassija
* Fixing Reactive Code at 100 Miles per Hour: Five Techniques to Improve How You Debug Scala and Akka / Tal Weiss @weisstal
* Options in Futures, how to unsuck them / Erik Bakker @eamelink
* State of the Meta, Summer 2015 / Eugene Burmako @xeno_by
* Function-Passing Style, A New Model for Asynchronous and Distributed Programming / Philipp Haller @philippkhaller & Heather Miller @heathercmiller
* Essential Scala: Six Core Principles for Learning Scala / Noel Welsh @noelwelsh
* Project Gålbma: Actors vs. Types / Roland Kuhn @rolandkuhn

Wednesday 2015-06-10

* Wednesday-keynote: The Future of AI in Scala, and on the JVM / Adam Gibson
* Why Spark Is the Next Top (Compute) Model / Dean Wampler @deanwampler
* The Reactive Streams Implementation Landscape / Mathias Doenitz @sirthias
* Reactive Slick for Database Programming / Stefan Zeiger @StefanZeiger
* So how do I do a 2-phase-commit with Akka then? / Lutz Huehnken @lutzhuehnken
* Functional Data Validation (or How to Think Functionally) / Dave Gurnell @davegurnell
* Don’t Block Yourself / Flavio Brasil
* Closing Panel and Thank You

More details will come…

Share Button

Update of WordPress


The update of WordPress and its Plugins did not really work.

A small change helped a lot:

In .htaccess put the following line to the beginning of the file:

AddHandler php56-cgi .php

The all updates seemed to work fine.

Maybe this helps others observing the same problem.

Share Button