Monday, March 09, 2009

Welcome the PDTT - PHP 5.3 Code Assist Engine Tests

pdtt is a clone of the popular phpt. Eclipse PDT uses this mechanism for testing its PHP 5.3 code assist engine. 

Since Michael has just finished implementing the second phase for PHP 5.3 support in PDT, we can now expose unit tests and ask users to add more cases to the code assist tests reposiroty.

As written in the pdtt wiki page
"The first thing you need to know about tests is that we need more!!! Although Eclipse PDT code assist works just great 99.99% of the time, not having a very comprehensive test suite means that we take more risks every time we add to or modify the Eclipse PDT Code Assist Engine implementation. The second thing you need to know is that if you can write PHP you can write tests. Thirdly - we are a friendly and welcoming community, don't be scared about writing to (pdt-dev@eclipse.org) - we won't bite!"

Basic Format for a pdtt file:
--TEST-- 
Tests a simple class name completion in namespace 
--FILE-- 
<? namespace My; class A{} class b{} $a = new My\| ?> 
--EXPECT-- 
type(A) 
type(B)

I guess that once we get some feedback from our members we will expose a better (automatic) way to submit pdtt files.

Enjoy ;)


Saturday, January 03, 2009

Seven Things - tagged by Andi Gutmans

Although till recently I thought that work and fun can't get along, Andi Gutmans is trying to prove to me, time after time, that this assumptions is completely wrong!. Yes... I've been tagged.

Seven things I want to share with you:

1. I am allergic to cats - well... at least that's what I was told when I was a kiddo, so my family had a cute dog with long hear, no cats. Now my wife insists that we should have a cat since she was grown up with cats, and I answer her that we have one cat already. Miaoo...

2. I have a super smart barber, who is a lawyer - my father, he actually replaced my mom when I was 13 years old. Curly hair is something easy to cut and I can't see any other barber since I get pretty strain by that.

3. My brother lives in Panama City with his lovely family. Last time I visited him, some guy that set next to me in the flight asked me why I use Eclipse as my development environment, I told him that I am a Java developer. He then ask me, "really? and I thought Java is dead, you should try out PHP..." :). It took me 10 minutes to convince him that I really work at Zend.

4. I am trying to figure out how to analyze X-ray images to better examine the OSA phenomena, my professor thinks it is doable at least...

5. I am very proud of my wife as she is going to be a doctor, well on 2010, and then she has more 7 years to be in residency... 2017 here we come!!!

6. I am managing 4 open source projects, 3 on Google and 1 on Eclipse. I am participating in much more.

7. My new iPhone is the most appreciated present I got from my wife. I sound like a material guy, but it just made my life much more comfortable.

Hi guys you've been tagged-

1. Kfir Karmon who is the smartest guy at Microsoft Israel Labs.
2. Yaniv Taigmanwho is going to have a knockout with his face.com startup.
3. Nick Boldt who is keeping his eyes on Eclipse PDT release engineering stuff.
4. Lior Wolf who is the most admired professor in my university ;).
5. Michael Spector, who doesn't have a blog but is the fastest coder at Zend, so he can arrange one in minutes :).
6. Philip Gabbert who met me in the last ZendCon, and became a Zend Studio fan.


And here are the rules I'm supposed to pass on to the above bloggers:
* Link your original tagger(s), and list these rules on your blog. 
* Share seven facts about yourself in the post - some random, some weird. 
* Tag seven people at the end of your post by leaving their names and the links to their blogs. 
* Let them know they've been tagged by leaving a comment on their blogs and/or Twitter.

Wednesday, November 26, 2008

Zend Framework and Dojo Integration is a Knockout!


A new screencast was released today showing off the slick integration between Zend Framework and the Dojo Toolkit. This screencast also demonstrated the tooling support which Zend Studio 6.1 provides for this end. The speaker demonstrates it by constructing a simple Web application that takes advantage of the new features, like code assist, navigation, easy to use of PHP and JavaScript.

This manual presents a step by step guide for getting the Web application from scratch.


Thursday, September 18, 2008

ZendCon 2008 Slides

Yesterday I gave a session about Rich Internet Application development, titled "PHP and AJAX made easier with Zend".






Ria Made Easier With Zend
View SlideShare presentation or Upload your own.

Friday, August 15, 2008

ZPortal is Open-Sourced

The pet project I have initiated at work a while ago finally goes public.

Project's name is ZPortal and from now on it is managed under Google Code. One important fact is that the "Z" prefix indicates the framework we used to build this portal, which is Zend Framework.


As an introduction to this post I want to point on the difference between "Horizontal information" which is information that anybody has and use vs. "Vertical information" which is information that only you or your organization has. In the Enterprise2.0 era we try to take advantage of these two types of information and bring it to the user (employee) so he has much more power in his daily work. Previous solutions like Wiki are not sufficient these days as they discard the horizontal layer and lack of integration points.

So what is all about? it is about Enterprise2.0. ZPortal is a system of Web-based technologies that provides rapid and agile collaboration, information sharing, and integration capabilities in the extended enterprise. For those who are not familiar with the term Enterprise2.0 but know something about Web2.0 I recommend reading this post that compares between the two methods. Actually from a user point of view ZPortal is similar to iGoogle with small differences. First the authentication method is against Microsoft Exchange Server (it can be replaced by any authentication technique but of course this is the common way thee days) second you can add internal feeds from your company as this system runs behind the company's firewall. Third you can extend this portal to your company needs.

If I'd try to depict my environment at office I would do it like this:


Finally, I want to thank two people who are not at Zend anymore but helped allot toward this project - Seva Lapsha and Yuval Kuck.



for more details visit the new ZPortal site - http://code.google.com/p/zportal/

Saturday, May 24, 2008

Eclipse PDT Bug Day

According to Eclipspedia the motivation for Eclipse Bug Day is "to help foster community outreach and growth". Since there are more and more people in the Eclipse PHP Development Tools (PDT) community that start asking for diversity in the development side, Nick Boldt has suggested to help out and contribute patches to the project "if there's Zend folks willing to coach me...". Actually, I am very excited from his (and others) proposal, since it's the first time a group of people have stated that they want to contribute to PDT.

There are three more things that worth mentioning here:
  1. I do think that PHP developers can (and should) try and contribute to this project although the core development is in Java, since trivalley this project is solely designated for them.
  2. PHPEclipse people that did great on this project, should think about a way to integrate their work and help us so we will unite the forces on one platform.
  3. Since people need to have some knowledge about our platform, we should supply basic design documents. The following two articles can be used for this end, ASTView and Abstract Syntax Tree.
Save the day, the bug day will be held on May 30th. Getting started bugs were tagged as "bugday" (thank you David!)

Thursday, April 03, 2008

PHP and JavaScript in a Single Frame

Many tutorials and blogs written about “PHP & AJAX” and “Rich Internet Application” but take no notice of a suitable development environment. Actually now days' web application tasks involve many technologies and mechanisms that come to be pretty fast a tedious work, this automatically brings many developers to search for an IDE for PHP and JavaScript.

Yesterday, I have conducted a Zend webinar, named "Developing Rich Internet Applications using Zend Studio for Eclipse". In this Webinar I presented Zend Studio for Eclipse empowered by the Ajax Tools plug-in, I went over the installation process, project management, source editing and debugging capabilities for both PHP and JavaScript including code assist, code formatter, folding elements, server-client debugging and more.



Also I have demonstrated the usage of ZF and Dojo session debugging and with the example that was given by Ralph last week. Thanks Ralph!

Also I gave a demonstration of the integrated Mozilla editor that communicated with other parts of the broser tolling (like DOM inspector, browser console, request monitor view, JavaScript Evaluator, DOM source view, CSS view and the DOM watcher).



See you next time!

Saturday, March 15, 2008

EclipseCon 2008 - Here I come...

It's time to pack two jeans and get the flight to San Fransisco- EclipseCon! here I come.

Though I am a speaker there, I am pretty wait to hear and see some of the Eclipse fellows. Like those from the Data tools platform and from the Web tools platform.

Also there are many sessions that I am eager to attend-
1. Getting started with RAP development - develop rich, AJAX-enabled web applications using the same development model as RCP.
2. Developing Python IDE on top of Eclipse DLTK Project - a set of frameworks designed to build full featured development environments for dynamic languages.
3. Getting Started with OSGi
4. Mylyn: code at the speed of thought
5. What can the WTP Snippets View do for me?
6. Eclipse Command Language

and a link to the EclipseCon sessions
http://www.eclipsecon.org/2008/index.php?page=introduction/

Friday, February 22, 2008

php Development Tools (PDT) Community News

It's funny how differently developers act in 'release cycle' vs. 'development cycle' . While during the first we are busy with users' feedback but we lack of any intellectual challenges , the latter is calm and quite but full of energy and programming disputes. PDT version 1.1 development cycle has begun and we need an extent of "noise" from our community so we won't lose our way. You are more than welcome to advise us now.

PDT v1.1 Development Cycle
Taken from Ohloh's Eclipse PDT page

So what's keeping us busy these days?

1. Revising Modeling Techniques – Its time to catch up Eclipse's standards. We have decides that our previous modeling technique is getting oldish. So naturally we are targeting JDT's concepts with adaptation to the php dynamic binding nature (given by the DLTK project).

2. Code Manipulation – sometimes the editor should generate new code or even rewrite an existing code. This is an excellent mechanism for such kind of tasks. Also a great advantage is that we catching up JDT's standards on these capabilities as well so many of JDT's features are quickly portable to php.

3. UI enhancements – this is the part that our community should be most happy to hear about. Since infra was enhanced , more and more UI features are available. Taking for example mark occurrences, override indicators, better code completion, fast searching, quick fixes and more.

Exit Execution Paths are marked in PDT 1.1 Editor

4. Upgrading our Dependencies – While most of Eclipse 3.4 enhancements are infra related, Web Tools 3.0 brings the Ajax tools into their editor and this is automatically brings it to the php environment. Editing, browsing, launching, code assisting, folding, and more features are now available for the JavaScript side as well.


5. Unit testing – Well... maybe it won't be an interest of any of our users but still it is worth mentioning. We have tripled our unit testing to provide stability and regression testing to PDT. It seems that it also makes the whole development cycle more fun to us!



Sunday, December 16, 2007

Speaking at EclipseCon 2008

I'm speaking at EclipseCon 2008

It seems that PHP developers have attracted much attention from the Eclipse community. In the next EclipseCon conference I am going to make two sessions about PDT and its ecosystem.

Developing Rich Internet Application with Eclipse Tools

It's about to get a whole lot easier for AJAX and PHP developers to develop Rich Internet Applications under the Eclipse environment.

This tutorial introduces tools to develop Rich Internet Application including:

  1. The Eclipse platform
  2. The Web-tools platform and the AJAX Toolkit
  3. The PHP Development tool
Content
  1. Introduction to Eclipse and Web development environment
  2. PHP (Server-Side) development tools
  3. JavaScript (Browser-Side) development tools
  4. Setting up a generic ‘hello world’ website
  5. Developing your AJAX-PHP web-application

Extending the PDT Project

The PDT project provides a PHP Development framework for the Eclipse platform. This project encompasses all development components necessary to develop PHP and facilitate extensibility. It leverages the existing Web Tools Project in providing developers with PHP capabilities.

In the PHP world, where there are hundreds of core extensions and dozens of frameworks, we finally have an accepted development environment that enables framework and core developers to support also their own development tools.

This tutorial introduces the basics of PDT extension points and architecture as well as a case study of a well-known extension to PDT.

Monday, November 19, 2007

PDT Gets Smarty

Staring from day one of PDT project, a feature request screaming "Support smarty template syntax coloring" was very popular in our bug tracking system. Twenty-three people voted for this issue, many posts were written about it in the newsgroup and users keep sending us e-mails hoping their request is going to be fulfilled in the near future.

Well... if I understand the Eclipse Foundation correctly, PDT developers shouldn't operate fast and fix these kinds of features. PDT was built only as a "PHP Development Tools framework". In the PHP world where there are hundreds of core extensions and dozens of frameworks it is impossible to support all of them.

But... a feature request is a feature request. And feature requests are meant to be resolved. Applying simple logic rules derives that - "PDT Gets Smarty".

So the growing eco-system of PDT has a new sibling called 'smartypdt' which is a project that "enables users to develop Smarty projects utilizing the power of PDT" it is a great initiative developed by William Candillon , that was guided by me and we expect Dave Kelsey to join us soon. The results are really great!!!

For now two basic capabilities are provided: syntax coloring and compilation
error analysis. This makes PDT and smartypdt the best development environment
for Smarty developers.

The idea is that frameworks and extension creators will re-use the
functionality presented in this project and provide it alongside their products
to ease the development with PHP under PDT.

The package and source code can be accessed from here - http://smartypdt.googlecode.com/

You are more than welcome to test-drive it and submit bugs, features and patches.





Tuesday, September 18, 2007

One community, Dozen programmers, 1186 bugs and one quest for transcendent PHP editor

One community, Dozen programmers, 1186 bugs and one quest for transcendent PHP editor, By Roy Ganor

A year and a half ago, I got a confirmation e-mail from Eclipse Foundation Inc., the subject was “Welcome to Eclipse!”. I probably didn’t understand the exact meaning of this message at that time.

Today the PDT project community consists of about 30 users that are daily involved, and about 300 users that are weekly involved, and about 13,000 users that are monthly involved in the project . Remarkable! by any mean of open-source project.

Going back to the beginning of the story, the group has started developing an Eclipse based PHP editor with mixed emotions. On the one hand our current implementation that was based on Java Swing Technology, was very robust and appreciated by PHP developers (many rewards, compliment reviews and winning contests). On the other hand we saw the effect of JDT project on the Java community.

I am not going to write about the development process as it would require at least more than ten pages to cover. I will rather tell you about the community, about us (the group) and about the integration level with the Eclipse community.

So, the first question is how we grew to a large scale community? I can come up with many reasons. Starting with the need for such a product and the existing Eclipse community, to the exposure we enjoyed during the development process. But if you ask me - there is one more (and most important) reason for growing to such a scale. Any community is based on its regular users that comprise 95% of it. This is the heart of the community and we felt that we should do more for them. We observed that everything went just great till one finds a defect in the editor, he then may:
Browse to Eclipse's bug tracking system and reports about the issue.
Go to the \eclipse folder and remove it with a ‘–r’ parameter.
But the question is how to make the user choose the first option? Well the answer is quite simple. A user will report on a bug if he gets a fix ASAP, say in 24 hours. 24 HOURS?! yes, he will then continue working with the product and probably report about another issues or features. In doing so he enters the 2% of the users that are called active users. We delivered the fix as part of a nightly build that was stable enough (unit tested) to be bundled and deployed.

The integration level with the Eclipse community is another magical and interesting issue. During the process of development we encountered with an “imported” code that is written as a framework on a daily basis. Most of the time we worked with a conformist API that in any circumstances cannot be changed. In other cases we tried to contribute these framework projects and made them more flexible to us – probably this is the strength of one open-source community that is obligated to each other. One of my e-mails to WST Project leader points out that it is a “miracle” that we integrated the PHP Editor into the Web Editor. Taking for example the JSP Editor whose team is a sub-project of WST and is relatively tight coupled to the Web Editor.

PDT 1.0 is out and there are many reasons to call it the transcendent PHP editor.

(The name of this post was inspired by “Dreaming in Code”/Scott Rosenberg)

Wednesday, January 03, 2007

Eclipse Plug-in Test Framework

After two weeks of configuring and scripting test packages I can say that "building" a build process is a very hard task, but worth the tears!

now you can RSS: http://download.eclipse.org/tools/php/downloads/rss/updates.xml
or be a member in pdt-unit-test@eclipse.org to be updated about the test results.

Good night,
Roy

Tuesday, January 02, 2007

Transforming to linux-style stream

Why there are differences between the platforms end of line characters? Oh yes, Never ask the WHY question on standarts, so I found my self coding a small block to overcome this mini-crisis:

// given an input stream
final InputStream is = ...;

// create a stream that behaves as a linux-style stream
InputStream linuxStream = new InputStream() {
int previous = -1;
int current = -1;
int next = -1;
  public int read() throws IOException {
if (next != -1) {// a buffered int was readen last iteration
current = next;
next = -1;
} else { // else read an int from the stream
current = is.read();
}
    if (current == 13) {
next = is.read();
if (next == 10) { // encounter "\r\n" transform to "\n"
next = -1;
}
current = 10;
}
return previous = current;
}
}


Monday, January 01, 2007

The Future of Operating Systems

Well... as I see it, there is no such thing "future to operating systems".
Hi, wait a minute, are you fooling me? how computer will work without an operating system?

They will, with a small effort one of the open-source companies will create a simple program that will first of all manage the basic hardware of a computer (I/O and memory), and second let the user the ability to browse the internet. Such kind of computers should be called "Webtops" (I know that some people use this word to describe web office-style programs but I think that like laptops/desktops, we should call small computers that designed for the net - "Webtops"). Oh ya! These computers will work fast, since they won't do any "heavy" computations.

So what you're telling me that simple and light computer program will be backup by a huge backend servers? well... yes.

There are many question here that I need to answer:
Q: Online vs. Offline work, how one should work without an internet connection?
A: Do you realy think that internet connection will not be accessible from anywhere in 10 years from now?

Q: What about security?
A: Security will be given by the server software.

TBC...

Roy Ganor,