What benefits can Vaadin offer my GWT Appengine app? - google-app-engine

The GWT page on the Vaadin website is a bit sparse: https://vaadin.com/gwt
"Only benefits, no gotchas
You will enjoy everything you love in GWT and get the additional benefit of a novel server-side programming model, components, tools, themes and other extras. If you do not like what you are seeing, it is easy to return as long as you stick to using com.google.* packages. You will probably be tempted to start using features in com.vaadin.* packages eventually. But there is no need to worry—Vaadin Framework is also distributed under the same liberal Apache 2.0 license"
I like some of the look and feels on the Vaadin website, but I'm nervous about "server side models"... I would rather have most of the code running on the clientside if at all possible, and I'm checking GWT RPC calls again (often with the same java code) for security. I don't like the idea of lots of back and forth.
Given my concerns, is it worth digging deeper into Vaadin? Or do I stop here? Can I leverage the various look&feels without stomaching everything? Any other non-intuitive answers about leveraging would be appreciated.
UPDATE:
Please don't answer the question comparing Vaadin vs GWT, offering alternative UI frameworks.
I've also used SmartGWT, GXT, and bundled GWT widgets etc. Also familiar with some really complete widget sets like DevExpress for .NET . The reason I asked the question is because Vaadin LOOKS really cool... I'm looking for answers like : No, it's not possible to extract the L&F from Vaadin without compromising the clientside OR besides the L&F stuff, there is cool validation stuff etc etc etc which you can use, and then perhaps some useful evidence to back up that position (tried and failed).

I am answering only a part of the question about the L&F i.e GUI and Security.
1) L&F
Vaadin upto 6.x release does not support independent use of widgets. You need to get into the whole server side models.
However, from version 7 onwards Vaadin is leaning on spinning of Widget side to allow widget use without being forced to use the back/forth jsf like server-side state maintenance.
Reference - https://groups.google.com/forum/?fromgroups=#!topic/google-web-toolkit/3U1h0W_iHcM
2) Security
GWT side has pretty nice support with XSRF feature for RPC which would allow rpctoken generation per RPC call or selectively with your choice of granularity. This be might be a performance overhead for Vaadin roundtrip per sever-side-state call.
3) GAE is a factor depending on how heavy your Vaadin roundtrips really are.
4) Future
Vaadin is a member of GWT steering committee and along with Jboss Errai (asynchronous bean management in Errai roadmap) lean heavily on server side models.

Related

Hybrid App Maker vs Mobile Frameworks

When do you think is best to to use a mobile App Maker (Ex: Appery.io) and when to code using a framework (Ex: Ionic)?
Of course, that coding with a framework doesn't tie you to any App Maker label... But, besides that, any other matter I should consider.
I need to start a simple project that querys a some REST API and have some doubts.
So I thought about posting here to open my head to someone who has walked this road before.
I don't mean this to be an open ended question on what is the best framework and comparing them all. I am just trying to establish is it really necessary to go down the heavier more complicated frameworks or can I get a mature long term solution using something like Appery?
Thanks!
When it comes to mobile apps, and as in your case, apps that load dynamic data from server, it is usually better to go for mobile app frameworks rather than, for online app builders. There can be multiple reasons for this :
App builders usually come with a lot of features, but they almost always fail for some Custom client requirements.
They usually tend to cater the need for static apps, when it comes to dynamic apps that have a lot of data manipulation stuff, you should prefer your own framework and logic to do so..
You can almost everytime modify / tweak a framework, You can't do so with an appbuilder.
You aren't sharing your code on cloud [Matters if you are working for some critical organization / client].
You have total control over your code / view. You can tweak it, twist it and almost guarantee total ownership. All you are bound to is the limitation your framework imposes.
You can mix and match frameworks, that doesn't applies for an appbuilder.
These are some of my quick thoughts, there can be [and are] many more reasons for switching towards a mobile framework..
AppMakers are generally there as tools for Rapid Prototyping. These days they market that you can make production apps using Appmakers but when you start using them you will notice that one or some other requirement you have cannot be implemented. In my experience, app development time seems to be less for AppMakers but it is generally more. On the other hand Mobile App Frameworks provide a lot of flexibility and code reusability too.

Building mind map based webapp. Not sure which framework to choose

We are working on a Mind map based webapp as our final year college project. It will be a website where users will be able to create mind maps collaboratively. The user interface will be very similar to what https://bubbl.us/beta/ and hxxp://www.mindmeister.com/ have.
In a nutshell, the users will have access to whiteboard and drawing tools to create mind maps on a whiteboard. The changes made by one user will be visible to other session users. e.g. A session has three users A, B and C. If A changes mind map, it will be visible on whiteboards of B and C.
We were considering Flex, Openlaszlo few days ago but having limited time (about 3 months) for project completion, we binned those. For Flex we will have to learn Actionscript3 and for Openlaszlo there is no IDE support. So both of them won't be good choices.
We have shortlisted Silverlight and Vaadin frameworks as viable choices but we are confused as we don't have any experience with either of them. We need to take these points into consideration while selecting a framework:
Time frame for project - about 3 months, give or take 2-3 weeks
Learning curve for framework - should be easy (Very relative term indeed..In the context, we are familiar with VB6, PHP, Javascript and Core Java)
Necessary graphics related features supported - such as whiteboard, drag-drop widgets, animations(need not be fancy stuff) etc.
Availability of tutorials and good documentation
There are 2 open source mind mapping applications that can be useful for this webapp.
Silverlight - hxxp://silverdraw.codeplex.com/ (a webapp) - More like a POC design.
Java - hxxp://www.xmind.net/ (a desktop app) - Most of the mindmapping features we need are present. If we use Vaadin, we can re-use some code which is a huge plus point.
We are open to other suitable frameworks. Which framework would you choose?
P.S.: Excuse for obscure URLs'. New users are limited to only one hyperlink.
Disclaimer: I'm a member of the Vaadin Team, and do not know Silverlight very well.
I believe both Silverlight and Vaadin would be good candidates for your application, and for both the biggest challenge will be the client-side implementation of the visual mind-map component.
I took a quick look at XMind and it seems to be Swing based, so I'm afraid that the only way to re-use that would be to wrap the mapping component into an applet. You can easily do this with Vaadin, but it will require the Java plugin in the browser.
If you consider implementing the mindmap component without plugins, you have the following options:
Use the Vaadin core components (eg. the Tree, live example here) to visualize the mind map. Vaadin supports drag & drop, so this would be very fast to implement, and you would need to work with only server side Java stuff.
Create a HTML5 component with Vaadin integration for the mind-map. You can do this with the HTML5 canvas, and wrapping it in a Vaadin component is easy, but it'll require that you code the component with GWT. There are several examples on how to manipulate the canvas with Vaadin and GWT.
Create a SVG component with Vaadin integration for the mind-map. As far as I know SVG supports interactive stuff a little better than Canvas, and there are examples on how to interact with SVG using GWT and Vaadin. Note that the support for SVG is lacking especially with the older IE versions.
All of these options are feasible to implement within your timeframe (depending on what extra functionality you want). The first option is by far the easiest to do, but it might not be fancy enough for your requirements.
We have strived to make Vaadin as easy to learn and use as possible, and I daresay that our documentation is very good. In addition we have a very lively community filled with helpful experts. If you need more information on Vaadin just come over to our forums and we'll help you out.
You are kind off answering your own question. Use vaadin it will be a little extra work but then your saving huge amount of time on the mindmap coding.

While porting a windows application to web, is it better to stick to conventional web technologies or adoping RIA is wise?

The web based application I am working on currently is a port from a windows application. This application is very data intensive. There are scores of modules and each of these modules have number of forms (data entry screens) and reports whereas the forms have many many fields and likewise the reports.
I have been trying to identify the most suitable architecture for the presentation tier. There are many functions that are not very easily portable, for example printing (this too is very complex). For most of the others, I am planning to us "Ext JS" library which looks like capable of handling about 70% of complexity out of the box while for the remaining I would be custom coding or extending Ext JS.
Having said that (sorry for being so descriptive), I wonder, if this is an Intranet application, why not port the entire application to SilverLight? While I am good at .Net, I'm somewhat alien to SilverLight. Considering I know my target audience and that the software will be used per seat license, would it be better to ride on SilverLight or is it better to stick to conventional web (XHTML, JS, CSS, etc)? Further, I have to support multiple devices in future and considering that SilverLight plug-ins for many devices are yet not out, would it be a risk?
IMO, if you are developing a web application, then yes, develop it as an RIA.
The choice of technology is up to you. I prefer jQuery and have never used ExtJS. But I've taken a look at it, and if your aplication is a port of a windows application and has a lot of conventional UI elements like forms, input boxes, toolbars, menus, button etc, then go for ExtJS.
As for some controls that are not available in ExtJS, you can easily extend ExtJS.
Regarding .NET: ExtJS is completely server-technology agnostic, so you can develop your application in .NET and still use an ExtJS UI. In fact, I would prefer to do such an implementation.
Regarding Silverlight: I am slightly against using silverlight, primarily because it requires a plugin to be installed that is not available on all platforms. But since your application is an intranet application, your user base will be in your control. But you should make sure that any future decision regarding the workstation platform will not affect your application's working.
Cheers
Whether to use Silverlight over HTML/JS etc. in this case would depend on 2 key factors.
What are you familar with already
What type and range of devices you need to reach.
If you are already comfortable with HTML + ExtJS then that has to be huge pro in its favor.
The range of devices that Silverlight is possibly going to be available (Windows Phone 7 for example as well as Moonlight, I've even heard that there may be port for Andriod and Symbian) is growing. However its really early days for that and not all may materialise in a form useful to you.
Having said that it should be acknowledged that a UI designed for use on desktop does not work well on a small device. Hence you would need to develop some task specific UI for other devices regardless of the technology you use. This in turn means that there is no reason for you to try to stick with single technology for all devices.
I think you should look very carefully into WCF, REST and OData first. Good layering of the application into useful models using these would more easily enable the use of a variety of front-end technologies for the client.
If you are into .NET and other Microsoft tech then you should seriously consider using JQuery and ASP.NET MVC as another potential front end technology.
I think that you need to ponder the inconveniences of a solution based solely in Silverlight. Like Flash it needs a plugin to be installed in every station, so it loses some of the premises of web applications (run everywhere with the only requirement of a browser). Besides although Silverlight has taken great advances, it is not yet a widely supported standard, and it is in control of a company who later may decide for you in very important matters regarding the platform you use, and made it outdated or useless (in the worst case).
Ext JS is a great library developed entirely in Javascript, so you can touch anything that suits your needs. If the Windows applications you are basing on is well-layered, then your work may not be that hard.
If you are an asp.net developer you could take a look on asp.net mvc, a great set of tools that implements MVC pattern to web applications using the same old C# or VB. Besides the developers behind asp.net mvc, have taken a lot of work to make it suitable to work with javascript libraries like jQuery
Happy coding!!!

WebForms / MVC to a Windows Forms programmer

First I'd like to make it clear, I'm not looking for a "my tech is better than yours" type of post; this is a real case scenario and I have been faced with this decision. With this in mind, let me explain:
We have a WinForms application. It started in the early .NET 1.0 but the first shipping version was using .NET 1.1. There are layers (like BusinessLayer.dll, Datalayer.dll, Framework.DLL, etc.) but at some point during the "long" development cycle of this application, the "presentation" layer (Win Forms) got infected with some code, thus the "separation between the code and the presentation with code behind" is some sort of myth.
Bad practices or whatever, the truth is that the application is there and it works.
Years passed and we had .NET 2.0, we slowly migrated and it mostly worked, had to change a few calls here and there. Last version did the same thing, but for .NET 3.5sp1. We needed some sort of Webservices thing, and decided to use WCF instead. It works fine.
But despite all these .NET upgrades, most of the application's codebase is still the same old rock and roll from 5 years ago. We use Gentle.NET (old and unmaintained now) for our dataobjects (it was a blessing 5 years ago!).
Our presentation layer, the winforms, are "nice looking" since we employ 90% of completely gdi+ custom controls. (whenever possible without having to hack the WinAPi). The application is touch based (i.e.: it makes use of the Ink but it doesn't rely on that), but the buttons, labels, etc, everything is "designed" to be used with a tactile device. (TabletPC or Touchscreen). Of course some users use keyboard/mouse.
With all that in mind, and with all this web2.0 and Internet fuzz (plus Jeff's posts ;) ), we are considering the possibility of rewriting the application but using a web technology.
The idea is obviously bringing more availability for our customers (they can use the system whenever/wherever they want), and less maintenance (we can upgrade and it is an instant upgrade for 'em all), etc. You know, the usual Internet vs WinApp thingy.
The problem is that given that this is the healthcare industry, not all of our customers might be willing to "move" their databases to our server/s, which is acceptable, and would force us to install a webserver/database server in their own servers so they have their own copy. Not a big problem (except we would have to update those manually but that's not an issue, given that we've been updating win32 apps for 5 years now!).
Now, back to the main "question".
The team has little Asp.NET experience, we did program a lot in ASP 2.0 (in 1999/2000) but that was a spaghetti of HTML+VBScript+CSS, so I don't think it counts. After all that experience (the Internet bubble!) we went back to VB6 then C#.NET 1x and you know the rest of the story. We're a small team of C# developers for WinForms. We've acquired some Linq To SQL Experience in our last .NET 3.5 ride, and we liked it. We felt it very natural and very "if we would have had this five years ago…" like.
Given all this, rewriting the application is not a "simple task" (not even if we wanted to do it in the already known C#.NET), it would take time and planning, but we could correct dozens of mistakes and with 5 years of experience working with the application, we now can say that we have a better idea of how the customers would like to use the software and what limitations we created (by ourselves) when we designed the current app.
All that "knowledge" of the application and the way the business works, could be applied to produce a much better application in terms of design and code and usability. Remember in .NET 1.1 we didn't even have generics! ;) (you'll see lots of ArrayList's hanging around here).
As an additional note, we use Crystal Reports (and, as usual, we hate it). We don't think the ink control is a "must" either. The HTML/CSS could be shaped to look the way we want it, although we're aware that HTML is not WinForms (and hence some things cannot be reproduced).
Do you think that planning this in MVC (or WebForms) would be too crazy?
I like the MVC (ruby on rails like) idea (I've never programmed in ruby beyond the basics of the book), so no one in our team is an expert, but we can always learn and read. It mustn't be "rocket science", must it?
I know that this whole question might be a little bit subjective, but would you replace an aging Winforms application with a new ASP/MVC/XXX web application? Do you have experience or have tried (and had success or failed) ?
Any insight in helping use better decide what to do will be appreciated.
Thanks in advance!
UPDATE: Thanks to all who responded, we'll evaluate whether this is a good move or not, it sure is a hell of work, but I am afraid the the desktop app is getting older (using old net 1.1 hacks) and tho it has been more or less working without problems in Vista and W7, I'm afraid a future update may break it.
Also, lots of "more or less core" parts of the application are exposing some badly designed ideas and we had to hack here and there to accomplish certain tasks. Part inexperience, part lack of 100% knowledge of how the business worked (and Customers not sure what they wanted).
A new application (in any form) would allow us to create a better foundation while retaining all the user knowledge.
But, it's a L O T of work :) So we'll consider all these options here.
As some of you have mentioned, maybe a thinner client and some (ab)use of WCF here and there might be more appropriate.
Once again, thanks to all!
It would be best to ditch all your efforts of reusing the desktop application code when you recreate the web app. Following are the reasons:
Web apps especially asp.net use a different model. For starters note http is stateless. Each time the browser talks to server you have to explicitly send the current content of all the controls on the current page. You would not have used such a model in your Windows application.
To decrease load on the network you want to optimize the size of viewstate and how frequent you make http requests. Again your existing window app does not have any such provisions.
Updating view. You might have different event handlers, threads and what not in your windows application to update the GUI in different scenarios. All of that will need to be replaced. Javascript is a totally different animal.
Security. When using a browser your access to the local disk is highly limited whereas you will take the same for granted in windows application. If there is any code in the windows app that requires local resources, then that is going to be a trouble spot for you.
I would recommend the following:
Verify if your current application has any local disk access requirements (e.g. read/write to local file etc).
As you write the different http modules or handlers, you can try leveraging some of the backend/ business logic part of the existing windows application.
Give some thought to what part of your application can become a web service.
It sounds like the application needs a lot of refactoring to clean it up. If you want to move to a web model, and have maximum reuse you will really need to do that. Before you move to a web model I think you need to understand if it will be possible to replicate your user interface in that model. Is it your unique selling point from a customer perspective? You want decisions like this to be user driven rather than purely technical decisions.
It sounds like your application is the perfect candidate for a thick client application, rather than the lowest common denominator web model.
Some things to consider:
How will the web interface impact the Tablet interaction?
What new customers will having a web version bring you?
Will existing customers abandon your product?
Do you have access to consultants or outside resource with the right skills to mentor you in web technology? If you don't you can rely on StackOverflow or other web resources to help. You need some good mentoring and guidance on the ground with you.
What happens if you start this effort and it takes much longer than you expect? You know the app but don't sound like you know the web. Past experience shows that massive rewrites like this can end in disaster (it never sounds so difficult at the start)
Can you possibly write new features in a web-based version?
Could you move to ClickOnce deployment to make the application easier to deploy to customers. One of the benefits of the web is easier (zero) deployment. Can you get closer to that?
Would it be easier to migrate to WPF and create a browser application with that?
Silverlight or Flex might be better options for creating a rich experience, and may be more approachable for WinForms developers. Is this a possibility?
It seems like your app. is one of those that works best as a desktop app. Though you want your users to be able to access your app. using a browser.
I would suggest refactoring as much as possible so that the GUI gets cleaner and don't have "code".
When you've done this, start developing a asp.net mvc app but keep your desktop app. You should be able to use all layers except the UI layer, making it easier/faster/... Now that mvc exists, I'd say webforms is more about letting non-web devs do web. But you know web, sort of, and you want control so mvc is the way to go.

What are the topics to ramp-up on when starting Silverlight\Web development?

I've been asked to do some work on an existing Silverlight project, mainly extending it a bit and doing bug fixes as needed. But there are a couple of ASP.Net pages too and a WCF service to deal with too. My background is desktop development with .Net so I think this is a good opportunity to start getting more involved in Web development.
So I'm trying to figure out what background knowledge I need for a project like this. Clearly I need to get familiar with Silverlight, but I'm not sure what other Web technologies, etc I need to ramp up on for this project. Obviously I would like to know as much as possible but in reality with limited time and resources I really need to focus on what I important in the near term for this project. Then expand my knowledge as things arise.
The things I'm thinking that are important in the immediate future are:
The basics of Web Development (I'm thinking this might be the most important\fundamental area to build a good foundation)
But what are consided the basics?
What is technology\language independent?
What is important for Silverlight?
The basics of ASP.Net (since there is some ASP.Net code)
What are the basics? ASP.net seems so huge, I have a 1000+ pg book here which seems daunting.
If you focus on Silverlight is knowing ASP.Net important, or is ASP.Net something I will continually run into?
How does ASP.Net MVC fit into the overall development picture and especially as related to Silverlight?
The basics of WCF
As compared what?
Any suggestions\comments on the list above?
What other topics\technologies will I run into if I continue doing Web development?
Note: Beyond this project I would focus on the Microsoft stack.
Generally speaking the amount of knowledge of ASP.Net you need to do Silverlight development is very very low.
Silverlight applications are hosted in a browser, usually via the <object> tag. This can sit on an asp.net page or a html page. The Silverlight template creates that for you, so you can forget its there and just get on with the Silverlight app.
Of course if you are integrating into an ASP.net environment (for example, islands of Silverlight sprinkled through an ASP.net site) then thats another thing. There are ways to get Silverlight talking to the HTML dom via the HTML Bridge but its not necessary. Really depends on what you are developing and integrating with. (new site vs existing)
I avoided ASP.net for as much as i could as the richness compared to desktop (WPF) just wasnt there. Silverlight changed all that. Its a Rich world on the web now!
Best place to start learning Silverlight is www.silverlight.net on the getting started part of the site. great Quickstarts and tutorials there.
Good luck
Only cursory knowledge of traditional web technologies (css, html, js, etc.) are necessary for silverlight development. As a consequence, you also don't need to understand the many cross-browser dependencies as well.
Here is my list of things that you must get a really good understanding of to be proficient at Silverlight development:
Understanding WCF (the Silverlight-supported parts) is essential. It can be a configration nightmare, but once working it is pretty stable/ reliable
You need to understand serialization used by WCF and how to debug the mysterious 404 errors. Get good at Fiddler and/or Firebug.
You must understand multi-threaded applications and how do debug them. Silverlight makes extensive use of threading to not block the UI thread. This creates numerous opportunities for race conditions that create what appear to be "magical" results. That said, it is incredibly powerful and IMHO one of the dominant reasons to use Silverlight.
What you learn about serialization and WCF will ultimately help you cache some data in IsolatedStorage. Learn about IsoStorage, it will reduce our bandwidth requirements and cost and improve your user experience
Learn about Linq - again this is one of the most powerful features of Silverlight. Combined with a smart client-side caching strategy you can offload lots of processing to the client.
Figure out how you going to support printing. SL3 does not at all and you will need a server side component. SL4 beta does, but it is not go live
Understand the Silverlight Roadmap as much as possible and plan out your roadmap to match/ sync with it as best as possible. I first built a SL2 app and I spent a lot of time building things by hand that were ultimately released in SL3. As it is getting more mature, there is less of this.
Download the Silverlight Toolkit and use it. But more importantly examine the source code, the structures, its build process. There is not better real world place to look for inspiration & best practices.
Good luck.

Resources