Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #6157

Re: Support for both Web and Desktop front-ends [Architecture]

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail
From Tom <tom400f@gmail.com>
Newsgroups comp.lang.java.programmer
Subject Re: Support for both Web and Desktop front-ends [Architecture]
Date Wed, 13 Jul 2011 10:34:08 +0000 (UTC)
Organization Aioe.org NNTP Server
Lines 51
Message-ID <pan.2011.07.13.10.34.09@gmail.com> (permalink)
References <ivj45r$hvl$1@speranza.aioe.org>
NNTP-Posting-Host kyiEPMrZYa1k6vhLW1G2ZQ.user.speranza.aioe.org
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding 8bit
X-Complaints-To abuse@aioe.org
User-Agent Pan/0.133 (House of Butterflies)
X-Notice Filtered by postfilter v. 0.8.2
Xref x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:6157

Show key headers only | View raw


On Wed, 13 Jul 2011 11:41:40 +0800, Warren Tang wrote:

> I'm about to develop an application which needs to support both Web
> client and desktop client. Is there any existing tools/practices I can
> use? Or any suggestions?
> 
> Recently I've done a project with Google Web Toolkit(GWT) + myBatis.
> Newly shifted from .NET Framework to Java, my current knowledge set is
> limited to core java, no Java EE or Spring experience (though I have
> plans to learn them).So lightweight is preferred.
> 
> Maybe I can use GWT + Spring + myBatis? For the desktop front-end I
> should use Swing + Spring + MyBatis? The Spring MVC can handle the two
> front-ends and make sharing business logic easier?

The issue is you need client and server (where these terms are
used in their general sense) that are agnostic of one another yet
support both web/desktop. In our products we started with desktop
apps but now we want web versions too.

You don't say what your desktop platform would be but as you've
posted in the Java group..... we developed our own server
implementation and c/s architecture for (desktop) clients. We
jettisoned the whole idea of object-relational mapping and indeed
anything to do with /implementing the application/ using OO, preferring
to regard all data as just a tree. After all, this is what the
document object model is so why introduce all the OO noise?

Anyway, our desktop client is swing and uses serialisation to/from
the server. There is no soap/rmi, just sockets. Events are both
ways so the client is sync'd as the server sees fit. Because all data
is just trees, MVC with the desktop is automatic (you don't have to
code that). We have transactions, locking and so forth.

When we came to consider web front ends, our data model
lends itself to the generation of json so we wrote a simple servlet
that processes service requests from the browser and generates
the tree in that form (rather than serialising it to the desktop
client as it would normally). We looked around for a suitable
browser framework and chose qooxdoo:
http://manual.qooxdoo.org/1.4/pages/introduction/about.html
(Its not html/css etc so not sure if that is the sort of
web client you want)

This means that we can use the same server-side code for both
types of client (with a little use of modularisation). Deep link:
http://www.inqwell.com/examples/petstore/myorders.html#serverstruct

The qooxdoo/javascript integration work we have to do is still in
progress but we've got trees/tables etc working and we're free
of J2EE/JPA/Hibernate etc, which we don't want.

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Support for both Web and Desktop front-ends [Architecture] Warren Tang <nospam@tangcs.com> - 2011-07-13 11:41 +0800
  Re: Support for both Web and Desktop front-ends [Architecture] markspace <-@.> - 2011-07-12 21:21 -0700
    Re: Support for both Web and Desktop front-ends [Architecture] Arne Vajhøj <arne@vajhoej.dk> - 2011-07-21 18:53 -0400
      separated by a common language "Richard Maher" <maher_rj@hotspamnotmail.com> - 2011-07-24 08:13 +0800
        Re: separated by a common language Arne Vajhøj <arne@vajhoej.dk> - 2011-07-23 21:37 -0400
  Re: Support for both Web and Desktop front-ends [Architecture] Tom <tom400f@gmail.com> - 2011-07-13 10:34 +0000
    Re: Support for both Web and Desktop front-ends [Architecture] Tom <tom400f@gmail.com> - 2011-07-13 12:28 +0000
  Re: Support for both Web and Desktop front-ends [Architecture] Arved Sandstrom <asandstrom3minus1@eastlink.ca> - 2011-07-13 07:36 -0300
  Re: Support for both Web and Desktop front-ends [Architecture] jebblue <n@n.nnn> - 2011-07-13 22:17 -0500
  Re: Support for both Web and Desktop front-ends [Architecture] Roedy Green <see_website@mindprod.com.invalid> - 2011-07-13 21:22 -0700
    Re: Support for both Web and Desktop front-ends [Architecture] Arne Vajhøj <arne@vajhoej.dk> - 2011-07-21 18:45 -0400
  Re: Support for both Web and Desktop front-ends [Architecture] Kristian Rink <kr@zimmer428.net> - 2011-07-14 13:06 +0200
  Re: Support for both Web and Desktop front-ends [Architecture] Arne Vajhøj <arne@vajhoej.dk> - 2011-07-21 18:33 -0400

csiph-web