Tomasz Slota's Weblog
« June 2009
MonTueWedThuFriSatSun
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
     
       
Today

XML

the links

Skype Me™!
View Tomasz Slota's profile on LinkedIn



All | NetBeans | Personal | Sun

20081224 Wednesday December 24, 2008

Presentaciones en Peru en Noviembre 2008

Para ser sincero estuve en Perú por una casualidad y sin tener muchas expectativas. Debido al estrés causado por la preparaciones del viaje antes de llegar a mi destino me sentía ya arrepentido de haber aceptado la invitación.

Sin embargo desde el momento de llegar todo cambio y empezó a ser una maravilla. La gente, el clima y el ambiente me agradaron mucho. De pronto, seducido por la riqueza y variedad, me embarque en un peligroso romance con la comida peruana. Lo malo de esta es que viene en porciones de tamaño familiar y aunque se puede pedir 'medio plato' siempre parece demasiado para una persona. En los primeros días solía cometer un error de no tener moderación y de mezclar demasiados sabores. En consecuencia mi estomago se puso de huelga y por el resto de mi viaje tuve que mantener una dieta y enfrentar (a menudo sin éxito) constantes tentaciones de romperla.

Food in Peru

Por parte de los organizadores y participantes de los eventos recibí un trato como si fuese una estrella de pelicula. Nunca en mi vida me habian tomado tantas fotos (¡por favor mandenme algunas!).
Uno de los detalles chistosos fue que en una página me pusieron un titulo de doctor por equivocación y este error fue replicado tantas veces en varias referencias que ahora parece que no hay otra forma de corregirlo que matricularme a un programa de doctorado...

JPC Poster

El evento principal al que atendía fue Jornadas Peruanas de Computación organizado por la Universidad Nacional Mayor de San Marcos - una institución bien conocida por ser la primera de este tipo en las Americas y por ser frecuentamente mencionada en la literatura.
Fue la primera vez que presentaba NetBeans a un auditorio que en su mayoría ya conocía esta herramienta. Me impresione por el nivel de proyectos realizados en la universidad y sobre todo por el gran entusiasmo que mostraron sus estudiantes.

El segundo evento al que atendí fue el VI CICIS / V CORECI en Moquegua - un pueblo en el sur del pais. Me encanto el cielo color azul oscuro con el sol caliente pero no quemante y los paltos (aguacates) con cada plato. También allí probé mi primero (y único) plato de cuy y tome otro esfuerzo para aprender a bailar (creo que esa vez finalmente llegue a mostrar algunas esperanzas). Ese congreso fue preparado por los mismos estudiantes, sin mayor participación de los profesores y a pesar de esto me pareció bien organizado. Me comentaron que para conseguir financiamiento organizaron eventos como rifas con mucho tiempo en antemano.

Moquegua

En Moquegua conocí a Juan Moroco, un docente de la Universidad del Altiplano en Puno. Juan me presentó una oportunidad de conocer a su pueblo ubicado a las orillas del lago Titicaca y de dar una charla en un evento que casualmente se estaba realizando por allí (CONTITEL 2008). Sin pensar mucho acepté su propuesta, pues desde que era pequeño el lago Titicaca fue para mi un místico símbolo de lo lejano y lo exótico y siempre tenía ganas de conocerlo personalmente. Fue una emoción grande llegar alli y encontrar usuarios de NetBeans además unos de ellos interesados especifícamente en las características que yo mismo desarollé (el soporte para PHP y GWT). Pues esto confirmó que mi trabajo es útil para gente en todo el mundo y darse cuenta de eso era una satisfacción enorme. Ahora mismo estoy armando un video de esta visita. La película se va a publicar en el portal NetBeans.TV dentro un par de semanas.

Mi paseo por el Perú fue concluido con una breve visita en Arequipa - la Ciudad Blanca como a veces la llaman sus orgullosos habitantes. Ese nombre viene del color de las rocas volcánicas que eran usadas para construir la parte antigua de la ciudad. Zeze Lazo - un dedicado evangelista de tecnologías Microsoft, otro personaje interesante que conocí en Moquegua me presto sus servicios de guía allí. Aunque en su horario de trabajo Zeze no perdía una solo ocasión para mencionar ventajas de la plataforma .NET, resultó una persona muy amigable y capaz de hablar sobre muchos otros temas interesantes. En particular le agradezco llevarme a una librería pirata, donde consegui un pocotón de novelas peruanas más manejable por el precio y en el tamaño que los libros que compre en librerías oficiales en Lima. Resultó una compra muy util, pues me toco pasar el mes siguiente en casa, esperando a que sanara el brazo que me rompi en mi viaje de regreso.

Pachacamac

No se si es por el bajo porcentaje de profesionales que manejan el idioma ingles o por la situación legislativa pero el potencial de Perú en la industria TI aun no ha sido descubierto por las grandes compañas internacionales. Las empresas locales por el momento ofrecen pocas oportunidades interesantes. Como en Polonia, mi país natal, muchos de los mejores alumnos sueñan y cumplen su sueño de salir del país al graduarse.
Sin embargo me parece que los estudiantes peruanos tienen buena capacidad y a veces hasta mas ganas de trabajar que los mejores profesionales que he conocido. Esto junto con la ventaja de bajo costo finalmente debe resultar en el crecimiento del negocio del desarrollo de software local. Viajar y intercambiar ideas es siempre bueno, pero es una pena no tener otra opción de desarrollarse profesionalmente que dejar un lugar con tantas ventajas.
Creo el software libre es una de las maneras de ayudar al Perú, espero que mi trabajo también ayude un poquito. Espero volver a Perú pronto y verlo mejorar.

Mientras tanto les deseo felices fiestas y prospero año nuevo a todos!

Fermin's bday Posted by tomslot ( Dec 24 2008, 12:34:23 AM CET ) Permalink Comments [4]

20080211 Monday February 11, 2008

An Interesting Problem with Python, Proxies and OS X

I just came back from long a vacation and I spent first half a day back at work dealing with a frustrating although interesting issue with Python and Mac OS. The problem and (even more so) the solution are poorly documented, so I am writing this post hoping that other people facing it will be able to google my blog and find the way out here.

While I was away the NetBeans project migrated from CVS to Mercurial so my first task was to check out the sources (or rather clone the repository). I did anticipate trouble and it came indeed: the 'hg clone' command failed with a message:

abort: error: No address associated with nodename

After running a series of sanity tests I realized the problem was located at low level, in the Python framework and affected every Python script trying to read data from the Internet. I had a hunch to check the proxy settings so I executed the the following code:

import urllib2
print urllib2.getproxies()

and discovered that Python was using a phantom proxy server (it was a one that looked familiar but I didn't use it for ages).

After some research I learned that the problem is caused by the fact that Python uses Internet Config to discover network settings on Mac.

Internet Config is a very old utility that stores all the network settings in one place and provides an API to query for them. Internet Config was a very welcomed innovation back in 1994 when it was started by a community members. in fact it was such a blast that Apple decided to include it in Mac OS 8.4 and further releases.

Later OS X provided new standard ways of storing the network configuration info but the Internet Config API remained to preserve compatibility. Many developers continued to use the Internet Config API without realizing it was not only deprecated but also out of sync with the system settings. Moreover there is no longer a graphical way to access those data in OS X.

Apparently I used some application that wrote the proxy info to the Internet Config database. The setting was ignored by most application, but Python was still relying on it.

Even once I knew that much it still wasn't easy to find out where this data was stored: the 'com.apple.internetconfig.plist' file in the Preferences directory. The file can be edited with the Property List Editor utility (it comes with the Developer Tools). Pay attention to these settings: UseHTTPProxy and HTTPProxyHost.

I hope that at least one of these two sneaky bugs (one on the Apple and the other on the Python side) gets fixed soon, in the meantime it is possible to work it around editing the 'com.apple.internetconfig.plist' file by hand. Posted by tomslot ( Feb 11 2008, 01:51:43 PM CET ) Permalink Comments [2]

20070802 Thursday August 02, 2007

IT in Panama

It has been 3 years since I returned from a year long student internship in Panama. I was working on the premises of the former US military base "Fort Clayton", which was converted into a technology park "Ciudad del Saber".

In my feeling in spite of a booming economy Panama was technology desert at that time (2003-2004). Unlike in many other developing countries, technical studies in Panama were not very popular. The few IT companies that existed tended to spend money on expensive software of dubious relevance from brand name giants such as Microsoft or Oracle than to pay their engineers a decent salary. Bigger IT projects were conducted by 100% foreign companies.

Things seems to changing now. There is a growing interest in Open Source and Java, local technology firms start looking for developers. Arististides Villareal, the author of the biggest blog on Sun Java technologies in Spanish started a JUG and is putting together a Java conference in December. There is a good chance I will attend it and get opportunity to reassess my views.

Unwanted reptile intruders can be a problem in an office surrounded by tropical rain forest. A proven workaround: keep some garlic next to your feet, it worked for me!

See more pictures of mine from Panama at http://tomslot.fotopic.net


Posted by tomslot ( Aug 02 2007, 03:32:11 PM CEST ) Permalink Comments [0]

20070412 Thursday April 12, 2007

GWT-based Visual GWT Designer

A good WYSIWYG HTML form editor should be written in the HTML and JavaScript , emulating the web browser environment is a hopeless work. I have developed a prototype GWT Visual Designer using GWT and NetBeans, check it out and you'll have to admit it looks promising.

The idea of web-based IDE is slowly materializing, there is a number of interesting projects going on. Many expect it to be the next big thing in the IDE world. AFAIK my effort was first such attempt for the GWT technology, unfortunately I will not be able to develop a production-quality tool by myself. Do you think it worth to carry on this project? Would you like to join?

Designer

Posted by tomslot ( Apr 12 2007, 05:57:08 PM CEST ) Permalink Comments [5]

20070120 Saturday January 20, 2007

Using development builds of Netbeans FAQ

I often come across questions about the current state of the development builds of NetBeans, so I decided to create a small FAQ and post in my blog.

Is possible to use current version of NB 6.0 to do some "real work"?

These days virtually all the NetBeans developers are using most recent (daily) builds to develop NetBeans itself. This means that at the very least more than 50 people are doing "real work" dealing with more than 20 000 java source files. I reckon there is about the same amount of people working on various NB add ons who do the same.

It is quite exciting to see new features in your work tool added day by day and there are not as many stability problems as one might expect. However if improving the quality of NetBeans is not a priority for your organization you will want to stick to the official releases. Surprises are not good for business, you want to minimize the number of things interfering with your deadlines in the first place.

What are the milestone builds good for?

Milestone builds allow us to:

  • keep balance between feature growth and stability throughout the development process
  • deliver relatively stable development releases on regular basis
  • keep track of release progress

We set goals and try to achieve them during 3 weeks of development. Then we spend one week on intensive testing and removing outstanding problems. A milestone build is not released until all the crucial bugs designated by the Quality Assurance team are not fixed. No other changes are allowed during that time, as every change carry a risk of introducing new problems. Basically it is a release process in small.

Using a milestone build is a reasonable trade-off for most developers who rely on the state-of-art NB features

What kind of problems may I encounter when using development builds of NetBeans?

  • wizards and refactorings may be generate wrong/suboptimal code.
  • the format of project, configuration, form, etc. files generated by the development builds is not guaranteed to be supported in the future, manual amendments might be needed to open them from a newer version of the IDE
  • you might enter exception loop and have to restart the IDE

On the other hand you may (almost) rely on the core functionality such as:

  • I/O (opening/saving files/projects)
  • version control subsystem
  • compilation
  • debugging standalone java applications

What are the most fragile areas in current builds of NB 6.0?

As of milestone 6: refactoring, java hints and all the Enterprise/Web functionality. All this stuff had to be completely rewritten to use the new, more powerful editor and language model infrastructure. Some basic functionality like encapsulating fields is still missing, using some existing features like "rename class" may mess up your code.

Posted by tomslot ( Jan 20 2007, 04:58:20 PM CET ) Permalink Comments [3]

20070109 Tuesday January 09, 2007

Breaking up with Apple

I purchased iWork 05 and I was not able to use it a year later on my new Intel-based MB Pro. I paid for upgrading OS X just to be able to use Java 5. Yet I was easy to forgive, satisfied and full of enthusiasm for their technology.

It wasn't until the MacWorld keynote (2 hours ago), in particular the info on partnership with Cingular that I realized how evil those guys were.

Wake up, those folks seem to be dreaming to lock us all up with their own stuff using patents, exclusive licenses and proprietary data formats, they do open software and standards only when necessary!

PS1. This post is emotional rather than factual, I may change my mind in a couple of hours

PS2. I am looking for good materials on using Linux as a primary OS on MB Pro

Update (answering the comments)

  • The thing that bothers me the most in the alliance with a single cellular operator is that I would not be able to change SIM card when abroad, paying the roaming fees is out of question for me
  • I was not accurate saying I was not able to use iWork '05 on Intel Mac. I was just so disappointed with the performance and stability of other apps written for PPC and running on Rosetta, that I did not bother to try iWork (I believe it could behave better as Apple product). For example MPlayer would crash the OS completely every time when run, only disconnecting power supply and removing the battery could bring it back to life..
Posted by tomslot ( Jan 09 2007, 09:02:35 PM CET ) Permalink Comments [4]

20061227 Wednesday December 27, 2006

I've tried Solaris on the public beta of VMWare for Intel Mac

... and I was quite amazed by its compatibility, stability and performance (although the beta release only works in the debug mode, which according to a warning displayed on startup implies a severe performance penalty).

Before Dec 22 there was only one virtualization solution for Mac developed by Parallel Desktops, which supported Solaris as well, but it had quite a few issues (see Capitan Holy Hippie's blog).

According to the press release: The new VMware desktop product for the Mac, codenamed Fusion, allows Intel-based Macs to run x86 operating systems, such as Windows, Linux, NetWare and Solaris, in virtual machines at the same time as Mac OS X. It is built on VMware's rock-solid and advanced desktop virtualization platform that is used by over four million users today.

I was playing with OpenSolaris build 54 and a Mac Book Pro. Already during the installation the mouse pad was working and there was a network connection (unlike during my previous attempts of installing Solaris directly on the hard drive). After installing the VMWare tools (a set of guest operating system /Solaris/ drivers, which make interaction with the host OS even smother) I could also work with sound and full screen resolution, accelerated video (it felt somewhat sluggish before that).

I was truly impressed not to come across a single stability problem in a couple of hours I spent playing with Fusion, torturing it with NetBeans and other heavy stuff, really well done!

I hope the I/O performance improves in the final product, anyways, I find Fusion as it is the best way to run Solaris on a Mac as of today.
Posted by tomslot ( Dec 27 2006, 08:56:29 PM CET ) Permalink Comments [0]

20060613 Tuesday June 13, 2006

muCommander - a Java-Powered, Cross-Platform File Manager

I am addicted to two paned, Norton Commander-like file managers. I do not require anything fancy though, I was quite happy using the command line version of Midnight Commander. My work laptop was recently upgraded to MacBook Pro. Unfortunately I find the PowerPC emulation (Rosetta) rather disappointing, apart from performance penalty it has a tendency to hang the entire OS, especially when running Open Source stuff (try PPC-compiled MPlayer).

Being lazy to attempt to recompile Midnight Commander manually I made a quick research for alternatives. It led me to muCommander, a free, cross-platform app written entirely in Java. The author (Mexence Bernard) is using a Mac as well, when run under OS X the application takes advantage of Apple's Java libraries providing a nearly native look & feel (OS X-style menus, native keyboard shortcuts are yet to be seen though)

Some highlights pointed in the website (www.mucommander.com) :
  • Virtual filesystem with FTP, SFTP, SMB and HTTP/HTTPS support

  • Quickly copy, move, rename files, create directories, email files...

  • Browse, create and uncompress ZIP, TAR and GZip archives

  • Universal bookmarks 

  • Multiple windows support

  • Customize the look and feel to your taste

  • Never leave that keyboard again, shortcuts are provided for almost everything

  • Available in 11 languages : English, French, German, Spanish, Czech, Simplified & Traditional Chinese, Polish, Hungarian, Russian and Slovenian

Cool stuff, highly recommendable to Java desktop sceptics!

viewing file in ZIP archive over FTP Posted by tomslot ( Jun 13 2006, 01:54:24 PM CEST ) Permalink Comments [0]

20060525 Thursday May 25, 2006

A New Way of Creating EJB3 Entity Relationships in NetBeans 5.5

I have just checked in a new, cool feature requested by the users – hints for defining entity relationships.

If there is a field/property of entity type ('Company' in the example below) defined in another entity ('Employee') and it is not annotated neither with the @OneToOne nor @ManyToOne annotation, it is underlined and there are quick-fix actions for creating relationship available:

If the newly defined field is a collection of entities it is possible to create OneToMany and ManyToMany relationships instead.

Once a "create relationship" action is chosen, the user is presented a dialog with options for selecting corresponding property at the other entity:

The property can be either picked up from a list of existing properties of matching type ('Employee' or collection of 'Employee', depending on the kind of relationship), or created from scratch as in presented example:

This feature is available is NB55 daily builds from today on. It is not present in NB55 Beta release.

Posted by tomslot ( May 25 2006, 04:54:00 PM CEST ) Permalink Comments [0]

20060501 Monday May 01, 2006

Problems with Version Control in Enterprise Applications

I used to do a year long internship in a Latin American banking software company. As an "outsider with a fresh look" I was occasionally asked to try to think of better ways of doing certain things that were causing them most troubles. One of such areas was version control. Updates sent out to the customers, in spite of rigorous procedures in place, were continuously causing inconsistencies between the database schema and client application layers (and thus annoying runtime exceptions). I developed an auto update tool and carried on later writing a Master's Thesis on some ideas of how to develop a self-updating, portable version control system for database schema. Once quite proud of the solutions I had come up with, I could never help the feeling that much simplier, "Egg of Columbus" style solution existed but I was failing to see it.

Now as I am working with the new EJB3/Java Persistence APIs I am starting to see a light in the end of tunnel... There is no longer need to maintain the database schema and application sources separately. The latter can be generated automatically from the sources. The consequences of this fact are depeer than just saving the time needed for manual schema creation - the source code duality problem (DDL SQL vs logic language like Java or PL/SQL) disappers, it is easier to handle sources manually as well as using modern, static analysis based tools.

I can imagine design patterns like "Versioned Entity Manager" that would look up and persist entities in a schema version dependent way. The mechanism could be possibly transparent to the developers and upper architecture layers. Perhabs one day such a mechanism could be incorporated into a standard application container...

A common database application development scenario is that the ORM mapping is pretty straightforward in the beginning and then gets complicated as the system is optimized for performance and is updated to keep some additional data. This case seems to be able to be handled very nicely. However there are still many corners (like renaming/removing tables/columns) that at least for now would require some special, conscious handling.

I wonder if anyone has come up with/is working on some smart ways of handling such problems. Looking forward to your comments!

Posted by tomslot ( May 01 2006, 12:01:52 PM CEST ) Permalink Comments [0]

20060309 Thursday March 09, 2006

Java EE 5 verification in Netbeans 5.5 I can eventually show off with a self-implemented piece of NB functionality: Java EE 5 Verification - a framework for finding & solving problems in Java code that uses EJB 3.0, Persistence API and JAX-WS 2.0 annotations. Similary to java syntax errors, the JEE 5 problems are detected and highlighted as you type. There are 'quick-fix actions' (hints) available for many of them. Just as in case of ordinary java errors, those actions can be accessed by clicking the bulb icon that pops up when the cursor position is within the line that contains error. Together with advanced code completion, online help and wizards this facility should make NetBeans 5.5 a terrific learning tool for folks starting up with Java EE 5.

Assertions implemented as of build 'release55_20060309':

Persistence API (JSR 220)

AssertionHints
InconsistentAccessTypeInEntityUnify property access, Unify property access
EntityHasNoSuitableAccessorEncapsulate field...
Missing Enity IDCreate Entity ID...
EntityHasPublicField (warning)
FinalClassAsEntity
NonPublicClassAsEntity
FinalMemberInEntity
NoSuitableConstructorInEntity
SetterMethodsAnnotatedInEntityMove persistence annotations from setter to getter
InvisiblePropertyAccessorInEntity

JAX-WS 2.0

AssertionHints
the serviceName attribute is not allowed on interfacesRemove serviceName attribute
the endpointInterface attribute is not allowed on interfacesRemove serviceName attribute
it is not possible to annotate a method with the @Oneway annotation without corresponding @WebMethod annotationAdd @WebMethod annotation, Remove @Oneway annotation
an operation marked @Oneway may not have a return valueRemove @Oneway annotation
an operation marked @Oneway may not have out/in-out parametersRemove @Oneway annotation
an operation marked @Oneway must not declare any exceptionsRemove @Oneway annotation
it is not allowed to combine @HandlerChain annotation with @SOAPMessageHandlers annotationRemove @HandlerChain annotation, Remove @SOAPMessageHandlers annotation
None of the EJB3-specific checks has been implemented so far, however the final list of assertions and hints in all the three areas is to be substantially expanded by the final NB 5.5 release. Posted by tomslot ( Mar 09 2006, 07:55:40 PM CET ) Permalink Comments [3]

20060110 Tuesday January 10, 2006

MWSF 2006 I am anxiously looking forward to read the transcript from Steve's presentation and learn what I am going to waste my savings for this year. I don't really like Apple, I'm just vulnerable to their marketing.. Posted by tomslot ( Jan 10 2006, 03:44:32 PM CET ) Permalink Comments [1]

Hello, world!! I’ve spent a week working at Sun development site in Prague and I feel it is a high time for creating my own blog.. I found out about Sun opening an office here reading a blog and it was the culture of openness that attracted me the most. I am no longer the idealist I used to be a few years ago, but I still find working full time on mass-market, open source projects very rewarding. I do enjoy sharing, even though some claim altruism to be the highest grade of selfishness ;-) Posted by tomslot ( Jan 10 2006, 09:54:48 AM CET ) Permalink Comments [0]