Re: [appengine-java] Apache POI spreadsheet autoSizeColumn() throws NoClassDefFoundError

2012-01-29 Thread George Simon K
Hi Mathew,

POI uses GAE restricted classes.
Please refer to
http://code.google.com/p/googleappengine/wiki/WillItPlayInJava
Alternate way is to use jxl library.

Thanks
George

On Sun, Jan 29, 2012 at 7:17 AM, Matthew Johnson
ijustmakecof...@gmail.comwrote:

 I'm working on an export to XLS service using Apache POI 3.6, and I've
 encountered a NoClassDefFoundError exception when using the autosize column
 feature.

 The code:

 Sheet sheet = wb.createSheet(Viewpath Timesheet (date range));
 PrintSetup printSetup = sheet.getPrintSetup();
 printSetup.setLandscape(true);
 sheet.setFitToPage(true);
 sheet.setHorizontallyCenter(true);

 //Set first four columns width to autosize.
 for (int i = 0; i = 4; i++) {
 sheet.autoSizeColumn(i);  //Commenting this line out resolves the
 error.
 }

 Produces...

 WARNING: /export/timesheet
 javax.servlet.ServletException: java.lang.NoClassDefFoundError:
 java.awt.font.FontRenderContext is a restricted class. Please see the
 Google  App Engine developer's guide for more details.
 at
 org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:862)
 at
 org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:791)
 at org.apache.jsp.export.timesheet_jsp._jspService(timesheet_jsp.java:406)
 ...
 Caused by: java.lang.NoClassDefFoundError: java.awt.font.FontRenderContext
 is a restricted class. Please see the Google  App Engine developer's guide
 for more details.
 at
 com.google.appengine.tools.development.agent.runtime.Runtime.reject(Runtime.java:51)
 at
 org.apache.poi.hssf.usermodel.HSSFSheet.autoSizeColumn(HSSFSheet.java:1694)
 at
 org.apache.poi.hssf.usermodel.HSSFSheet.autoSizeColumn(HSSFSheet.java:1662)
 at org.apache.jsp.export.timesheet_jsp.toXls(timesheet_jsp.java:154)
 at org.apache.jsp.export.timesheet_jsp._jspService(timesheet_jsp.java:396)

 ...Whaa..? Like a good baby-java dev, I checked the GAE developers guide
 as directed, but couldn't find anything useful. I upgraded to POI 3.7 for
 kicks, but the error remained. Anyone have experience with POI + Excel
 Spreadsheets + GAE? Anyone? ...Bueller?

 Cheers,
 Matthew

 --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



Re: [appengine-java] OAuth and google chrome

2012-01-18 Thread George Simon K
Hi Chris,

Solution to your problem can be fixed by moving
oauthParameters.setOAuthCallback(http://myappengine/connect.jsp;);
after oauthHelper.getUnauthorizedRequestToken(oauthParameters);

But this is oauth 1.0 not the updated 1.0.a, means you won't receive a
verifer id and will have the yellow warning message. Solution to this

1. Make no changes in step one index.jsp as you have written now.
2. In Connect jsp
*  String accessToken = request.getParameter(oauth_token);
  oauthParameters.setOAuthToken(accessToken);*
  oauthParameters.setOAuthTokenSecret(Unauthorizedtoken);

oauthHelper.getOAuthParametersFromCallback(request.getQueryString(),oauthParameters);
  String accessToken =oauthHelper.getAccessToken(oauthParameters);
  String accessTokenSecret =  oauthParameters.getOAuthTokenSecret();


Thanks
George

On Thu, Jan 19, 2012 at 12:46 AM, Ikai Lan (Google) ika...@google.comwrote:

 This is strange - there should be nothing browser specific about the
 session.

 Try to isolate the behavior by removing OAuth out of the equation. What
 happens when you store a variable in session scope without the OAuth flow?
 Does it change each time?

 --
 Ikai Lan
 Developer Programs Engineer, Google App Engine
 plus.ikailan.com



 On Tue, Jan 17, 2012 at 3:14 AM, Christopher Gabin 
 christopher.ga...@ogys.fr wrote:

 Hi everyone !

 I'm looking for a solution to run my connection oauth with google
 chrome. currently my code only works on firefox and IE but not on
 google chrome because when I persist in my OAuthTokenSecret a session
 variable when google redirect back on my aplication the value of the
 OAuthTokenSecret in the session variable has changed.


 my code JAVA :

 step one index.jsp

 GoogleOAuthParameters oauthParameters = new GoogleOAuthParameters();
oauthParameters.setOAuthConsumerKey(CONSUMER_KEY);
oauthParameters.setOAuthConsumerSecret(CONSUMER_SECRET);
oauthParameters.setScope(
 https://www.google.com/calendar/feeds/
 https://spreadsheets.google.com/feeds/;);
oauthParameters.setOAuthCallback(
 http://myappengine/connect.jsp;);

GoogleOAuthHelper oauthHelper = new GoogleOAuthHelper(new
 OAuthHmacSha1Signer());
oauthHelper.getUnauthorizedRequestToken(oauthParameters);
String unauth = oauthParameters.getOAuthTokenSecret();
request.getSession(true).setAttribute(accessTokenSecret,
 unauth);

out.println(a
 href='+oauthHelper.createUserAuthorizationUrl(oauthParameters)+'log
 in/a);

 step two after redirect connect.jsp

 //google chrome on the value changes each time I refreshed the page
String Unauthorizedtoken =
 (String)request.getSession(true).getAttribute(accessTokenSecret);


GoogleOAuthParameters oauthParameters = new
 GoogleOAuthParameters();
oauthParameters.setOAuthConsumerKey(CONSUMER_KEY);
oauthParameters.setOAuthConsumerSecret(CONSUMER_SECRET);
oauthParameters.setOAuthTokenSecret(Unauthorizedtoken);
GoogleOAuthHelper oauthHelper = new GoogleOAuthHelper(new
 OAuthHmacSha1Signer());

  oauthHelper.getOAuthParametersFromCallback(request.getQueryString(),
 oauthParameters);
String accessToken
 =oauthHelper.getAccessToken(oauthParameters);
String accessTokenSecret =
  oauthParameters.getOAuthTokenSecret();


  People, your help is really needed here.

  Thanks,

 Christopher

 --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



Re: [appengine-java] Re: @Google: Are you working on UserService running with OpenId?

2011-07-14 Thread George Simon K
Hi Daniel,
Were you able to figure out Step2 integrated with UserService.
Your help greatly appreciated.

Thanks
George

On Thu, Mar 18, 2010 at 6:03 AM, Conor Power iamco...@gmail.com wrote:

 would be great if you could share your solution with the community ...



 On Wed, Mar 17, 2010 at 8:11 PM, dflorey daniel.flo...@gmail.com wrote:

 I finally managed to get it up and running - but an integration with
 UserService would be highly appreciated




 On Mar 10, 5:03 pm, dflorey daniel.flo...@gmail.com wrote:
  If yes, I can sit down and wait. If not, I have to keep on my fight
  with getting Step2 running on App Engine...

 --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



Re: [appengine-java] can we use Spreadsheet api in GAE Java?

2011-06-02 Thread George Simon
Hi Rambo,
   First update appengine-web.xml by adding

system-properties
  property name=com.google.gdata.DisableCookieHandler value=true/
/system-properties

Also refer to the simple steps from Google

http://code.google.com/apis/spreadsheets/data/2.0/developers_guide_java.html


Thanks

George


On Thu, Jun 2, 2011 at 1:56 PM, Rambo ramkumarpec...@gmail.com wrote:

 Hi friends...!

Am new to Google app engine
 Am deploying projects in GAE using Java codes

 But i dont know how to use Spreadsheet api in that


 Can we use spreadsheet api...?

 If so please tell me how...?


 Thanks in advance.

 --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



Re: [appengine-java] Unable to find the webapp directory

2011-05-31 Thread George Simon
dev_appserver.cmd **C:\Program Files\GoogleAppEngine
\appengine-java-sdk-1.3.0\demos\guestbook\war**

On Mon, May 30, 2011 at 3:05 PM, Suresh suresh...@gmail.com wrote:

 hi

 i have just installed the java sdk. after extracting the files from
 the appengine-java-sdk-1.3.0 jar, I am trying to start the server
 with
 at the command line with the following:


 C:\Program Files\GoogleAppEngine\appengine-java-
 sdk-1.3.0\bindev_appserver.cmd C:\Program Files\GoogleAppEngine
 \appengine-java-sdk-1.3.0\demos\guestbook\war


 I get the following error message:


 Unable to find the webapp directory Files\GoogleAppEngine\appengine-
 java-sdk-1.3.0\demos\guestbook\war


 can anyone help?


 Thx


 --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
 google-appengine-java@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



[appengine-java] Gmail IMAP and SMTP using OAuth

2011-05-30 Thread George Simon
Hi Guys,

Anyone knows about integrating Gmail IMAP and SMTP using OAuth on GAE. Both
of them using sockets. Also if I use GAE Mail java API to send mails,
from address(sender) becoming an issue as only the app developers email
address can be added.

Basically my app is integrated to Google APPS and I am looking  to send
mails on behalf of the logged in user.

Any thoughts on this?

Thanks in advance

George Simon

-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



[appengine-java] Re: built in security features of GAE

2009-09-20 Thread George Simon

Thanks Jason.

We are migrating our apps to GAE in 2-3 months, so our customers may
ask some of the security measures. Though I know GAE is fully secured
environment and google take security very seriously, I would like to
know
1. Any firewall running?
2. Do you provide any safeguards to prevent the user's credentials
from being captured by a spyware?
3. Incase of the system failure how fast we are notified...

If you can share some informartion, it will be great.

Thanks in Advance.

On 9/16/09, Jason (Google) apija...@google.com wrote:
 This can mean several things, so you'll have to be more specific.

 To see the list of restrictions in place to help secure Google's back-end
 infrastructure, see the documentation on the App Engine sandbox:

 http://code.google.com/appengine/docs/java/runtime.html#The_Sandbox

 If you're referring to the built-in services Google offers for
 authenticating and authorizing users, then you should see the following
 links:

 http://code.google.com/appengine/docs/java/users/
 http://code.google.com/appengine/docs/java/config/webxml.html#Security_and_Authentication

 HTTPS (secure URL) support is discussed here:

 http://code.google.com/appengine/docs/java/config/webxml.html#Secure_URLs

 Let me know if you were looking for something else.

 - Jason

 On Tue, Sep 15, 2009 at 4:30 AM, George Simon
 george.simo...@gmail.comwrote:

 Has anyone know the built in security features in GAE.

 Thanks in Advance

 


 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~--~~~~--~~--~--~---



[appengine-java] built in security features of GAE

2009-09-15 Thread George Simon
Has anyone know the built in security features in GAE.

Thanks in Advance

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~--~~~~--~~--~--~---