Re: [appengine-java] Re: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread Nischal Shetty
Sorry, haven't worked with GWT, hope someone helps you.

-N

On 19 April 2011 12:19, Ram  wrote:

> Hi,
>
>  Thank you..Also I have another doubt, how to use GWT desiner in my
> Eclipse.In documents no continuity is therewhere i want to
> open GWT designer using eclipse.
>
> please help me..
>
> On Apr 19, 11:18 am, Nischal  wrote:
> > I'm using struts 2 and it seems good for development. However, there are
> > other lighter frameworks that appengine users have spoken positively
> about.
> > You should check out this thread -
> https://groups.google.com/forum/#!topic/google-appengine-java/7wkMDm6...
>
> --
> 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.
>
>


-- 
-Nischal
+91-9920240474
twitter: NischalShetty 
facebook: Nischal 



-- 
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] JSP markup/code highlighting

2011-04-19 Thread Drew Spencer
Ah thanks a lot. I had initially installed the Oracle Enterprise Pack which 
had a JSP editor among other things, but it had loads of stuff I don't 
really need right now so I've uninstalled it and am giving the web page 
editor a try as mentioned on stackoverflow. Anyone else who wants it just 
search the marketplace for "Web Page" and install "Web Page Editor 
(Optional)".

Thanks again Matthew!

All the best,

Drew

-- 
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: can I use Google maps in my Google Appengine java Application

2011-04-19 Thread Didier Durand
Hi Ram,

The web is full of good tutorials for the subjects that you want to
learn: use google to find some.

Please, understand that this group is not a place for all what
concerns Jav dev: far too broad...

regards

didier

On Apr 19, 7:56 am, Ram  wrote:
> Please anybody reply...

-- 
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: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread Marcel Overdijk
I'm using the Spring stack (Spring DI, AOP ,MVC, Security) together
with Objectify successfully on appengine.
The app is not in production yet, but several tests of the setup also
worked on appengine.

Off course there are lighter frameworks, but that's not a issue for me
using warm instances.

On Apr 19, 9:13 am, Nischal Shetty  wrote:
> Sorry, haven't worked with GWT, hope someone helps you.
>
> -N
>
> On 19 April 2011 12:19, Ram  wrote:
>
>
>
> > Hi,
>
> >  Thank you..Also I have another doubt, how to use GWT desiner in my
> > Eclipse.In documents no continuity is therewhere i want to
> > open GWT designer using eclipse.
>
> > please help me..
>
> > On Apr 19, 11:18 am, Nischal  wrote:
> > > I'm using struts 2 and it seems good for development. However, there are
> > > other lighter frameworks that appengine users have spoken positively
> > about.
> > > You should check out this thread -
> >https://groups.google.com/forum/#!topic/google-appengine-java/7wkMDm6...
>
> > --
> > 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.
>
> --
> -Nischal
> +91-9920240474
> twitter: NischalShetty 
> facebook: Nischal 
>
> 

-- 
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: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread Nischal
You mean you have reserved instances? IMO you would still need to take care 
of your load time as new instances are spun off when your traffic increases 
and if your load time is too much then it would lead to errors while 
spinning up new instances.

-- 
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] Simulating POST Request to BLOBSTORE

2011-04-19 Thread Josh F.
Hello, I'm really at loss trying to track down the source of this
exception:

Apr 19, 2011 11:53:47 AM com.google.apphosting.utils.jetty.JettyLogger
warn
WARNING: /_ah/login
java.lang.NullPointerException
at
com.google.appengine.api.users.dev.LoginCookieUtils.encodeEmailAsUserId(LoginCookieUtils.java:
89)
at
com.google.appengine.api.users.dev.LoginCookieUtils.createCookie(LoginCookieUtils.java:
41)
at
com.google.appengine.api.users.dev.LocalLoginServlet.doPost(LocalLoginServlet.java:
90)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
511)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1166)
at
com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:
58)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1157)
at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
43)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1157)
at
com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:
122)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1157)
at
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
388)
at
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:
216)
at
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
182)
at
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
765)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:
418)
at
com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:
70)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
152)
at com.google.appengine.tools.development.JettyContainerService
$ApiProxyHandler.handle(JettyContainerService.java:351)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
542)
at org.mortbay.jetty.HttpConnection
$RequestHandler.content(HttpConnection.java:938)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:755)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at
org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:
409)
at org.mortbay.thread.QueuedThreadPool
$PoolThread.run(QueuedThreadPool.java:582)

This is occurring on my development server after running the app as a
Web Application through eclipse. The app basically stores .html files
in the blobstore, and allows the user to edit the html file through a
small jQuery based HTML editor.

I can retrieve the .html file contents from the blobstore using
fetchData to return a byte array of the contents. But once the user
has made changes to the html code via the editor, I'm trying to update
the entry in the DATASTORE that references the BlobKey string for the
corresponding .html file. So I am using a MultiPartFormOutputStream to
write directly to the request headers and simulate an HTTP POST
request.

Here is the code I have:

byte[] htmlData = content.getBytes();
for(int k=0; khttp://localhost:"; + uploadURL;
 }
 URL url = new URL(uploadURL);
 // create a boundary string
 String boundary = MultiPartFormOutputStream.createBoundary();
 URLConnection urlConn =
MultiPartFormOutputStream.createConnection(url);
 urlConn.setReadTimeout(15000);
 urlConn.setRequestProperty("Accept", "*/*");
 urlConn.setRequestProperty("Content-Type",
MultiPartFormOutputStream.getContentType(boundary));
 // set some other request headers...
 urlConn.setRequestProperty("Connection", "Keep-Alive");
 urlConn.setRequestProperty("Cache-Control", "no-cache");
 // no need to connect because getOutputStream() does it
 MultiPartFormOutputStream out = new
MultiPartFormOutputStream(urlConn.getOutputStream(), boundary);
 // write a text field element - This should be removed - left 
over
from multipart library demo code
 out.writeField("old", oldBlobKey);
 out.writeField("lob", lineOfBusiness);
 out.writeField("topic", topic);
 out.writeField("category", category);
 out.writeField("key", ke

[appengine-java] Data being stored in a weird way

2011-04-19 Thread Luca Matteis
I posted a question on StackOverflow about my data being stored with
weird chars, and it only happens live, which is very strange.

Here's the question:
http://stackoverflow.com/questions/5707266/google-app-engine-data-being-stored-in-a-weird-way

Am I missing something?

-- 
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: can I use Google maps in my Google Appengine java Application

2011-04-19 Thread suchitra nair
hey
  I recommend you go through the in depth tutorial
http://code.google.com/webtoolkit/doc/latest/tutorial/index.html.
I am new to GWT and GAE too. As far as I know, GWT is used for client side
development and we can use it to communicate to a server using asynchronous
communication as in AJAX. You can create a single web app project in eclipse
using GWT for client and GAE sdk for the server along with jsp, servlet,
html, css (by installing the required plugins for gwt and gae). Hope this
helped. I am not sure of gwt being used in server side.

-- 
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] Cheapest way to update a versioned object?

2011-04-19 Thread blue
Every action on my app will require the user to view and update their user 
object, but other users will have the opportunity to update other user 
objects as well.  So, my question is, what is the cheapest way to do this?

The best way I have found to do this is:
1) read user from memcache (or datastore if not
 there and put into memcache)
2) modify user object
3) get from memcache again and see if version has changed
4) write to memcache with new version or throw error if version is different
5) have a cron job write batches to the datastore if needed

Most of the time a user will end up with 2 gets from memcache and 1 set to 
memcache.

The other option I have tried was transactions, but that was way too 
expensive -- datastore writes on every request.
I also tried sessions, but that was also very expensive -- datastore writes 
on every request.

Does anyone have a better solution?

-- 
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: Simulating POST Request to BLOBSTORE

2011-04-19 Thread Josh F.
Solved. turns out I was not passing the cookie that keeps you logged
in.

Cookie [] cookies = req.getCookies();
String name = cookies[0].getName();
String value = cookies[0].getValue(); //this holds all
the information that the login servlet needs

to get the authentication cookie from the http request, then passed it
along to the final Upload servlet:

 urlConn.setRequestProperty("Cookie", name + "=" +
value);

It worked like a charm!!

On Apr 19, 12:03 pm, "Josh F."  wrote:
> Hello, I'm really at loss trying to track down the source of this
> exception:
>
> Apr 19, 2011 11:53:47 AM com.google.apphosting.utils.jetty.JettyLogger
> warn
> WARNING: /_ah/login
> java.lang.NullPointerException
>         at
> com.google.appengine.api.users.dev.LoginCookieUtils.encodeEmailAsUserId(LoginCookieUtils.java:
> 89)
>         at
> com.google.appengine.api.users.dev.LoginCookieUtils.createCookie(LoginCookieUtils.java:
> 41)
>         at
> com.google.appengine.api.users.dev.LocalLoginServlet.doPost(LocalLoginServlet.java:
> 90)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>         at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
> 511)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1166)
>         at
> com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:
> 58)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1157)
>         at
> com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
> 43)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1157)
>         at
> com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:
> 122)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1157)
>         at
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
> 388)
>         at
> org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:
> 216)
>         at
> org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
> 182)
>         at
> org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
> 765)
>         at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:
> 418)
>         at
> com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:
> 70)
>         at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 152)
>         at com.google.appengine.tools.development.JettyContainerService
> $ApiProxyHandler.handle(JettyContainerService.java:351)
>         at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 152)
>         at org.mortbay.jetty.Server.handle(Server.java:326)
>         at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
> 542)
>         at org.mortbay.jetty.HttpConnection
> $RequestHandler.content(HttpConnection.java:938)
>         at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:755)
>         at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
>         at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
>         at
> org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:
> 409)
>         at org.mortbay.thread.QueuedThreadPool
> $PoolThread.run(QueuedThreadPool.java:582)
>
> This is occurring on my development server after running the app as a
> Web Application through eclipse. The app basically stores .html files
> in the blobstore, and allows the user to edit the html file through a
> small jQuery based HTML editor.
>
> I can retrieve the .html file contents from the blobstore using
> fetchData to return a byte array of the contents. But once the user
> has made changes to the html code via the editor, I'm trying to update
> the entry in the DATASTORE that references the BlobKey string for the
> corresponding .html file. So I am using a MultiPartFormOutputStream to
> write directly to the request headers and simulate an HTTP POST
> request.
>
> Here is the code I have:
>
> byte[] htmlData = content.getBytes();
>                 for(int k=0; k                 {
>                         resp.getWriter().println("Byte " + k + ": " + 
> htmlData[k]);
>                 }
>                 BlobstoreService blobstoreService =
> BlobstoreServiceFactory.getBlobstoreService();
>                 String uploadURL = 
> blobstoreService.createUploadUrl("/upload");
>
>                              //add host if in dev mode
>                  if(uploadURL.indexOf("http") == -1)
>                  {
>                          uploadURL = "http://localhost:"; + uploadURL;
>                  }
>                  URL url 

[appengine-java] Re: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread Marcel Overdijk
No check out docs about Warmup requests:
http://code.google.com/appengine/docs/java/config/appconfig.html#Warmup_Requests

On Apr 19, 1:18 pm, Nischal  wrote:
> You mean you have reserved instances? IMO you would still need to take care
> of your load time as new instances are spun off when your traffic increases
> and if your load time is too much then it would lead to errors while
> spinning up new instances.

-- 
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: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread lorenoolive...@gmail.com
What is a good/acceptable application load time? The load time of my
application in "run" mode in the development environment gives me a good
confidence of the real application load time on production environment?

Loreno

On Tue, Apr 19, 2011 at 5:18 PM, Marcel Overdijk
wrote:

> No check out docs about Warmup requests:
>
> http://code.google.com/appengine/docs/java/config/appconfig.html#Warmup_Requests
>
> On Apr 19, 1:18 pm, Nischal  wrote:
> > You mean you have reserved instances? IMO you would still need to take
> care
> > of your load time as new instances are spun off when your traffic
> increases
> > and if your load time is too much then it would lead to errors while
> > spinning up new instances.
>
> --
> 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] Re: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread Starman
I'm using a combination of Spring, Objectify and Spring Security. App
spins up in 20 secs. Could be a lot faster if I was not using
classpath scanning. But with always up and correct warmup request
config, anything under 30 secs will do just fine.

What you want is to get sub 10 secs startup in dev mode so that your
unit tests start up fast.

On Apr 19, 4:24 pm, "lorenoolive...@gmail.com"
 wrote:
> What is a good/acceptable application load time? The load time of my
> application in "run" mode in the development environment gives me a good
> confidence of the real application load time on production environment?
>
> Loreno
>
> On Tue, Apr 19, 2011 at 5:18 PM, Marcel Overdijk
> wrote:
>
>
>
> > No check out docs about Warmup requests:
>
> >http://code.google.com/appengine/docs/java/config/appconfig.html#Warm...
>
> > On Apr 19, 1:18 pm, Nischal  wrote:
> > > You mean you have reserved instances? IMO you would still need to take
> > care
> > > of your load time as new instances are spun off when your traffic
> > increases
> > > and if your load time is too much then it would lead to errors while
> > > spinning up new instances.
>
> > --
> > 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] How to trace the TaskQueue status

2011-04-19 Thread Herist.ZHOU
Hi all :
I found that we could add a TaskOptions to a queue and could get the
TaskHandler then get the taskName or ETA info etc.

But I can't find a api to get the status of queue.

For exp :
I want to add 1000 entities to DataStore, We can't do the task in one
request due to the request deadline ,So  I split it to 50 TaskOptions
After Added these taskOptions to a queue.  I have no method to track
the executing status in our code.
I knew that we could watch it at admin console page. But Is there
other ways?

-- 
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] How to trace the TaskQueue status

2011-04-19 Thread Herist.ZHOU
Hi all :
I found that we could add a TaskOptions to a queue and could get the
TaskHandler then get the taskName or ETA info etc.

But I can't find a api to get the status of queue.

For exp :
I want to add 1000 entities to DataStore, We can't do the task in one
request due to the request deadline ,So  I split it to 50 TaskOptions
After Added these taskOptions to a queue.  I have no method to track
the executing status in our code.
I knew that we could watch it at admin console page. But Is there
other ways?

-- 
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: Cheapest way to update a versioned object?

2011-04-19 Thread Nick Rudnik
You are correct that writing to memcache is by far the cheapest way to save 
data. A cron job to periodically persist the changes to the datastore is 
required if you care to make sure your data isn't lost. Memcache can be 
flushed for any reason at any time. The frequency of the cron job will 
determine how durable your data is vs how much cost you are comfortable with 
as far as writes to the datastore. 

-- 
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: Which one is best for development...Spring Framework or Servlet& Jsp....

2011-04-19 Thread Nick Rudnik
Spring MVC 3 works very well inside App Engine. I have a fairly small and 
simple application and see a load time of around 20 seconds also. 

-- 
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: Redirection query on naked domain

2011-04-19 Thread Nick Rudnik
The problem is likely that your domain provider is doing a simple redirect 
to your www hostname where App Engine is able to respond. The redirect logic 
is probably very basic in that it does not preserve the rest of the request 
url when doing the redirect. The only way I know around this is to have a 
site hosted somewhere that can respond to your naked domain request that has 
the logic to properly form the redirect to the app engine hosted host with 
the rest of the url intact. 

-- 
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: HTTP Post not working

2011-04-19 Thread Nick Rudnik
If I understand correctly, are you trying to POST from within the servlet 
code? If so, there are restrictions on the way you are allowed to open a 
network connection from within your application. There is a special Google 
provided class to make a network connection that way. Maybe that's your 
problem? 

-- 
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: JDO - Set Entity group parent in an unowned relationship

2011-04-19 Thread Nick Rudnik
It sounds like you need a keyOfA in class B with the extension annotation so 
A B and C all end up in the same entity group. If you are actually only 
updating B and C together in a transaction, the extension annotation should 
only be necessary on the keyOfB member in class C. 

There is also some strange behavior that I've noticed when I retrieve an 
existing entity from the datastore that has one of those extension members 
that I cannot update it and persist it back unless I set the field to null. 
However, it remains in the right entity group. I think it just can't be set 
again after it was created once since the entity group is unchangeable. 

-- 
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: HTTP Post not working

2011-04-19 Thread Didier Durand
Hi,

Read this part of app engine doc: 
http://code.google.com/appengine/docs/java/urlfetch/overview.html

You will see that there are some restrictions in the URL service: port
numbers, etc...

Maybe you will into one of them with c2dm

regards

didier

On Apr 15, 1:37 pm, Thomas Riley  wrote:
> Hello, I'm using GAEJ as the back end for my Android application and have
> implemented Cloud to Device Messaging for Android (C2DM).
>
> I have everything working bar one bit of code. The Servlet that is executed
> in a TaskQueue refuses to execute correctly.
>
> The code includes a HTTP POST that is technically correct as the code was
> adapted from Google's Chome2Phone App Engine sample code. For some reason,
> app engine does not execute my code however it does not log that an error
> has occured and the logging I have configured to occur during the HTTP POST
> process is not displayed (however any logging before or after the attempt to
> POST is displayed).
>
> This is an extremely odd error that I can't figure out, has anyone
> else experienced a similar problem?
>
> Note: This is not an issue with C2DM or my Android device client as I have
> successfully tested this using CURL.
>
> If anyone has a suggestion, it will be greatly appreciated!

-- 
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: Cheapest way to update a versioned object?

2011-04-19 Thread Didier Durand
Hi,

Be careful with the cron job: you may lose some of your updates if gae
has some trouble between some updates and the cron job. There is no
guarantee from Google on that point:

see "Under rare circumstances, values may also disappear from the
cache prior to expiration for reasons other than memory pressure.
While memcache is resilient to server failures, memcache values are
not saved to disk, so a service failure may cause values to become
unavailable." at 
http://code.google.com/appengine/docs/java/memcache/overview.html#How_Cached_Data_Expires

Anyway, more simply if the cache is too loaded, some values are
discarded. So, here again you may lose values.

So, I would encourage either a direct write-through in addition to
cache write. You can do it via a synchronous / async I/O from the
transaction or via a task that you queue.

regards

didier
On Apr 19, 7:40 pm, blue  wrote:
> Every action on my app will require the user to view and update their user
> object, but other users will have the opportunity to update other user
> objects as well.  So, my question is, what is the cheapest way to do this?
>
> The best way I have found to do this is:
> 1) read user from memcache (or datastore if not
>  there and put into memcache)
> 2) modify user object
> 3) get from memcache again and see if version has changed
> 4) write to memcache with new version or throw error if version is different
> 5) have a cron job write batches to the datastore if needed
>
> Most of the time a user will end up with 2 gets from memcache and 1 set to
> memcache.
>
> The other option I have tried was transactions, but that was way too
> expensive -- datastore writes on every request.
> I also tried sessions, but that was also very expensive -- datastore writes
> on every request.
>
> Does anyone have a better solution?

-- 
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: Data being stored in a weird way

2011-04-19 Thread Didier Durand
Hi,

Are you using eclipse ?  if yes check under File > Properties > Text
File encoding that your file is UTF-8 encoding.

I would guess not.

So, change it to UTF-8 and your issue should get fixed.

regards

didier

On Apr 19, 6:32 pm, Luca Matteis  wrote:
> I posted a question on StackOverflow about my data being stored with
> weird chars, and it only happens live, which is very strange.
>
> Here's the 
> question:http://stackoverflow.com/questions/5707266/google-app-engine-data-bei...
>
> Am I missing something?

-- 
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: Eclipse, RichFaces & Google App Engine - Tutorial - Step By Step - Draft 1.0

2011-04-19 Thread Daniel
nice!
tx!

On Apr 18, 12:53 am, Tomek  wrote:
> On Apr 17, 9:48 pm, Tomek  wrote:
>
> > Hi,
>
> > Maybe some of you will find the 
> > tutorialuseful.
> >  Any comments (fixes too) are very welcome.
>
> > All the best,
>
> > Tomek
>
> I am sorry, I didnt use and post to the groups before, so the link
> looked like broken. Once 
> again:http://void-pointers.blogspot.com/2011/04/eclipse-richfaces-google-ap...

-- 
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.