1. Recently I have had to work a lot with NetBeans. We are working on integrating GridGain management console with SUN VisualVm, so NetBeans is pretty much the only IDE we have available for the task.

    Overall, I was quite exited to try out a new IDE and I can definitely say that NetBeans6 has tremendously leaped forward comparing to its previous versions. It also looks quite nice on Fedora Linux. However, it has certain annoyances that still make IDEA or Eclipse much superior IDEs. Some of them are:
    • Project Views
      Although you can import arbitrary sources from various folders, in Package View I can only look at Java code. Why can't I have one view where NetBeans would auto detect Java code and show it as packages and non-Java code - as regular folders? It's getting tiresome to switch between package and File views just to look at my XML files

    • Hierarchical Package View
      First of all, to switch Package View from flat into hierarchical mode was not easy. I really had to look for it. Moreover, unlike other IDEs, NetBeans does not have an option to group empty packages. Also, there is no expand-all/collapse-all option, which makes hierarchical view virtually unusable.

    • Imports
      There is practically no way in NetBeans to configure a project to auto-include package level imports, with '*' at the end. The only way to work with NetBeans is to have single-class imports. I constantly have to manually fix imports because we have a project-wide coding standard to only use package-level imports.

    • Javadoc
      I would like to have an option to configure all Override method to auto-include @Override annotation. I also want to have all methods that implement an interface or override methods from superclass to have automatic {@inheritDoc} Javadoc inserted. Eclipse, for example, has the best support for it.

    • Library Dependencies
      It is annoying to have to specify every single JAR file separately as project dependency (we have over 30 JARs that I need to specify). I love the support from IDEA which allows me to simply specify a folder and IDEA will automatically scan all JAR files in it.

    I will stop here, although I could name a few more. Hope NetBeans 6.5 will address some of these issues. I will definitely give it a shot once it comes out of beta.

    And by the way, I am definitely not an advanced NetBeans user, so if I missed any features of NetBeans that already solve these problems, please comment on this blog.

    10

    View comments

  2. GridGain team usually gives lots of JUG presentation. Last week we presented at Minneapolis and Denver JUGs. We usually go over power point presentation followed by our live coding demo. The way our coding demos are different from others is that we don't have any pre-written code. We start from a blank IDEA or Eclipse project and within 15 minutes we have our first Java application grid-enabled.

    I really enjoy giving out the coding demos whenever I get a chance. You really see the "WOW" effect on people's faces when without any explicit deployment or configuration you just run your project in Eclipse or IDEA and it automatically executes on the grid nodes that I have started on the same laptop. We usually keep it simple and present grid-enabled "Hello World" example having "Hello" printed on one node and "World" on another.

    However, during Denver JUG something interesting happened. During the coding demo, one of the people in the audience downloaded GridGain and started a grid node on the laptop he brought in. As IP-Multicast was enabled on the local WiFi network, his node immediately joined the grid nodes running on the presenter's laptop. The effect was great - the word "Hello" printed on one laptop, and the word "World" - on the other laptop.

    This really shows and proves how developers can get started on GridGain within minutes. The guy at the JUG never used GridGain before, but was able to start his first GridGain node right during the presentation. And, moreover, his node, running on his laptop, immediately started participating in grid task execution while he was simply seating and listening in the audience.

    Does not get any better than this!
    2

    View comments


  3. From the get go we put developers productivity as one of our main goals without sacrificing any enterprise grid computing features. But then you would think – how easy can it really get, any product can be installed and set up relatively easy. Here is a good analogy for you – think IPhone. I never thought that using my Motorola cell phone was hard, but IPhone just makes my life a lot easier. I can now check weather or flight status within seconds (things I didn’t even bother doing on my old cell phone). The same kind of productivity you get with GridGain. Take a look at some of the GridGain features that make it so easy to use and work with.

    Uniform Programing Model
    This basicaly means that your application should produce the same results wthether there is no grid, 1 node in the grid, or a 1000 nodes in the grid (of course the more nodes you add, the faster and more scalable your application should become). When writing your boiler plate code you should not worry about grid-enabling it. However, if you ever do need to grid-enable it, grid-enabling logic should be orthogonal to your business logic. GridGain provides two ways you can grid-enable your code.

    Transparent Grid-Enabling
    With transparent grid enabling you can move execution of your code to the grid by simply attaching @Gridify annotation to it, like so:

    public class BizLogic {
    @Gridify
    public Object process(Object arg) throws ProcessException {
    // Perform bizness logic here.
    }
    }
    Without GridGain, method process(..) above would simply run locally, as usual. However, by simply attaching @Gridify annotation, the execution of this method will be taken to a remote grid node. This alone can significantly improve scalability of your application, as now you have automatic fail-over, node topology management, and load balancing provided to you by GridGain out of the box.

    Now, if you decided that your method process(..) takes to long and you need to split its execution, you would need to implement GridTask interface to tell GridGain how your logic will be split. However, the only change you would need to make to your main code is specify which task it should use like so:

    @Gridify(taskClass = MyProcessTask.class)

    API-based Grid Enabling
    If you would like to use direct API calls instead of @Gridify annotation or if you need to wait for results asynchronously, GridGain allows you to do it as well. Simply invoke any of the Grid.execute(..) methods directly as following:

    Grid grid = GridFactory.start();

    // Execute.
    GridTaskFuture<Object> future =
    grid.execute(MyProcessTask.class, /*task argument*/someArg);

    // Wait for result.
    Object result = future.get();
    Or for asynchronous execution you would execute your task as follows:

    GridTaskListener resultListener = new MyProcessTaskResultListener();

    grid.execute(MyProcessTask.class, someArg, resultListener);

    Zero Deployment
    This means that you don’t need to explicitly deploy your code when using GridGain. When developing with GridGain, you can simply start up several grid instances, and then write your code in the IDE of your choice as you would usually do. When ready to execute, just click Run button in your IDE and watch your code execute on the grid. All the classes and resources will be automatically deployed to all participating grid nodes absolutely transparently to a user.

    Just think how much time you will save from not having to constantly run Ant or Maven builds to deploy your code to all remote nodes. Every time you change your code, just hit a Run button and GridGain will automatically detect that and load the changed classes.

    Simple Startup
    GridGain startup is as easy as it gets – just execute gridgain.sh or gridgain.bat scripts under bin folder and you got your grid node. There are no ports or IP addresses to configure, it all happens automatically (of course you have an option to change it if you have a need).

    But there is more. You can start multiple instances of grid nodes on the same box without any extra effort. Just think how much time you would have to spend trying to configure multiple instances of JBoss on the same machine – it’s doable, but it’s not easy. With GridGain, you just execute the same startup script multiple times and that’s it - you got your grid on your laptop. When developing and testing on your local box, this does come in handy.

    On top of that, you can start multiple GridGain instances in the same VM. This becomes extremely useful during debugging. Just set breakpoints in your code as you would usually do locally, hit Debug button in your IDE and you are able to step through your code as it executes on the grid. You don’t need to setup remote debugging to run your code “remotely”.

    Testability
    Testability of a distributed system is always a big issue. However, with GridGain, ability to startup multiple grid instances in the same VM makes writing Unit Tests extremely easy. Simply startup several grid nodes within the same test and perform all the necessary checks. Here is a simple JUnit3 example:

    public MyGridTest extends TestCase {
    // Simple test case.
    public void testGrid() throws Exception {
    GridConfiguration cfg1 = new GridConfigurationAdapter();
    GridConfiguration cfg2 = new GridConfigurationAdapter();

    cfg1.setGridName("grid1");
    cfg2.setGridName("grid2");

    try {
    Grid grid1 = GridFactory.start(cfg1);
    Grid grid2 = GridFactory.start(cfg2);

    GridTaskFuture<Object> future = grid1.execute(MyTestTask.class, ...);

    Object result = future.get();

    assertNotNull(result);
    }
    finally {
    GridFactory.stop("grid1", true);
    GridFactory.stop("grid2", true);
    }
    }
    }
    I guess I will stop here, otherwise this post will never end :)

    Please visit GridGain Website for more features and developer documentation.

    3

    View comments

About me
About me
- Antoine de Saint-Exupery -
- Antoine de Saint-Exupery -
"A designer knows he has achieved perfection not when there is nothing left to add, but when there is nothing left to take away."
Blog Archive
Blogs I frequent
Loading
Dynamic Views theme. Powered by Blogger.