Re: Integrating GWT with the existing webapp

2009-05-04 Thread newtoGWT


Hi Sumit,

Thanks for ur reply, it really helped me.
The architecture which we follow is bit older than struts (though it
has some flavour of struts).
After browsing through the forums & documentation, i got a confidence
in integration of GWT with out any issues.
As you said i too feel RPC would be the better option for server
communication.

Thanks,
Ganesh R

On Apr 29, 12:59 pm, Sumit Chandel  wrote:
> Hi Ganesh,
> Although I'm not totally sure of your GWT integration goals, I imagine they
> involve a smoother user experience by Ajax-ifying your application.
>
> If that's the case, my advice would be to take steps to eventually end up in
> situation 2) described above. Depending on how your business logic flows
> through your server-side, you could potentially implement RPC services that
> would replace existing action servlets and over time, redefine your
> server-side architecture in terms of GWT RPC services.
>
> This might seem like an all or nothing approach, but it will lead to a net
> win in terms of application performance. If you're not looking to totally
> redefine your application and just add Ajax bits to it using GWT, that can
> be done too. Let me know if you want to consider doing that and I would be
> happy to provide more info (or a quick search for "RootPanel.get("id").add"
> on the group should turn up some useful results).
>
> As you mentioned, using solution 2) will effectively break and require
> replacing your existing Struts-style architecture. However, I don't think
> that will affect the scalability of your application in terms of server
> load. In fact, it should make your application even more scalable since
> extra roundtrips would be avoided. Unless you meant scalability of your code
> base for maintenance purposes, in which case I still don't think it will
> lead to scalability problems.
>
> Hope that helps,
> -Sumit Chandel
>
>
>
> On Sun, Apr 26, 2009 at 11:41 PM, newtoGWT  wrote:
>
> > In the existing webapplication,
>
> > my action class receives the request, validates it, hits the DAO,
> > builds the Value Object (nothing but a bean class), and finally
> > returns the VO to the action class. This value object is then set into
> > session and retrieved in JSP page. (Normal request and response model)
>
> > To implement GWT in the existing webapp,
> >  1. Using HTTP request to call my action class, convert the value
> > object in JSON and write it in to response. Access the json in GWT
> > class and paint the page.
> >     Advantages:   i am not breaking my existing architecture, going
> > through action class.
> >   Disadvantages: Extra round trip to convert value object to json and
> > vice versa.
>
> > 2. Using RPC to call service method directly and get the value object
> > from service directly.
> >     Advantages:   I can get my value object with out any extra round
> > trip.
> >   Disadvantages: Breaking my existing architecture, by calling
> > service directly (coz scalability might be an issue later, just a
> > futuristic thought not sure though).
>
> > Above 2 approaches has their own adv. & disadv. please guide to choose
> > the best solution/approach to follow so that GWT can be integrated
> > successfully without issues.
>
> > Thanks,
> > Ganesh R
>
> > Disclaimer:
> > i am a beginner in GWT! so question can be silly some times :)- Hide quoted 
> > text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Json string parser displaying ""

2009-04-29 Thread newtoGWT


Please find my code below:

Inside action class
 import net.sf.json.JSON;
 import net.sf.json.JSONSerializer;
 ...
 ...
 ValueBean value = new VallueBean();
 value.setPlainText("Search Result");
 JSON json = JSONSerializer.toJSON(writingsAssetValue);
 response.getWriter().write(json.toString());

Inside GWT class
 public void onResponseReceived(Request request, Response
response) {
  if (200 == response.getStatusCode()) {
  JSONValue jsonValue = JSONParser.parse(response.getText
());
  searchButton.setEnabled(true);
  Window.alert(jsonValue.toString());
  Window.alert(jsonValue.isObject().get
("plainText").toString().replace("\"", ""));
  flexTable.setHTML(row, 1, value.isObject().get
("plainText").toString());
  } else {
// Handle the error.  Can get the status text from
response.getStatusText()
  }
}

The problem here is Window.alert(jsonValue.toString()); displays
"plainText":"Search Result"

but i expected Window.alert(jsonValue.isObject().get
("plainText").toString()) to display
Search Result (with out any double quotes) but it displayed as "Search
Result"

i  fixed this temp. by using replace method but i want to know whether
this is the only way by which i can fix the double quote issue? or
whether i am doing some thing wrong.

Any help on this would be appreciated..

Thanks!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Deployment of default GWT application.

2009-04-27 Thread newtoGWT

Did you test your application in hosted mode? try debugging it in the
hosted mode..

On Apr 27, 2:38 am, Dan King  wrote:
> Hi there,
>
> Can anyone give me any instructions on how to deploy the default GWT
> application. I have successfully gotten the client to appear properly
> in the browser by reference it as a website in Apache. The problem I
> am getting is when I click "Send" to send the name to the server I
> receive a Remote Procedure Call - Failure message. I'm not sure what I
> need to do. Any help is greatly appreciated as I am new to web
> development and GWT.
>
> Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Integrating GWT with the existing webapp

2009-04-26 Thread newtoGWT

In the existing webapplication,

my action class receives the request, validates it, hits the DAO,
builds the Value Object (nothing but a bean class), and finally
returns the VO to the action class. This value object is then set into
session and retrieved in JSP page. (Normal request and response model)

To implement GWT in the existing webapp,
 1. Using HTTP request to call my action class, convert the value
object in JSON and write it in to response. Access the json in GWT
class and paint the page.
 Advantages:   i am not breaking my existing architecture, going
through action class.
   Disadvantages: Extra round trip to convert value object to json and
vice versa.

2. Using RPC to call service method directly and get the value object
from service directly.
 Advantages:   I can get my value object with out any extra round
trip.
   Disadvantages: Breaking my existing architecture, by calling
service directly (coz scalability might be an issue later, just a
futuristic thought not sure though).

Above 2 approaches has their own adv. & disadv. please guide to choose
the best solution/approach to follow so that GWT can be integrated
successfully without issues.

Thanks,
Ganesh R

Disclaimer:
i am a beginner in GWT! so question can be silly some times :)

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



java.io.FileOutputStream is not supported by Google App Engine's JRE

2009-04-24 Thread newtoGWT


I am trying to merge my existing code base (web application) with GWT
but the compiler throws

"java.io.FileOutputStream is not supported by Google App Engine's Java
Runtime Environment"

in the existing code.

since my web application uses javax.naming.InitialContext, Context,
FileWriter etc...
i am unable to compile any of the files that uses above classes/
interfaces.

Any suggestion to this would be greatly helpful.

Thanks,
Ganesh R
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Creating GWT application

2009-04-24 Thread newtoGWT

hmmm.. i'll try out that too... Thanks!!

On Apr 22, 9:04 am, Rajeev Dayal  wrote:
> Glad that everything is working for you. As an FYI, if you have a proxy
> server that you can use to hit the Eclipse update site, you can configure
> Eclipse to use it when performing an update or an installation. In Eclipse
> 3.3, go to Windows -> Preferences -> Network Connections (or Eclipse ->
> Preferences -> Network Connections, if on the Mac).
>
> We'll definitely add some more documentation to help out people that are
> suffering with proxy issues.
>
>
>
> On Wed, Apr 22, 2009 at 5:37 AM, newtoGWT  wrote:
>
> > Hi Rajeev,
>
> > Thanks a ton! for your guide on installing the eclipse plugin. it
> > works great!!!
>
> > if these steps are listed as part of "http://code.google.com/eclipse/
> > docs/getting_started.html#installing<http://code.google.com/eclipse/%0Adocs/getting_started.html#installing>"
> > this web page,
> > it would help developers who are working behind a firewall or in the
> > cases where ppl facing problems in updating through eclipse.
>
> > >In the future, we'll make this whole process easier by providing a zip of
> > the plugin. -- Really great wud be easier too!!
>
> > >I just had a thought about this - are you behind a proxy?
>
> > offcourse i am working inside a secure network (that has firewall,
> > websense etc) i thinks thats blocking eclipse from installing plugins
> > directly...
>
> > Thanks,
> > Ganesh R
>
> > On Apr 21, 10:11 am, Rajeev Dayal  wrote:
> > > If you can't get Eclipse's install mechanism working, here's how you can
> > > install the plugin manually in Eclipse 3.3:
>
> > > Download the following file and place it in a temporary directory:
>
> > >http://dl.google.com/eclipse/plugin/3.3/site.xml
>
> > > Now, download the following into a directory called *features*,
> > underneath
> > > your temporary directory:
>
> >http://dl.google.com/eclipse/plugin/3.3/features/com.google.appengine
> > ..
>
> > > Finally, download the following into a directory called *plugins*,
> > > underneath your temporary directory:
>
> >http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.appengine.
> > ..
>
> > > If on linux:
> >http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> > > If on mac:
> >http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> > > If on windows:
> >http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> > > Now, go into Eclipse, and set up a local update site, and point it to the
> > > temporary directory that you created. You should be able to install the
> > > plugin from this "local" update site.
>
> > > In the future, we'll make this whole process easier by providing a zip of
> > > the plugin.
>
> > > On Tue, Apr 21, 2009 at 5:51 AM, newtoGWT  wrote:
>
> > > > "Network connection problems encountered during search.
> > > > Unable to access "http://dl.google.com/eclipse/plugin/3.3";.
> > > > Error parsing site stream. [Premature end of file.]
> > > > Premature end of file.
> > > > Error parsing site stream. [Premature end of file.]
> > > > Premature end of file."
>
> > > > I know this is not the exact stack trace but this is what it shows in
> > > > eclipse when i click on details button.
>
> > > > thanks for your info,http://dl.google.com/eclipse/plugin/3.3/site.xml
> > > > works!
> > > > Is there any downloadable jar file? so that i can directly unzip
> > > > inside eclipse plugins folder...(other than cypal).
>
> > > > On Apr 20, 10:47 am, rdayal  wrote:
> > > > > In your first post, when attempting to install the plugin, you
> > > > > mentioned that "it throws a network exception". Can you copy and
> > paste
> > > > > the stack trace?
>
> > > > > Also, hitting the URLhttp://dl.google.com/eclipse/plugin/3.3directly
> > > > > in the browser will not work, because this is not a browsable
> > > > > directory. If you want to see if the site works via a browser, try
> > > > > hittinghttp://dl.google.com/eclipse/plugin/3.3/site.xml
>
> > > > > On Apr 20, 7:02 am, newtoGWT  wrote:
>
> > > > > > yes you are right Darkflame!!
> > > > > > Its due to firewall... i am unable to connect to server..
> > > > > > i downloaded fromhttp://
> > code.google.com/p/cypal-studio/downloads/list
> > > > > > but the downside of cypal-studio is, it doesn't support GWT6 :(. it
> > > > > > shows whilecreatingGWTModule.- Hide quoted text -
>
> > > > > - Show quoted text -- Hide quoted text -
>
> > > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Creating GWT application

2009-04-22 Thread newtoGWT

Hi Rajeev,

Thanks a ton! for your guide on installing the eclipse plugin. it
works great!!!

if these steps are listed as part of "http://code.google.com/eclipse/
docs/getting_started.html#installing" this web page,
it would help developers who are working behind a firewall or in the
cases where ppl facing problems in updating through eclipse.

>In the future, we'll make this whole process easier by providing a zip of the 
>plugin. -- Really great wud be easier too!!

>I just had a thought about this - are you behind a proxy?

offcourse i am working inside a secure network (that has firewall,
websense etc) i thinks thats blocking eclipse from installing plugins
directly...

Thanks,
Ganesh R


On Apr 21, 10:11 am, Rajeev Dayal  wrote:
> If you can't get Eclipse's install mechanism working, here's how you can
> install the plugin manually in Eclipse 3.3:
>
> Download the following file and place it in a temporary directory:
>
> http://dl.google.com/eclipse/plugin/3.3/site.xml
>
> Now, download the following into a directory called *features*, underneath
> your temporary directory:
>
> http://dl.google.com/eclipse/plugin/3.3/features/com.google.appengine...http://dl.google.com/eclipse/plugin/3.3/features/com.google.gdt.eclip...http://dl.google.com/eclipse/plugin/3.3/features/com.google.gwt.eclip...
>
> Finally, download the following into a directory called *plugins*,
> underneath your temporary directory:
>
> http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.appenginehttp://dl.google.com/eclipse/plugin/3.3/plugins/com.google.appenginehttp://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gdt.eclips...http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gdt.eclips...http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> If on 
> linux:http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> If on 
> mac:http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> If on 
> windows:http://dl.google.com/eclipse/plugin/3.3/plugins/com.google.gwt.eclips...
>
> Now, go into Eclipse, and set up a local update site, and point it to the
> temporary directory that you created. You should be able to install the
> plugin from this "local" update site.
>
> In the future, we'll make this whole process easier by providing a zip of
> the plugin.
>
>
>
> On Tue, Apr 21, 2009 at 5:51 AM, newtoGWT  wrote:
>
> > "Network connection problems encountered during search.
> > Unable to access "http://dl.google.com/eclipse/plugin/3.3";.
> > Error parsing site stream. [Premature end of file.]
> > Premature end of file.
> > Error parsing site stream. [Premature end of file.]
> > Premature end of file."
>
> > I know this is not the exact stack trace but this is what it shows in
> > eclipse when i click on details button.
>
> > thanks for your info,http://dl.google.com/eclipse/plugin/3.3/site.xml
> > works!
> > Is there any downloadable jar file? so that i can directly unzip
> > inside eclipse plugins folder...(other than cypal).
>
> > On Apr 20, 10:47 am, rdayal  wrote:
> > > In your first post, when attempting to install the plugin, you
> > > mentioned that "it throws a network exception". Can you copy and paste
> > > the stack trace?
>
> > > Also, hitting the URLhttp://dl.google.com/eclipse/plugin/3.3directly
> > > in the browser will not work, because this is not a browsable
> > > directory. If you want to see if the site works via a browser, try
> > > hittinghttp://dl.google.com/eclipse/plugin/3.3/site.xml
>
> > > On Apr 20, 7:02 am, newtoGWT  wrote:
>
> > > > yes you are right Darkflame!!
> > > > Its due to firewall... i am unable to connect to server..
> > > > i downloaded fromhttp://code.google.com/p/cypal-studio/downloads/list
> > > > but the downside of cypal-studio is, it doesn't support GWT6 :(. it
> > > > shows whilecreatingGWTModule.- Hide quoted text -
>
> > > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Creating GWT application

2009-04-21 Thread newtoGWT


"Network connection problems encountered during search.
Unable to access "http://dl.google.com/eclipse/plugin/3.3";.
Error parsing site stream. [Premature end of file.]
Premature end of file.
Error parsing site stream. [Premature end of file.]
Premature end of file."

I know this is not the exact stack trace but this is what it shows in
eclipse when i click on details button.

thanks for your info, http://dl.google.com/eclipse/plugin/3.3/site.xml
works!
Is there any downloadable jar file? so that i can directly unzip
inside eclipse plugins folder...(other than cypal).

On Apr 20, 10:47 am, rdayal  wrote:
> In your first post, when attempting to install the plugin, you
> mentioned that "it throws a network exception". Can you copy and paste
> the stack trace?
>
> Also, hitting the URLhttp://dl.google.com/eclipse/plugin/3.3directly
> in the browser will not work, because this is not a browsable
> directory. If you want to see if the site works via a browser, try
> hittinghttp://dl.google.com/eclipse/plugin/3.3/site.xml
>
> On Apr 20, 7:02 am, newtoGWT  wrote:
>
>
>
> > yes you are right Darkflame!!
> > Its due to firewall... i am unable to connect to server..
> > i downloaded fromhttp://code.google.com/p/cypal-studio/downloads/list
> > but the downside of cypal-studio is, it doesn't support GWT6 :(. it
> > shows whilecreatingGWTModule.- Hide quoted text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Creating GWT application

2009-04-20 Thread newtoGWT

yes you are right Darkflame!!
Its due to firewall... i am unable to connect to server..
i downloaded from http://code.google.com/p/cypal-studio/downloads/list
but the downside of cypal-studio is, it doesn't support GWT6 :(. it
shows while creating GWT Module.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Creating GWT application

2009-04-09 Thread newtoGWT

I am a newbie in GWT.
1. i downloaded GWT6
2. i just followed the steps to install the eclispe plugin from
http://code.google.com/eclipse/docs/install-eclipse-3.3.html
sadly it throws the network exception. The url mentioned doesn't
work
"http://dl.google.com/eclipse/plugin/3.3";

it would be of great help if some one can give some guidance/pointers
for installing/using GWT applications.

Thanks in Advance!


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: FlexTable issues

2009-02-23 Thread NewToGWT

Thanks! Both the approaches solved my problem.


On Feb 22, 8:04 am, Mahavir Jain  wrote:
> Also you can loop through each row of the FlexTable in KeyBoardListener()
> like this:
>
> for(int i=0; i {
>     TextBox txt=(TextBox)table.getWidget(i, 0) //column is 0 because your
> textbox in first column
>      If (sender==txt)
>      {
>            //add your stuff relating to textbox
>      }
>
> }
>
> Hope this helps.
>
> Mahavir
>
> On Sun, Feb 22, 2009 at 8:06 PM, Bakulkumar  wrote:
>
> > Hi,
>
> > Set the name of textbox as an id of the record (or DTO, whatever you
> > call it).
>
> > and then:
>
> > textBox.addKeyboardListener(new KeyboardListenerAdapter() {
> >      public void onKeyPress(Widget sender, char keyCode, int
> > modifiers) {
> >        if (keyCode == (char) KEY_TAB){
> >          // TextBox.cancelKey() suppresses the current keyboard
> > event.
> >          String recordId = ((TextBox)sender).getName();
> >          // call the service with this id and on success update the
> > row
>
> >        }
> >      }
> >    });
> > Hope it should work.
>
> > -Bakul kumar
>
> > On Feb 20, 3:59 pm, NewToGWT  wrote:
> > > Hello,
>
> > > I have a FlexTable, the first column of each row in the FlexTable is a
> > > TextBox.
>
> > > I am calling a service to update the other elements (columns) of the
> > > FlexTable row based on what the user keyed into the text box in that
> > > row.
>
> > > The question I have is: How do I determine which row in the FlexTable
> > > the user keyed into and tabbed off of? I have  a keyboard listener
> > > attached to the TextBox. Using this istener, I am unable to figure out
> > > which row in the FlexTable was modified.
>
> > > Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



FlexTable issues

2009-02-20 Thread NewToGWT

Hello,

I have a FlexTable, the first column of each row in the FlexTable is a
TextBox.

I am calling a service to update the other elements (columns) of the
FlexTable row based on what the user keyed into the text box in that
row.

The question I have is: How do I determine which row in the FlexTable
the user keyed into and tabbed off of? I have  a keyboard listener
attached to the TextBox. Using this istener, I am unable to figure out
which row in the FlexTable was modified.

Thanks



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---