[appengine-java] Re: Exhaustive JPA/JDO tutorial
Thanks Esteban. This seems useful. Will read and post feedback later. On Sep 15, 12:02 am, Esteban Masoero emaso...@getsense.com.ar wrote: This should help:http://www.datanucleus.org/products/accessplatform_1_1/index.html Regards, Esteban Java_GAE escribió: Hi, Please anybody can post a link to exhaustive and intensive tutorial on JPA/JDO. I got head and tail from the google app engine tutorial but need to understand much more than that to create my application. 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] Fetch by string equality stopped working
I have a jpa/spring dao that returns a user by open id url. Running on sdk 1.2.1, his worked without a problem. moving to 1.2.2, and now 1.2.5, it no longer returns any records. Returning all records and using String.equals works fine: String openIdUrl = http://blah/me;; List results = em.createQuery(select u from +OpenIDUser.class.getName ()+ u where u.openIDUrl=?1).setParameter(1, openIdUrl).getResultList (); //results is size 0 List l = em.createQuery(select u from +OpenIDUser.class.getName()+ u).getResultList(); for(Object o: l){ String url = ((OpenIDUser)o).getOpenIDUrl(); if(openIdUrl.equals(url)){ //string matches return (OpenIDUser)o; } } I am assuming I have inadvertently screwed something up in my environment, but I'm struggling to get any more information - can anyone suggest any pointers? --~--~-~--~~~---~--~~ 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] Regarding nullpoint exception
Hi i have been working with an application and when i send a url request thru the browser,iam getting a null point exception,so someone tell me how can i rectift dat error --~--~-~--~~~---~--~~ 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 avoid Data Nucleus and still use JPA?
As leszek says I think you have a few things confused: DataNucleus is a JDO/JPA implementation that can run within AppEngine. AppEngine provides 2 persistence mechanisms, BigTable and VFS (Virtual File System). You cannot configure your GoogleApp to use an external RDBMS, nor can you host an RDBMS within your GoogleApp. Also note that with each DB record, BigTable effectively stores not only the data but also the metadata for the table. Ie all the column names are stored alongside the column data, for each record. So a Gigabyte of data will commonly consume 10GB of space within BigTable. Using GWT on your client is orthogonal, to the persistence on the server. However, if you have a clean JPA (non-Hibernate specific) implementation you might have a way continue to use JPA within your GoogleApp by using a H2 RDBMS implementation running on top of VFS. See http://groups.google.com/group/google-appengine-java/browse_thread/thread/fce7750aad2845ff?hl=en and http://groups.google.com/group/gaevfs/browse_thread/thread/c23b8af5791b3a4 On a side note, Andy (aka Datanucleus) you need to chill dude. Users are reporting problems with Datanucleus because they are feeling pain. Barking at them is not the way to win support and market share for Datanucleus, quite the opposite. William --~--~-~--~~~---~--~~ 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 avoid Data Nucleus and still use JPA?
@WilliamF, I don't see how any of my responses in this thread can be construed even remotely as barking at somebody. In fact providing references to docs would likely be the opposite, as the user indeed recognised in his post. In fact you can review all of my responses to people over the last 5 months and judge that for yourself; some replies where more time was available to give a full response and others less. Obviously, in a written form, someone somewhere will always want to construe a response in some other way maybe due to the problems they themselves are having with some software and the subsequent frustration and want someone to blame. For the record, people in general are reporting problems with the Google-provided datanucleus plugin, not DataNucleus itself. There are actually no outstanding JIRAs for DataNucleus relating to AppEngine usage. I chip in here occasionally with help in my spare time, since DataNucleus is an open source project, to which anyone could volunteer their time. If that is inadequate for you then that is indeed unfortunate. Good luck with your application. --~--~-~--~~~---~--~~ 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 avoid Data Nucleus and still use JPA?
Nobody can contradict that DataNucleus is a high quality software. The fact that it is Google's persistence provider of choice speaks for itself. --~--~-~--~~~---~--~~ 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/JPA Snippets That Work - Creating a bidirectional, owned, one-to-many relationship
Max, Love the examples, however I have one question. In the GAE JDO documentation there's much written about the KeyFactory, Builder(s) and creating hierarcal Key(s). It's doesn't appear that your example has factored these in. I know littered through out my code are KeyFactory and Builders for the child objects. Should these Key Builders be included within your example? Thank you, Jeff On Mon, Sep 14, 2009 at 7:07 PM, Max Ross maxr+appeng...@google.commaxr%2bappeng...@google.com wrote: Hello hello and welcome to the very first installment of JDO/JPA Snippets That Work! Creating A Bidrectional Owned One-To-Many Suppose you're building a book catalog application and you want to model books and chapters. Books contain chapters. A chapter cannot exist without a book, so if you delete a book you want its chapters automatically deleted along with it. You also want to each chapter to have a reference to the book that owns it. Sounds like a bidrectional, owned, one-to-many relationship is just the thing. First we'll set up our model objects and then we'll add some code to create a Book with 2 Chapters. JPA: @Entity public class Book { @Id @GeneratedValue(strategy=GenerationType.IDENTITY) private Key id; private String title; @OneToMany(mappedBy = book, cascade = CascadeType.ALL) private ListChapter chapters = new ArrayListChapter(); // getters and setters } @Entity public class Chapter { @Id @GeneratedValue(strategy=GenerationType.IDENTITY) private Key id; private String title; private int numPages; @ManyToOne(fetch = FetchType.LAZY) private Book book; // getters and setters } Now let's create a book with two chapters (we'll assume someone else is creating and closing an EntityManager named 'em' for us): Book b = new Book(); b.setTitle(JPA 4eva); Chapter c1 = new Chapter(); c1.setTitle(Intro); c1.setNumPages(10); b.getChapters().add(c1); Chapter c2 = new Chapter(); c2.setTitle(Configuration); c2.setNumPages(9); b.getChapters().add(c2); em.getTransaction().begin(); try { em.persist(b); em.getTransaction().commit(); } finally { if (em.getTransaction().isActive()) { em.getTransaction().rollback(); } } JDO: @PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = true) public class Book { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key id; private String title; @Persistent(mappedBy = book) @Element(dependent = true) private ListChapter chapters = new ArrayListChapter(); // getters and setters } @PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = true) public class Chapter { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key id; private String title; private int numPages; @Persistent private Book book; // getters and setters } Now let's create a book with two chapters (we'll assume someone else is creating and closing a PersistenceManager named 'pm' for us): Book b = new Book(); b.setTitle(JDO 4eva); Chapter c1 = new Chapter(); c1.setTitle(Intro); c1.setNumPages(10); b.getChapters().add(c1); Chapter c2 = new Chapter(); c2.setTitle(Configuration); c2.setNumPages(9); b.getChapters().add(c2); pm.currentTransaction().begin(); try { pm.makePersistent(b); pm.currentTransaction().commit(); } finally { if (pm.currentTransaction().isActive()) { pm.currentTransaction().rollback(); } } --~--~-~--~~~---~--~~ 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
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] Re: How to save GeoPt in JPA?
use geohash Sent from my iPhone On 15/09/2009, at 7:09 AM, Jason (Google) apija...@google.com wrote: Release 1.2.5 did add a GeoPt property type for Java so you can more easily store geographic coordinates in the datastore, but App Engine itself does not provide the logic necessary for doing bounding-box or other geo queries. As you said, there are several projects available for App Engine Python, but I don't know of any for Java, though they could still be out there. - Jason On Sat, Sep 12, 2009 at 1:55 PM, damenlon inhouse...@gmail.com wrote: Hi, There is a good Map tutorial, geodatastore, for Python. Is there one for Java using JPA? What I want to do is searching Geo Points within a boundary. Thanks! --~--~-~--~~~---~--~~ 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: Bulk writes to datastore
Hi Larry I am wondering about writing a Servlet that would form/multi-part upload large files and cache them in memcache then use the cron API to trickle persist them into the DS over time ... I've been thinking about using something like this as well. I think you could likely cache the upload to the store because the limit here seems to be mainly the amount of entities, not the size of one entity (below 1mb). I have e.g. 100/200k worth of data that I upload, but because it's represented as a couple hundred entities it chokes. I could just upload the 93k and fire off a task (or cron job) that would parse and insert the data offline. At the very least, I plan to use the low-level api more. The (very useful) performance testing app http://gaejava.appspot.com/ shows consistently higher CPU usage from JDO. If this ever improves, that app should show it. Until then, low-level looks good. Regards, Richard --~--~-~--~~~---~--~~ 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: ArrayIndexOutOfBoundsException: at org.datanucleus.plugin.ConfigurationElement.putAttribute(Configuratio nElement.java:104)
No one has any update on this??? Thanks Patrizio Munzi wrote: Mmm, I think there's need of datanucleus experts. Hope someone could clarify this subject wada3 wrote: It would be bug or limitation of development environment. I have not met them on real appengine environment because container looks like running on single thread model. Normally it would not need to be synchronized I think. On Sep 11, 4:41pm, "patrizio.munzi" eris4.mu...@gmail.com wrote: Isn't this an important subject to address? Are all method calling the makePersistent method needed to be synchronized...?? Is this a bug..?? No one has any consideration??? Thanks On Sep 10, 10:35am, "patrizio.munzi" eris4.mu...@gmail.com wrote: I did a few more investigation and It looks like a threads safety problem. In fact if I synchronize the method com.myapp.server.datastore.EventsManager.addEvent whithin makePersistent is called everything works fine. I think here experts are needed.. :-) Bye On Sep 10, 10:18am, "patrizio.munzi" eris4.mu...@gmail.com wrote: Hi everybody I'm having an ArrayOutOfBoundException from nucleus... I don't know where it comes from... Can anyone give me some information about it... Here's the stack trace... --- The server is running athttp://localhost:8181/ java.lang.ArrayIndexOutOfBoundsException: 1187 at org.datanucleus.plugin.ConfigurationElement.putAttribute (ConfigurationElement.java:104) at org.datanucleus.store.appengine.DatastorePluginRegistry.getExtensionPoint (DatastorePluginRegistry.java:59) at org.datanucleus.plugin.PluginManager.getExtensionPoint (PluginManager.java:65) at org.datanucleus.plugin.PluginManager.getConfigurationElementForExtension (PluginManager.java:113) at org.datanucleus.plugin.PluginManager.getAttributeValueForExtension (PluginManager.java:230) at org.datanucleus.ObjectManagerImpl.getCallbackHandler (ObjectManagerImpl.java:3804) at org.datanucleus.state.AbstractStateManager.getCallbackHandler (AbstractStateManager.java:160) at org.datanucleus.state.JDOStateManagerImpl.initialiseForPersistentNew (JDOStateManagerImpl.java:466) at org.datanucleus.state.StateManagerFactory.newStateManagerForPersistentNew (StateManagerFactory.java:151) at org.datanucleus.ObjectManagerImpl.persistObjectInternal (ObjectManagerImpl.java:1297) at org.datanucleus.ObjectManagerImpl.persistObject (ObjectManagerImpl.java:1175) at org.datanucleus.jdo.JDOPersistenceManager.jdoMakePersistent (JDOPersistenceManager.java:669) at org.datanucleus.jdo.JDOPersistenceManager.makePersistent (JDOPersistenceManager.java:694) at com.myapp.server.datastore.EventsManager.addEvent (EventsManager.java:167) at com.myapp.server.restlet.EventResource.addEvent(EventResource.java: 30) at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.restlet.resource.ServerResource.doHandle(ServerResource.java: 390) at org.restlet.resource.ServerResource.doHandle(ServerResource.java: 328) at org.restlet.resource.ServerResource.doNegotiatedHandle (ServerResource.java:581) at org.restlet.resource.ServerResource.doConditionalHandle (ServerResource.java:254) at org.restlet.resource.ServerResource.handle(ServerResource.java: 923) at org.restlet.resource.Finder.handle(Finder.java:510) at org.restlet.routing.Filter.doHandle(Filter.java:156) at org.restlet.routing.Filter.handle(Filter.java:201) at org.restlet.routing.Router.doHandle(Router.java:321) at org.restlet.routing.Router.handle(Router.java:520) at org.restlet.routing.Filter.doHandle(Filter.java:156) at org.restlet.routing.Filter.handle(Filter.java:201) at org.restlet.routing.Filter.doHandle(Filter.java:156) at org.restlet.routing.Filter.handle(Filter.java:201) at org.restlet.routing.Filter.doHandle(Filter.java:156) at org.restlet.engine.application.StatusFilter.doHandle (StatusFilter.java:152) at org.restlet.routing.Filter.handle(Filter.java:201) at org.restlet.routing.Filter.doHandle(Filter.java:156) at org.restlet.routing.Filter.handle(Filter.java:201) at org.restlet.engine.ChainHelper.handle(ChainHelper.java:111) at org.restlet.engine.application.ApplicationHelper.handle (ApplicationHelper.java:72) at org.restlet.Application.handle(Application.java:344) at org.restlet.routing.Filter.doHandle(Filter.java:156) at org.restlet.routing.Filter.handle(Filter.java:201) at org.restlet.routing.Router.doHandle(Router.java:321) at org.restlet.routing.Router.handle(Router.java:520) at
[appengine-java] CPU Occasionally Spikes when HttpSession is Created
Hi Everyone, I've noticed that CPU occasionally spikes when creating an HTTPSession. It only seems to happen when it's been awhile since an app has been accessed or when an app is initially deployed. For example, I created a simple test servlet that creates a session and and writes a response: protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { req.getSession(); PrintWriter writer = resp.getWriter(); writer.write(Test Complete); writer.flush(); writer.close(); } When I deploy the app and invoke the servlet for the first time, I see the following in the admin console: 09-15 05:57AM 29.487 /test 200 7184ms 4381cpu_ms 65api_cpu_ms 0kb Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.6) Gecko/ 2009011913 Firefox/3.0.6 (.NET C Note the high CPU and long response time. Subsequent session creations are much faster. If I delete my cookies and re-invoke the servlet, CPU is approx. 70-80ms. Now, if I leave the app for awhile (let's say an hour) and hit the servlet again, CPU is once again through the roof for the initial GET. Any thoughts about what's going on here? I know that Google's session management involves memcache and the datastore. Could the high CPU be a side-effect of some initialization routine, etc...? Thanks for the feedback, Jamie --~--~-~--~~~---~--~~ 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: Regarding debugging error
Replace: filter-classAuthFilter/filter-class With filter-classcom.org.login.AuthFilter/filter-class --~--~-~--~~~---~--~~ 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/JPA Snippets That Work - Creating a bidirectional, owned, one-to-many relationship
This example only demonstrates creation of parent and child when both parent and child use datastore id generation. If you wanted to use a named Key for either of these objects as opposed to datastore id generation, the KeyFactory and the KeyFactory.Builder class would be involved. This would also be the case if you were constructing a Key to perform a lookup of either parent or child. I plan to devote other snippets to more complicated Key-management scenarios. Thanks, Max On Tue, Sep 15, 2009 at 4:16 AM, Jeff Arbaugh jeffarba...@gmail.com wrote: Max, Love the examples, however I have one question. In the GAE JDO documentation there's much written about the KeyFactory, Builder(s) and creating hierarcal Key(s). It's doesn't appear that your example has factored these in. I know littered through out my code are KeyFactory and Builders for the child objects. Should these Key Builders be included within your example? Thank you, Jeff On Mon, Sep 14, 2009 at 7:07 PM, Max Ross maxr+appeng...@google.commaxr%2bappeng...@google.com wrote: Hello hello and welcome to the very first installment of JDO/JPA Snippets That Work! Creating A Bidrectional Owned One-To-Many Suppose you're building a book catalog application and you want to model books and chapters. Books contain chapters. A chapter cannot exist without a book, so if you delete a book you want its chapters automatically deleted along with it. You also want to each chapter to have a reference to the book that owns it. Sounds like a bidrectional, owned, one-to-many relationship is just the thing. First we'll set up our model objects and then we'll add some code to create a Book with 2 Chapters. JPA: @Entity public class Book { @Id @GeneratedValue(strategy=GenerationType.IDENTITY) private Key id; private String title; @OneToMany(mappedBy = book, cascade = CascadeType.ALL) private ListChapter chapters = new ArrayListChapter(); // getters and setters } @Entity public class Chapter { @Id @GeneratedValue(strategy=GenerationType.IDENTITY) private Key id; private String title; private int numPages; @ManyToOne(fetch = FetchType.LAZY) private Book book; // getters and setters } Now let's create a book with two chapters (we'll assume someone else is creating and closing an EntityManager named 'em' for us): Book b = new Book(); b.setTitle(JPA 4eva); Chapter c1 = new Chapter(); c1.setTitle(Intro); c1.setNumPages(10); b.getChapters().add(c1); Chapter c2 = new Chapter(); c2.setTitle(Configuration); c2.setNumPages(9); b.getChapters().add(c2); em.getTransaction().begin(); try { em.persist(b); em.getTransaction().commit(); } finally { if (em.getTransaction().isActive()) { em.getTransaction().rollback(); } } JDO: @PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = true) public class Book { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key id; private String title; @Persistent(mappedBy = book) @Element(dependent = true) private ListChapter chapters = new ArrayListChapter(); // getters and setters } @PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = true) public class Chapter { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key id; private String title; private int numPages; @Persistent private Book book; // getters and setters } Now let's create a book with two chapters (we'll assume someone else is creating and closing a PersistenceManager named 'pm' for us): Book b = new Book(); b.setTitle(JDO 4eva); Chapter c1 = new Chapter(); c1.setTitle(Intro); c1.setNumPages(10); b.getChapters().add(c1); Chapter c2 = new Chapter(); c2.setTitle(Configuration); c2.setNumPages(9); b.getChapters().add(c2); pm.currentTransaction().begin(); try { pm.makePersistent(b); pm.currentTransaction().commit(); } finally { if (pm.currentTransaction().isActive()) { pm.currentTransaction().rollback(); } } --~--~-~--~~~---~--~~ 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] RPC call and variables
Hello In my application, If a client A makes an rpc call and changes a variable at server, I want this change to be immediately reflected to other clients when they make same rpc call. But it looks that my clients are interacting with different servers and changes are not reflected. What can I do to make this possible? Regards Sahil --~--~-~--~~~---~--~~ 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: Fetch by string equality stopped working
Looks like a regression in handling of positional params. I could've sworn I had tests for these.but no, they don't exist. I'll follow up with a bug number you can use to track this issue. I'll also try to find you a workaround. Sorry for the trouble, Max On Tue, Sep 15, 2009 at 12:33 AM, damnpana...@googlemail.com damnpana...@googlemail.com wrote: I have a jpa/spring dao that returns a user by open id url. Running on sdk 1.2.1, his worked without a problem. moving to 1.2.2, and now 1.2.5, it no longer returns any records. Returning all records and using String.equals works fine: String openIdUrl = http://blah/me;; List results = em.createQuery(select u from +OpenIDUser.class.getName ()+ u where u.openIDUrl=?1).setParameter(1, openIdUrl).getResultList (); //results is size 0 List l = em.createQuery(select u from +OpenIDUser.class.getName()+ u).getResultList(); for(Object o: l){ String url = ((OpenIDUser)o).getOpenIDUrl(); if(openIdUrl.equals(url)){ //string matches return (OpenIDUser)o; } } I am assuming I have inadvertently screwed something up in my environment, but I'm struggling to get any more information - can anyone suggest any pointers? --~--~-~--~~~---~--~~ 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: Fetch by string equality stopped working
http://code.google.com/p/datanucleus-appengine/issues/detail?id=128 Unfortunately the only real workaround is to use named params instead of positional params. Do you think you can make that work? Max On Tue, Sep 15, 2009 at 7:36 AM, Max Ross maxr+appeng...@google.commaxr%2bappeng...@google.com wrote: Looks like a regression in handling of positional params. I could've sworn I had tests for these.but no, they don't exist. I'll follow up with a bug number you can use to track this issue. I'll also try to find you a workaround. Sorry for the trouble, Max On Tue, Sep 15, 2009 at 12:33 AM, damnpana...@googlemail.com damnpana...@googlemail.com wrote: I have a jpa/spring dao that returns a user by open id url. Running on sdk 1.2.1, his worked without a problem. moving to 1.2.2, and now 1.2.5, it no longer returns any records. Returning all records and using String.equals works fine: String openIdUrl = http://blah/me;; List results = em.createQuery(select u from +OpenIDUser.class.getName ()+ u where u.openIDUrl=?1).setParameter(1, openIdUrl).getResultList (); //results is size 0 List l = em.createQuery(select u from +OpenIDUser.class.getName()+ u).getResultList(); for(Object o: l){ String url = ((OpenIDUser)o).getOpenIDUrl(); if(openIdUrl.equals(url)){ //string matches return (OpenIDUser)o; } } I am assuming I have inadvertently screwed something up in my environment, but I'm struggling to get any more information - can anyone suggest any pointers? --~--~-~--~~~---~--~~ 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: Exception since upgrading to 1.2.5
I was also getting this error after upgrading to 1.2.5, except that in my case the javax.jdo.JDODetachedFieldAccessException was happening when I tried to access a simple 'com.google.appengine.api.datastore.Text' field on a Detached object (Datanucleus must be treating Enumerated fields like a Collection). I'm using JPA, so for every Text in my entities I had to add the annotation @Basic(fetch = FetchType.EAGER). Just FYI, because I'd never used a fetchtype on a non-collection field. Not sure if this is how it's supposed to work, but it fixes the issue. david On Sep 10, 1:13 am, hansamann sven.hai...@googlemail.com wrote: Hi all, since I updated my app to the latest java sdk, I sometimes see these errors (which results in the homepage of the app being blank or showing an ugly error message): [groovytweets/73.336182399219449559].stdout: StackTrace Sanitizing stacktrace: org.codehaus.groovy.runtime.InvokerInvocationException: javax.jdo.JDODetachedFieldAccessException: You have just attempted to access field retweets yet this field was not detached when you detached the object. Either dont access this field, or detach it when detaching the object. at org.codehaus.groovy.reflection.CachedMethod.invoke (CachedMethod.java:92) at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:234) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1062) at groovy.lang.ExpandoMetaClass.invokeMethod(ExpandoMetaClass.java: 926) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:893) at groovy.lang.Closure.call(Closure.java:279) at org.codehaus.groovy.grails.web.pages.GroovyPage.invokeTag (GroovyPage.java:219) at org.codehaus.groovy.grails.web.pages.GroovyPage$invokeTag $0.callCurrent(Unknown Source) at --~--~-~--~~~---~--~~ 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: Regarding Error in Jsp Code
It looks like there is a problem with your import statement: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:9: cannot find symbol [javac] symbol : class query [javac] location: package javax.jdo [javac] import javax.jdo.query; [javac] I think you want to import javax.jdo.Query here (note the difference in case). As for: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:144: cannot find symbol [javac] symbol : method getContent() [javac] location: class exe.exeEntry [javac] out.print(e.getContent()); [javac] ^ Your class exe.exeEntry does not have a method named getContent(), though it does have a field named content. You have to expose the getter/setter yourself. On Tue, Sep 15, 2009 at 3:14 AM, nimmala anukarthi nimmala.anukar...@gmail.com wrote: Hi rajeev, Thanks for your reply, i have included % % between the curly braces and compiled it again then iam getiing following error. HTTP ERROR: 500 Unable to compile class for JSP Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:9: cannot find symbol [javac] symbol : class query [javac] location: package javax.jdo [javac] import javax.jdo.query; [javac] ^ Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:116: cannot find symbol [javac] symbol : class Query [javac] location: class org.apache.jsp.ex_jsp [javac] Query query=pm.newQuery(SELECT * FROM +exeEntry.class.getName()); [javac] ^ Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:144: cannot find symbol [javac] symbol : method getContent() [javac] location: class exe.exeEntry [javac] out.print(e.getContent()); [javac] ^ Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:147: cannot find symbol [javac] symbol : method getPoster() [javac] location: class exe.exeEntry [javac] out.print(e.getPoster()); [javac] ^ Generated servlet error: [javac] Note: C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java uses unchecked or unsafe operations. Generated servlet error: [javac] Note: Recompile with -Xlint:unchecked for details. [javac] 4 errors RequestURI=/ex.jsp Caused by: org.apache.jasper.JasperException: Unable to compile class for JSP Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:9: cannot find symbol [javac] symbol : class query [javac] location: package javax.jdo [javac] import javax.jdo.query; [javac] ^ Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:116: cannot find symbol [javac] symbol : class Query [javac] location: class org.apache.jsp.ex_jsp [javac] Query query=pm.newQuery(SELECT * FROM +exeEntry.class.getName()); [javac] ^ Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:144: cannot find symbol [javac] symbol : method getContent() [javac] location: class exe.exeEntry [javac] out.print(e.getContent()); [javac] ^ Generated servlet error: [javac] C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java:147: cannot find symbol [javac] symbol : method getPoster() [javac] location: class exe.exeEntry [javac] out.print(e.getPoster()); [javac] ^ Generated servlet error: [javac] Note: C:\Users\DEVELO~1.ADM\AppData\Local\Temp\Jetty_127_0_0_1_8087_war-iudaqf\jsp\org\apache\jsp\ex_jsp.java uses unchecked or unsafe operations. Generated servlet error: [javac] Note: Recompile with -Xlint:unchecked for details. [javac] 4 errors at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84) at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:332) at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:412) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:472) at
[appengine-java] Re: Eclipse GWT update error
Miguel, I have now tried this - but not had any luck making it work as yet. I have downloaded and unzipped 'gwt-windows-1.6.4' - then put it into eclipse/plugins. If I try to 'Add App Engine SDK' - it just says: Failed to Initialise App Engine SDK at ./gwt-windows-1.6.4 - don't know why. One obvious thing - don't know if its significant - if you look inside the dirs for the other gwt versions installed - they have a number of things, like: appengine-sdk-plugin.jar, META-INF directory, etc as well as an appengine-java-sdk-xxx directory, but the newly downloaded/ unzipped directory only contains a 'gwt-windows-1.6.4' sub-directory. Andrew --~--~-~--~~~---~--~~ 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] Problem with a query that uses Date
I have this simple query: Query query = pm.newQuery(Contact.class); query.setFilter(accountKey == accountKeyParam lastActionDate lastActionDateParam); query.declareParameters(com.google.appengine.api.datastore.Key accountKeyParam, Date lastActionDateParam); query.declareImports(java.util.Date); public class Contact { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key key; @Persistent private Date latestActionDate; // ... } When I run this query I get this exception: javax.jdo.JDOUserException: Invalid import declaration : java.util.Date at org.datanucleus.jdo.NucleusJDOHelper.getJDOExceptionForNucleusException (NucleusJDOHelper.java:375) at org.datanucleus.jdo.JDOQuery.execute(JDOQuery.java:275) Any ideas why? Thanks --~--~-~--~~~---~--~~ 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: RPC call and variables
It is a clustered environment and you cannot assume that every request is run in the JVM. If you want to share data between requests you should persist them (data) in 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: Eclipse GWT update error
Hi Andrew, This is confusing, but the App Engine SDK and the GWT SDKs are separate SDKs (one does not contain the other) and they are added via separate preferences. Trying to add the GWT SDK via the App Engine preferences will fail in the manner that you described. To clarify, if you want to add a GWT SDK you need to navigate to *Window Preferences*, or *Eclipse Preferences* if you are on Mac OS X. Open the * Google* entry in the left pane and select *Web Toolkit.* On Tue, Sep 15, 2009 at 10:57 AM, AndrewG andrew.g...@rcrt.co.uk wrote: Miguel, I have now tried this - but not had any luck making it work as yet. I have downloaded and unzipped 'gwt-windows-1.6.4' - then put it into eclipse/plugins. If I try to 'Add App Engine SDK' - it just says: Failed to Initialise App Engine SDK at ./gwt-windows-1.6.4 - don't know why. One obvious thing - don't know if its significant - if you look inside the dirs for the other gwt versions installed - they have a number of things, like: appengine-sdk-plugin.jar, META-INF directory, etc as well as an appengine-java-sdk-xxx directory, but the newly downloaded/ unzipped directory only contains a 'gwt-windows-1.6.4' sub-directory. Andrew -- Miguel --~--~-~--~~~---~--~~ 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] Task Queues questions
Hi all, I'm thinking of using the Task Queue feature in order to split a particular resource consuming request which could hit the 30 secs request limits. I've got a few questions about queues (for the moment, maybe more are coming :-))... 1) is it possible to simulate a serial tasks execution? I was thinking of the following configuration for that. queue namequeue/name rate5/s/rate bucket-size1/bucket-size /queue 2) Where Can I find more information about what you call the special task scheduling parameters...?? 3) Is the quota total queue execution rate of 10/s a per queue basis quota or a global quota for all configured queues?? Thanks --~--~-~--~~~---~--~~ 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 GWT update error
Miguel, thank you - just before I picked up yr msg I figured out that I had tried to install it in the wrong place, and tried again. I have now (re-)installed the 'web toolkit' at v1.6.4, but I haven't yet reinstalled the app engine to its previous state. With just the toolkit re-installed, I am now getting a different set of errors: Project xxx is missing required library .. com.google.appenginesdkbundle_1_2_1 where the missing jars are things like: appengine-tools-api.jar, appengine-local-runtime-shared.jar, etc'. does this mean that the gwt sdk v 1.6.4 is closely tied to the appengine vn that was broken during the upgrade? - or is something else wrong - at the moment eclipse has appengine v1.2.5 installed - prior to the upgrade it was 1.2.1. I would like to get back to the configuration that I had before the upgrade (which worked) - but the only vn that I can see on the download page is v1.2.5 - so not sure where to get the 1.2.1 version - or is this a red herring and the errors are being caused by something else ? Thank you, Andrew --~--~-~--~~~---~--~~ 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 GWT update error
Let us know when you have something. On Tue, Sep 15, 2009 at 12:43 PM, AndrewG andrew.g...@rcrt.co.uk wrote: Miguel, I have sorted that last problem out - when I switched versions some 'phantom' jar references appeared in the build path - which I have removed. There is something else strange going on though - I will post again when I have pinned it down. Andrew -- Miguel --~--~-~--~~~---~--~~ 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 GWT update error
Miguel, ok - I think that I am closer to the problem now. At the moment I am running the web app under tomcat 6 with the re- installed gwt 1.6.4 sdk, following the problematic upgrade. There now appears to be what looks like a classloader problem - the various servlets which this app runs cannot now be created. When the web app starts you get the 'Error loading WebAppClassLoader' message - and then 'ClassNotFoundException' for each of the servlets defined in the project - so none of the servlets work. I have checked that the entries visible in the 'Build Path' - and everything seems right. This problem appears to be isolated to the gwt project - if I create a new dynamic web project from scratch in eclipse - it runs ok - so this is not just something in the tomcat installation that has broken. Also, if I run an 'export to war' of the web app - and run it in a stand-alone tomcat web server - it seems to work. My guess is that somehow - during the upgrade something in the low- level classes which the web server has to class-load in order to create and run servlets has got broken. Unfortunately, if this assumption is right, I have no idea how to find out what the offender might be and fix it. Andrew --~--~-~--~~~---~--~~ 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 reset the datastore
I seem to recall this question passing through the group before. But now I cannot find the answer (if there was one) in the maillist or in documentation... I would like to purge all data from my datastore on the App Engine. (I do this locally by deleting the 2 files in /WEB-INF/appengine-generated.) Is there a way to do this in bulk? Or do I need to use the Admin Console and delete one table at a time? TIA, Steve B. --~--~-~--~~~---~--~~ 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: self referral one-to-many relationship with null root
Can someone please answer it. I appreciate it. On Sep 14, 5:09 pm, Arash aras...@gmail.com wrote: I have a class which has a collection of itself as its children. It is mapped as : @Persistent private Group parent; @Persistent(mappedBy= parent) private ListGroup children; The problem is I cannot insert the root object. The call to makePersistent comes back successfully, but the entity is not in the database. I guess this object with this mapping can not have null parents. Is there anyway I can make the parent nullable? --~--~-~--~~~---~--~~ 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] java.lang.IllegalArgumentException: id or name, but not both, must be set in each key path element
I get this exception in my application. Anybody knows what is it about ? java.lang.IllegalArgumentException: id or name, but not both, must be set in each key path element at com.google.appengine.api.datastore.DatastoreApiHelper.translateError (DatastoreApiHelper.java:29) at com.google.appengine.api.datastore.DatastoreApiHelper.makeSyncCall (DatastoreApiHelper.java:56) at com.google.appengine.api.datastore.DatastoreServiceImpl$2.run (DatastoreServiceImpl.java:170) at com.google.appengine.api.datastore.TransactionRunner.runInTransaction (TransactionRunner.java:30) at com.google.appengine.api.datastore.DatastoreServiceImpl.put (DatastoreServiceImpl.java:158) at com.google.appengine.api.datastore.DatastoreServiceImpl.put (DatastoreServiceImpl.java:138) at com.google.appengine.api.datastore.DatastoreServiceImpl.put (DatastoreServiceImpl.java:134) at com.mably.webwinewatch.model.DatastoreEntity.save (DatastoreEntity.java:84) [...] Thanx for your help. François Bordeaux, FRANCE --~--~-~--~~~---~--~~ 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: Problem with a query that uses Date
Any ideas why? In Java when you have an import statement what do you write ? Something like import java.util.Date ? so do that for JDOQL --~--~-~--~~~---~--~~ 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: ClassLoading Problems in FileUpload Servlet
Toby, thanks for taking the time to respond, I appreciate it. First some things I should have said before, I am using the GAE Eclipse plug in. GWT 1.7, App Engine 1.2.5. What I don't understand is why other test applications seem to work quite hapilly with datastore without me adding a load of jars to the lib area. Those other applications are using GWT and for example the standard eclipse generated GreatingServer expanded to use PersistenceManager seem to work just fine. Now this may just be down to good/bad luck and the way that the google projects are structured and therefore work with Jetty etc. If the correct way to structure things is to explicitly put the GAE/ JDO/... jars in the war/WEB-INF/lib area should they be appearing on the classpath of the eclipse projects? And why do some projects/use cases (such as via GWT RCP) seem to work and others fail? Its coming up to midnight here, so I am going to sleep and revisit this in the morning, hopefully with a clear head I will be able to work out what I need to do, but any input on how to set up properly is really appreciated. J On Sep 15, 11:23 pm, Toby Reyelts to...@google.com wrote: John, The JDO/JPA support for App Engine lives entirely in userland. Like all the other libraries under the sdk's SDK_ROOT/lib/user folder, you must bundle it with your application in order to use it. One nice aspect about the ORM support living in userland is that you can easily apply patches or try new interim releases between official SDK releases. On Tue, Sep 15, 2009 at 6:17 PM, John john.r.nic...@gmail.com wrote: Actually I think I have simplified this further. The basic issue seems to be referencing anything to do with the datastore from an ordinary servlet. So if I have a servlet import java.io.IOException; import javax.jdo.JDOHelper; import javax.jdo.PersistenceManagerFactory; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; public class UploadFileServlet extends HttpServlet { �...@override protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { } private static final PersistenceManagerFactory PMF = JDOHelper.getPersistenceManagerFactory(transactions-optional); } and I send it a request I get the following exception WARNING: Nested in javax.servlet.ServletException: init: java.lang.NoClassDefFoundError: javax/jdo/JDOHelper at com.cloudscapesolutions.wavacalculator.server.UploadFileServlet.clinit (UploadFileServlet.java:18) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance (NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance (DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at java.lang.Class.newInstance0(Class.java:355) at java.lang.Class.newInstance(Class.java:308) at org.mortbay.jetty.servlet.Holder.newInstance(Holder.java:153) at org.mortbay.jetty.servlet.ServletHolder.getServlet (ServletHolder.java:339) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java: 463) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1093) at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter (TransactionCleanupFilter.java:43) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at com.google.appengine.tools.development.StaticFileFilter.doFilter (StaticFileFilter.java:121) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at org.mortbay.jetty.servlet.ServletHandler.handle (ServletHandler.java:360) at org.mortbay.jetty.security.SecurityHandler.handle (SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle (SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle (ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java: 405) at com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle (DevAppEngineWebAppContext.java:54) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java:139) at com.google.appengine.tools.development.JettyContainerService $ApiProxyHandler.handle(JettyContainerService.java:313) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:313) at
[appengine-java] Re: How to grow your data model over the long term
Purely from experimenting with this (if anyone can identify a reference to a good doc that would be great) I've succeeded with the just add the new fields approach described above. The hiccups I've experienced are that you have to use nullable types for your new properties (e.g. an int won't work but an Integer will) and, if you don't implement and execute some sort of batch update-everything-to- good-non-null-defaults process queries containing the new properties won't work as you might expect. Its definitely a source of some concern for me. Looking forward to the model migration segments of the JDO/JPA Snippets That Work series here (which seem like they are important enough to promote to blog posts or the like). --~--~-~--~~~---~--~~ 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: ClassLoading Problems in FileUpload Servlet
Ok having thought about what Toby said and allied to what I knew I went back to retest basics, which no longer worked!!! On investigation I see that all of my projects have empty lib areas, except for gwt- servlet.jar. I created a new Eclipse project and sure enough it has been created with all of the necessary jar files in the war/WEB-INF/lib area. I can't immediately think why/how the jars have been removed from the lib area, I am thinking it must be related to upgrading from App Engine 1.2.2 to App Engine 1.2.5 yesterday. Well thanks again Toby for the comments, they have helped me onto the right path hopefully and I can continue with a clearer model of how things are constructed. Now sleep ... John On Sep 15, 11:49 pm, John john.r.nic...@gmail.com wrote: Toby, thanks for taking the time to respond, I appreciate it. First some things I should have said before, I am using the GAE Eclipse plug in. GWT 1.7, App Engine 1.2.5. What I don't understand is why other test applications seem to work quite hapilly with datastore without me adding a load of jars to the lib area. Those other applications are using GWT and for example the standard eclipse generated GreatingServer expanded to use PersistenceManager seem to work just fine. Now this may just be down to good/bad luck and the way that the google projects are structured and therefore work with Jetty etc. If the correct way to structure things is to explicitly put the GAE/ JDO/... jars in the war/WEB-INF/lib area should they be appearing on the classpath of the eclipse projects? And why do some projects/use cases (such as via GWT RCP) seem to work and others fail? Its coming up to midnight here, so I am going to sleep and revisit this in the morning, hopefully with a clear head I will be able to work out what I need to do, but any input on how to set up properly is really appreciated. J On Sep 15, 11:23 pm, Toby Reyelts to...@google.com wrote: John, The JDO/JPA support for App Engine lives entirely in userland. Like all the other libraries under the sdk's SDK_ROOT/lib/user folder, you must bundle it with your application in order to use it. One nice aspect about the ORM support living in userland is that you can easily apply patches or try new interim releases between official SDK releases. On Tue, Sep 15, 2009 at 6:17 PM, John john.r.nic...@gmail.com wrote: Actually I think I have simplified this further. The basic issue seems to be referencing anything to do with the datastore from an ordinary servlet. So if I have a servlet import java.io.IOException; import javax.jdo.JDOHelper; import javax.jdo.PersistenceManagerFactory; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; public class UploadFileServlet extends HttpServlet { �...@override protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { } private static final PersistenceManagerFactory PMF = JDOHelper.getPersistenceManagerFactory(transactions-optional); } and I send it a request I get the following exception WARNING: Nested in javax.servlet.ServletException: init: java.lang.NoClassDefFoundError: javax/jdo/JDOHelper at com.cloudscapesolutions.wavacalculator.server.UploadFileServlet.clinit (UploadFileServlet.java:18) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance (NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance (DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at java.lang.Class.newInstance0(Class.java:355) at java.lang.Class.newInstance(Class.java:308) at org.mortbay.jetty.servlet.Holder.newInstance(Holder.java:153) at org.mortbay.jetty.servlet.ServletHolder.getServlet (ServletHolder.java:339) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java: 463) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1093) at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter (TransactionCleanupFilter.java:43) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at com.google.appengine.tools.development.StaticFileFilter.doFilter (StaticFileFilter.java:121) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter (ServletHandler.java:1084) at org.mortbay.jetty.servlet.ServletHandler.handle (ServletHandler.java:360) at org.mortbay.jetty.security.SecurityHandler.handle
[appengine-java] Re: cron query
no... On Wed, Sep 16, 2009 at 3:47 AM, bgood ben.mcgee.g...@gmail.com wrote: Is it possible to specify the start time for a scheduled task that happens at regular intervals? For example, if I want something to happen at 12:00, 12:10, 12:20 ... (not e.g. 12:03, 12:13, 12:23...) ? thanks --~--~-~--~~~---~--~~ 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: cron query
no... On Wed, Sep 16, 2009 at 3:47 AM, bgood ben.mcgee.g...@gmail.com wrote: Is it possible to specify the start time for a scheduled task that happens at regular intervals? For example, if I want something to happen at 12:00, 12:10, 12:20 ... (not e.g. 12:03, 12:13, 12:23...) ? thanks --~--~-~--~~~---~--~~ 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] Accessing file from within a jar file
How do you access a file inside of a jar file in the appengine? I was able to successfully do it on my local box, but i get a FileNotFoundException while in the cloud. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
[google-appengine] Re: City, County, State lookup by 'PostalAddressProperty'
Probably not. You could possibly using the Google Maps API Geocoder (if already using the maps API only!) to get structured data, and store in separate properties. You would then need some sort of 'group by' functionality to get lists of (for example) cities, there is no native way to do this in GAE, need to implement something to perform aggregation. (either at write time, or a long running task - using cron/tasks) On 15/09/2009, PatHaugen pathau...@gmail.com wrote: Are there any simple ways to do location lookups in GAE using the PostalAddressProperty? I manually made arrays with all the cities in a few states using US Census data for cities with parent counties, found it insane, there has to be a better way right? On Sep 14, 2:30 pm, Barry Hunter barrybhun...@googlemail.com wrote: It looks like really its just a text field - nothing magic http://code.google.com/apis/gdata/docs/1.0/elements.html#gdPostalAddress On 14/09/2009, PatHaugen pathau...@gmail.com wrote: Currently, grouping together users by physical area has been a challenge I've met a few ways in various projects by having a 'city' field and using my own arrays with cities of all states, county arrays that contain multiple cities, and doing queries using these to find all people in a county or in a state, etc. Google's 'PostalAddressProperty' got me excited and I was wondering if there is a way to use this to simplify lookups for cities (based on zips), counties, states, etc with simple queries on this special field? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Open Letter to Ryan Barrett and the AppEngine Team regarding high availability
Dear Ryan: I did read your Sep. 14 posting on the megastore transition with interest. I also viewed your presentation at Google I/O. I am very impressed by the effort that the team is putting to make GAE scaleable, highly available and minimize downtime. In your talk multiple times you mentioned how unacceptable a two hour downtime is and you gave the SVColo incident that brought down Tweeter and FriendFeed a few times. So you seem to get it!!! Unfortunately, the reality I see and face in the ground for the past 16 months is different. As I am writing this, I have 2 GAE powered sites down for TWO DAYS[1] and I am still waiting. The root cause? Simple index count quotas reseting issues that Google can solve on your end in minutes by resetting counters. In a similar situation in June[2], it took SEVEN DAYS to resolve the problem. Same issue in January took FOUR DAYS to get resolved[4]. Same issue is October 2008 took THREE DAYS to resolve[5]. Do you find this response acceptable? If you read the postings I refer to, you will see that most of the time was wasted in round trip communication across timezones!!! Several bugs have been filed on the index quotas issues but they have not been addressed. You cannot believe how frustrating and unproductive is to be in my shoes: 1. I dont know when anybody from Google will read my postings... 2. It can take up to 12 hours between replies. 3. For hours, I have to check the discussion group every ten minutes to see if somebody will read/take action/reply to my messages. Who can run a successful service with this kind of support? In addition to investments in multihoming, data centers and all the other great projects you describe, Google needs to invest in fixing the relatively simples issues (like [3]) first. This will make us self sufficient. It also must beef up support. A couple of months ago I posted a note on what Google can do to improve Google App Engine Support[6]. I received a lot of positive feedback from the community but official GAE did not even reply to the posting. The situation I currently see makes me wonder whether GAE as a whole has its priorities right. Right now I definetely feel that the customer is not the priority. Thanks for reading, I hope this message will help Google focus on the buring issues first and improve Google App Engine. Best Regards, Peter http://www.gae123.com REFERENCES 1. http://groups.google.com/group/google-appengine-python/browse_thread/thread/688aa5d0d376bd9f 2. http://groups.google.com/group/google-appengine/browse_thread/thread/d5c17a116e81d266 3. http://groups.google.com/group/google-appengine/browse_thread/thread/e0c5bd1a19c945c1 4. http://groups.google.com/group/google-appengine/browse_thread/thread/4f98d2c04fac0fb9/715e7def1a361ec9?show_docid=715e7def1a361ec9 5. Direct e-mail communication with Mar. Nic., available upon request 6. http://groups.google.com/group/google-appengine/browse_thread/thread/03fd57a38f130dee --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 'ReferenceProperty' query filtering?
Hi, I think you are trying to filter the ReferenceProperty as a string, this won't work. You need to; query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) Doc on the Datastore ReferenceProperty; http://code.google.com/appengine/docs/python/datastore/entitiesandmodels.html#References Thanks, Arun Shanker Prasad. On Sep 15, 8:54 am, PatHaugen pathau...@gmail.com wrote: Jumping into GAE, I found the ReferenceProperty interesting but still don't fully understand it. My question can expand on the example from:http://code.google.com/appengine/docs/python/datastore/creatinggettin... class PetOwner(db.Model): name = db.StringProperty() class Pet(db.Model): name = db.StringProperty() type = db.StringProperty() # cat, dog, etc. owner = db.ReferenceProperty(PetOwner) Let's do a query to select all cats with a specific owner. query = db.Query(Pet) query = Pet.all() query.filter('type = ', 'Cat') results = query.fetch(limit=10) for result in results: output = result.name return output What can I add to this to filter only those where 'owner' is 'johndoe'? I tried: query.filter('owner = ', 'johndoe') However it fails to return me a result, and I know you can pull the owner name via 'pet.owner.name' however trying: query.filter('owner.name = ', 'johndoe') Also fails, though it made sense for what should work. Does anyone know the proper method? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Server Error (500) Indexes stuck in building
Hi, Sounds similar to a problem I had sometime back; http://groups.google.com/group/google-appengine/browse_thread/thread/ed380a3d752133ae Thanks, Arun Shanker Prasad. On Sep 15, 5:21 am, Ben bhym...@gmail.com wrote: Thanks Nick, but i am still having some problems. After your changes the problem items were in error state, i removed them from my index.yaml file and then updated the indexes which caused them to go into a deleting state as expected. after a few minutes they all disappeared from indexes page of the dashboard. However, when i try to deploy a new version with new indexes or if i run update_indexes i still am getting the Server Error (500) error and my new indexes are not implemented. Help! On Sep 14, 5:43 am, Nick Johnson (Google) nick.john...@google.com wrote: Hi Ben, I've reset your indexes - you should be able to vacuum and rebuild them now. -Nick Johnson On Sun, Sep 13, 2009 at 6:07 PM, Ben bhym...@gmail.com wrote: Hi I added a bunch of new indexes and deleted a bunch of old ones. The old ones seem to have been properly deleted, but the new ones are stuck in building. I have less than 100 total indexes. can i get a reset? my appID is orangevsblack -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Server Error (500) Indexes stuck in building
Hi Ben, I've reset your index count quota - you should be able to upload new indexes now. -Nick On Tue, Sep 15, 2009 at 1:21 AM, Ben bhym...@gmail.com wrote: Thanks Nick, but i am still having some problems. After your changes the problem items were in error state, i removed them from my index.yaml file and then updated the indexes which caused them to go into a deleting state as expected. after a few minutes they all disappeared from indexes page of the dashboard. However, when i try to deploy a new version with new indexes or if i run update_indexes i still am getting the Server Error (500) error and my new indexes are not implemented. Help! On Sep 14, 5:43 am, Nick Johnson (Google) nick.john...@google.com wrote: Hi Ben, I've reset your indexes - you should be able to vacuum and rebuild them now. -Nick Johnson On Sun, Sep 13, 2009 at 6:07 PM, Ben bhym...@gmail.com wrote: Hi I added a bunch of new indexes and deleted a bunch of old ones. The old ones seem to have been properly deleted, but the new ones are stuck in building. I have less than 100 total indexes. can i get a reset? my appID is orangevsblack -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: No Handlers matched this URL - Warning - What does it mean?
That is correct literal interpretation. However, this warning generated by App Engine JAVA version so cryptic, and not enough trace. On my regular dev machine, this error never occurred. It took me to install in different dev machine to trace the error. This error means that somewhere is a null pointer or data not available. The URL is correct but the trace did not have enough information. On Sep 14, 2:03 pm, Wooble geoffsp...@gmail.com wrote: None of the URL mappings you set up in app.yaml (or web.xml; you don't say what runtime you're using) are matching the URL '/' On Sep 14, 10:46 am, Shirish shirishran...@gmail.com wrote: 09-12 11:01PM 21.595 /favicon.ico 404 5ms 0cpu_ms 0kb Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_5_8; en-us) AppleWebKit/531.9 (KHTML, like Gecko) Version/4.0.3 Safari/531.9,gzip(gfe) 24.34.250.89 - - [12/Sep/2009:23:01:21 -0700] GET /favicon.ico HTTP/ 1.1 404 0 http://1-21.latest.awetechnology.appspot.com/; Mozilla/ 5.0 (Macintosh; U; Intel Mac OS X 10_5_8; en-us) AppleWebKit/531.9 (KHTML, like Gecko) Version/4.0.3 Safari/531.9,gzip(gfe) 1-21.latest.awetechnology.appspot.com W 09-12 11:01PM 21.595 No handlers matched this URL. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: No Handlers matched this URL - Warning - What does it mean?
Hi Shirish, As Wooble says, the error means that the URL in question (/favicon.ico, not /) is not mapped in your app. It may not have shown up on your local server if your browser doesn't request favicon.ico, but other browsers do. Unless you want to serve up a favicon.ico to users, you don't need to worry about it. -Nick Johnson On Tue, Sep 15, 2009 at 2:47 PM, Shirish shirishran...@gmail.com wrote: That is correct literal interpretation. However, this warning generated by App Engine JAVA version so cryptic, and not enough trace. On my regular dev machine, this error never occurred. It took me to install in different dev machine to trace the error. This error means that somewhere is a null pointer or data not available. The URL is correct but the trace did not have enough information. On Sep 14, 2:03 pm, Wooble geoffsp...@gmail.com wrote: None of the URL mappings you set up in app.yaml (or web.xml; you don't say what runtime you're using) are matching the URL '/' On Sep 14, 10:46 am, Shirish shirishran...@gmail.com wrote: 09-12 11:01PM 21.595 /favicon.ico 404 5ms 0cpu_ms 0kb Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_5_8; en-us) AppleWebKit/531.9 (KHTML, like Gecko) Version/4.0.3 Safari/531.9,gzip(gfe) 24.34.250.89 - - [12/Sep/2009:23:01:21 -0700] GET /favicon.ico HTTP/ 1.1 404 0 http://1-21.latest.awetechnology.appspot.com/; Mozilla/ 5.0 (Macintosh; U; Intel Mac OS X 10_5_8; en-us) AppleWebKit/531.9 (KHTML, like Gecko) Version/4.0.3 Safari/531.9,gzip(gfe) 1-21.latest.awetechnology.appspot.com W 09-12 11:01PM 21.595 No handlers matched this URL. -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Server Error (500) Indexes stuck in building
Thanks Nick, that seems to have done the trick! On Sep 15, 8:32 am, Nick Johnson (Google) nick.john...@google.com wrote: Hi Ben, I've reset your index count quota - you should be able to upload new indexes now. -Nick On Tue, Sep 15, 2009 at 1:21 AM, Ben bhym...@gmail.com wrote: Thanks Nick, but i am still having some problems. After your changes the problem items were in error state, i removed them from my index.yaml file and then updated the indexes which caused them to go into a deleting state as expected. after a few minutes they all disappeared from indexes page of the dashboard. However, when i try to deploy a new version with new indexes or if i run update_indexes i still am getting the Server Error (500) error and my new indexes are not implemented. Help! On Sep 14, 5:43 am, Nick Johnson (Google) nick.john...@google.com wrote: Hi Ben, I've reset your indexes - you should be able to vacuum and rebuild them now. -Nick Johnson On Sun, Sep 13, 2009 at 6:07 PM, Ben bhym...@gmail.com wrote: Hi I added a bunch of new indexes and deleted a bunch of old ones. The old ones seem to have been properly deleted, but the new ones are stuck in building. I have less than 100 total indexes. can i get a reset? my appID is orangevsblack -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: TombstonedTaskError
On Mon, Sep 14, 2009 at 11:39 PM, Benjamin Schuster-Böckler b...@pearcomp.com wrote: Ok, I was mislead then. I thought I could use the task name to check if a task is still in the queue, by catching TaskAlreadyExistsError. What's the best way to know if a task is still queued, then? Set a flag in the datastore when the task has executed, and check for the existence of this flag. Task names are intended to prevent duplicate tasks being queued - for example, if you want to enqueue at most one task per minute, you could name the task mytask-%Y%m%d (substituting in the appropriate date). -Nick Johnson Best, Benjamin On 15 Sep 2009, at 00:36, Nick Johnson (Google) wrote: Hi Benjamin, As the docs say, tombstoned tasks stay that way for at least a week. Generally you should never try and reuse a task name - generate a task you expect to be unique each time. -Nick Johnson On Mon, Sep 14, 2009 at 11:19 PM, Benjamin Schuster-Böckler b...@pearcomp.com wrote: I'm getting these a lot when trying to add new tasks to a queue. My understanding is that GAE will keep a tombstone for a task that quit recently, and if I try to add another task with the same name, it'll bum out. How long is this tombstone gonna stay in place? The tasks that are raising this exception have finished several hours ago. I can't find any information on this in the docs either. Thanks for the info, best, Benjamin -- Benjamin Schuster-Böckler Pear Computer LLP 86 Cavendish Road Cambridge CB1 3AF United Kingdom Company No. OC340192 VAT No. 971 3948 85 -- Nick Johnson, Developer Programs Engineer, App Engine -- Benjamin Schuster-Böckler Pear Computer LLP 86 Cavendish Road Cambridge CB1 3AF United Kingdom Company No. OC340192 VAT No. 971 3948 85 -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: simultaneous dynamic requests limitation
Hi, As apps scale up and get more traffic, this limit is increased proportional to the traffic you're getting. -Nick Johnson On Sat, Sep 12, 2009 at 3:05 AM, mitnickcbc mitnick...@gmail.com wrote: Hi, I'm leveraging GAE recently and I'm very impressive by the improvements GAE has made during the last 12 months. 12 month ago, I have no option but to migrate my app to EC2 due to the high amount CPU limitation and non-billable quota on GAE. I'm glad to see that these two issues have been resolved. However, there is one limitation which I cannot understand, the simultaneous dynamic requests. The document said the limitation is about 30 simultaneous dynamic requests. I know it's a pretty big number, but it still sets a limitation there which prevents our apps to become super popular. And the project I'm going to build is expecting large amount of requests from each user, which is very likely to have problem with this limitation. The question is, is there any possibility to remove this limitation? Or do we have workaround if we hit this limitation? I really don't want to see this become another high amount CPU limitation, which gives me one month bad sleeps. -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Reaching 10 apps. Can someone at Google please help.
Hi observer, I've increased the number of apps you can create to 20. -Nick Johnson On Mon, Sep 14, 2009 at 7:56 PM, observer247 prem...@gmail.com wrote: I like the app engine platform and have spent quite a lot of time to learn python and now I use app engine for most of the things I need to do on the web. I have already reached 9 apps and I have around 5 apps ready to be deployed. Can someone please increase the number of apps to 20. I have a billable account and I would like to work the legitimate way instead of trying to use others account etc. Thanks and will really appreciate this ! -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Reached Apps Limits
Hi Lassina, I've increased the number of apps you can create to 20. -Nick Johnson On Sat, Sep 12, 2009 at 10:07 PM, Lassina Ouattara bbd...@gmail.com wrote: Can I get an increase? I Need to deploy a couple of more apps but I have already reached the 10 applications per username limit. I actually have twelve but two of them were shared with me, If an admin can increase the limit for my username that will be great! - Zie Lassina Ouattara -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Run your Lucene Applications on Google AppEngine with GAELucene
Hi lhelper, Interesting project! Have you tested it with a large corpus of text to search? -Nick Johnson On Mon, Sep 14, 2009 at 5:23 PM, lhelper lhel...@gmail.com wrote: Enlightened by the discussion Can I run Lucene in google app engine? [http://www.nabble.com/Can-I-run-Lucene-in-google-app-engine-- td23017742.html], I implemented a google datastore based Lucene component, GAELucene, which can help you to run search applications on google app engine. The main clazz of GAELucene include: * GAEDirectory - a read only Directory based on google datastore. * GAEFile - stands for an index file, the file's byte content will be splited into multi GAEFileContent. * GAEFileContent - stands for a segment of index file. * GAECategory - the identifier of different indices. * GAEIndexInput - a memory-resident IndexInput? implementation like the RAMInputStream. * GAEIndexReader - wrapper for IndexReader? that cached in GAEIndexReaderPool * GAEIndexReaderPool - pool for GAEIndexReader The following code snippet demonstrates the use of GAELucene do searching: Query queryObject = parserQuery(request); GAEIndexReaderPool readerPool =GAEIndexReaderPool.getInstance(); GAEIndexReader indexReader = readerPool.borrowReader (INDEX_CATEGORY_DEMO); IndexSearcher searcher =newIndexSearcher(indexReader); Hits hits = searcher.search(queryObject); readerPool.returnReader(indexReader); You can find more here 'http://code.google.com/p/gaelucene' -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 1000 entity limit?
Interesting. That seems kinda tedious. So suppose someone were to write a wrapper around the datastore get API that handled the 1000 entity limit by automatically splitting queries into 1k groups, but returned them seamlessly to the user as if they were one query. Would that be a violation of the appengine TOS? Would users of such a wrapper risk having their app shut off? On Sep 15, 12:48 am, 风笑雪 kea...@gmail.com wrote: You can sort the entities by __key__, and get the first 1000 entities. Then add a filter for __key__ that bigger(or smaller) than the 1000th entity, to get 1001st to 2000th entities, and so on. 2009/9/15 Locke locke2...@gmail.com: From the documentation: maximum number of entities in a batch get: 1000 Does this mean that if I have say 5000 accounts which I am keeping track of in the datastore, and I do a query to list all of them, it would not work? I would have to do five queries in a row, hard coding distinct queries to get account numbers 0-999, 1000-1999, 2000-2999, 3000-3999, and 4000-4999? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 1000 entity limit?
Hi Locke, If you want to write such a wrapper, you're quite welcome to - it's certainly not a violation of the TOS or anything like that. We'd encourage you to examine why you need to do this, though - do you really need to return several thousand results in a single request? Will your users be able to use an interface that includes thousands of items? -Nick On Tue, Sep 15, 2009 at 3:53 PM, Locke locke2...@gmail.com wrote: Interesting. That seems kinda tedious. So suppose someone were to write a wrapper around the datastore get API that handled the 1000 entity limit by automatically splitting queries into 1k groups, but returned them seamlessly to the user as if they were one query. Would that be a violation of the appengine TOS? Would users of such a wrapper risk having their app shut off? On Sep 15, 12:48 am, 风笑雪 kea...@gmail.com wrote: You can sort the entities by __key__, and get the first 1000 entities. Then add a filter for __key__ that bigger(or smaller) than the 1000th entity, to get 1001st to 2000th entities, and so on. 2009/9/15 Locke locke2...@gmail.com: From the documentation: maximum number of entities in a batch get: 1000 Does this mean that if I have say 5000 accounts which I am keeping track of in the datastore, and I do a query to list all of them, it would not work? I would have to do five queries in a row, hard coding distinct queries to get account numbers 0-999, 1000-1999, 2000-2999, 3000-3999, and 4000-4999? -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Can't access the dashboard anymore
Hi Rud, Are you logging in from http://appengine.google.com/a/k5rud.us ? -Nick Johnson On Fri, Sep 11, 2009 at 8:41 PM, Rud k5...@k5rud.us wrote: More information on this problem... I used my wife's cell to get an SMS. I created an application but after that it takes me right back to the create application page. Created another application and right back again. From My Account, I click on my applications and go right back to the create application page. Rud On Sep 10, 8:53 pm, Rud rudmerr...@gmail.com wrote: I am having the same problem. Rud On Sep 9, 6:56 pm, Riyadh rias.sher...@gmail.com wrote: I posted this message in response to another thread but for some reason it is not shown there. So here we go again :-) --- Hi everyone, A few weeks ago I created my GAE account and set up two applications. I deployed them using Eclipse - several times, over a course of about two weeks. Everything was working fine. Then, a few days ago, I tried to log in to my GAE account usinghttps:// appengine.google.com/andhttps://appengine.google.com/a/MYDOMA... and all I see is the page that says Create an application - just as if I never created an application before. For some strange reason both of my applications are still accessible when I open them viahttp://MYDOMAIN.TLD-so they're not down or something like that. The only thing is that I can't access their Dashboard using the above URLs. I can still deploy the applications using Eclipse. I also tried creating a new application and when I entered my cell phone number during the verification step it says The phone number has been sent too many messages or has already been used to confirm an account.. How can I get access to my applications and - more importantly - to the database contents (without writing some Servlet that exports them). I didn't do anything to my Google accounts lately so I guess it's some GAE issue. By the way: in Google Apps I still see my domains being connected to Google AppEngine. Many thanks R.- Hide quoted text - - Show quoted text - -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Run your Lucene Applications on Google AppEngine with GAELucene
Hi ihelper, This is really what i am looking for. Great project, great contribution. 2009/9/15 Nick Johnson (Google) nick.john...@google.com Hi lhelper, Interesting project! Have you tested it with a large corpus of text to search? -Nick Johnson On Mon, Sep 14, 2009 at 5:23 PM, lhelper lhel...@gmail.com wrote: Enlightened by the discussion Can I run Lucene in google app engine? [http://www.nabble.com/Can-I-run-Lucene-in-google-app-engine-- td23017742.htmlhttp://www.nabble.com/Can-I-run-Lucene-in-google-app-engine--%0Atd23017742.html], I implemented a google datastore based Lucene component, GAELucene, which can help you to run search applications on google app engine. The main clazz of GAELucene include: * GAEDirectory - a read only Directory based on google datastore. * GAEFile - stands for an index file, the file's byte content will be splited into multi GAEFileContent. * GAEFileContent - stands for a segment of index file. * GAECategory - the identifier of different indices. * GAEIndexInput - a memory-resident IndexInput? implementation like the RAMInputStream. * GAEIndexReader - wrapper for IndexReader? that cached in GAEIndexReaderPool * GAEIndexReaderPool - pool for GAEIndexReader The following code snippet demonstrates the use of GAELucene do searching: Query queryObject = parserQuery(request); GAEIndexReaderPool readerPool =GAEIndexReaderPool.getInstance(); GAEIndexReader indexReader = readerPool.borrowReader (INDEX_CATEGORY_DEMO); IndexSearcher searcher =newIndexSearcher(indexReader); Hits hits = searcher.search(queryObject); readerPool.returnReader(indexReader); You can find more here 'http://code.google.com/p/gaelucene' -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 -- http://daily.appspot.com/food/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Open Letter to Ryan Barrett and the AppEngine Team regarding high availability
Your criticism seems legit, I just wanted to point out the following: * This is a preview release of Google App Engine. It certainly seems that appengine is less mature than some of the other cloud offerings. But it also looks to be more promising over the long term, if they get it right. Combine that with free hosting for low-load apps, and here we are, despite having to deal with the growing pains :-) On Sep 15, 9:02 am, ramu rslet...@gmail.com wrote: +1 for this .. I have also been thinking to post something. Though since my app is not mission critical and Failures get corrected by next minute cron update but I still get frustrated when the same entity which was accessed successfully for last 100 times (read only) gets sudden read Timeout Error from datastore. So what if I had something critical or I plan to do somthing more importand in future. The situation start getting worse if you MUST provide a hundred *try:except* pairs and fallbacks... due to these kind of totally random errors. On Sep 15, 3:01 pm, gae123 pa...@gae123.com wrote: Dear Ryan: I did read your Sep. 14 posting on the megastore transition with interest. I also viewed your presentation at Google I/O. I am very impressed by the effort that the team is putting to make GAE scaleable, highly available and minimize downtime. In your talk multiple times you mentioned how unacceptable a two hour downtime is and you gave the SVColo incident that brought down Tweeter and FriendFeed a few times. So you seem to get it!!! Unfortunately, the reality I see and face in the ground for the past 16 months is different. As I am writing this, I have 2 GAE powered sites down for TWO DAYS[1] and I am still waiting. The root cause? Simple index count quotas reseting issues that Google can solve on your end in minutes by resetting counters. In a similar situation in June[2], it took SEVEN DAYS to resolve the problem. Same issue in January took FOUR DAYS to get resolved[4]. Same issue is October 2008 took THREE DAYS to resolve[5]. Do you find this response acceptable? If you read the postings I refer to, you will see that most of the time was wasted in round trip communication across timezones!!! Several bugs have been filed on the index quotas issues but they have not been addressed. You cannot believe how frustrating and unproductive is to be in my shoes: 1. I dont know when anybody from Google will read my postings... 2. It can take up to 12 hours between replies. 3. For hours, I have to check the discussion group every ten minutes to see if somebody will read/take action/reply to my messages. Who can run a successful service with this kind of support? In addition to investments in multihoming, data centers and all the other great projects you describe, Google needs to invest in fixing the relatively simples issues (like [3]) first. This will make us self sufficient. It also must beef up support. A couple of months ago I posted a note on what Google can do to improve Google App Engine Support[6]. I received a lot of positive feedback from the community but official GAE did not even reply to the posting. The situation I currently see makes me wonder whether GAE as a whole has its priorities right. Right now I definetely feel that the customer is not the priority. Thanks for reading, I hope this message will help Google focus on the buring issues first and improve Google App Engine. Best Regards, Peterhttp://www.gae123.com REFERENCES 1.http://groups.google.com/group/google-appengine-python/browse_thread/... 2.http://groups.google.com/group/google-appengine/browse_thread/thread/... 3.http://groups.google.com/group/google-appengine/browse_thread/thread/... 4.http://groups.google.com/group/google-appengine/browse_thread/thread/... 5. Direct e-mail communication with Mar. Nic., available upon request 6.http://groups.google.com/group/google-appengine/browse_thread/thread/... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 1000 entity limit?
I would not be returning thousands of rows to users. This would be for background tasks executed via cron. The hard limits appengine imposes (30 seconds, 1000 query results, etc.) all seem quite reasonable for interactive apps, but for non- interactive background tasks, it looks like a lot of hacking will be required to get around those limits. It would be nice if appengine were to someday support longer-running, bigger background tasks. Until then, it sounds like we will have to basically hash our datastores, chain TaskQueue operations, and do other shenanigans if we want to run big background jobs. On Sep 15, 11:21 am, Nick Johnson (Google) nick.john...@google.com wrote: Hi Locke, If you want to write such a wrapper, you're quite welcome to - it's certainly not a violation of the TOS or anything like that. We'd encourage you to examine why you need to do this, though - do you really need to return several thousand results in a single request? Will your users be able to use an interface that includes thousands of items? -Nick On Tue, Sep 15, 2009 at 3:53 PM, Locke locke2...@gmail.com wrote: Interesting. That seems kinda tedious. So suppose someone were to write a wrapper around the datastore get API that handled the 1000 entity limit by automatically splitting queries into 1k groups, but returned them seamlessly to the user as if they were one query. Would that be a violation of the appengine TOS? Would users of such a wrapper risk having their app shut off? On Sep 15, 12:48 am, 风笑雪 kea...@gmail.com wrote: You can sort the entities by __key__, and get the first 1000 entities. Then add a filter for __key__ that bigger(or smaller) than the 1000th entity, to get 1001st to 2000th entities, and so on. 2009/9/15 Locke locke2...@gmail.com: From the documentation: maximum number of entities in a batch get: 1000 Does this mean that if I have say 5000 accounts which I am keeping track of in the datastore, and I do a query to list all of them, it would not work? I would have to do five queries in a row, hard coding distinct queries to get account numbers 0-999, 1000-1999, 2000-2999, 3000-3999, and 4000-4999? -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Make number of task insertions per day a billable quota
I use the task queue for some heavy lifting background updating. I create a single task for a URLfetch call and subsequent parsing, and storing, of data in a page. I would need a quota of ~2 per day, to keep a cycle of updating some 8 pages every 4 days. Are there any plans of extending this limitation, or making it a billable quota? The task queue is tremendously useful, but a hard limit for number of tasks per day defeats the purpose a little... Best, Benjamin -- Benjamin Schuster-Böckler Pear Computer LLP 86 Cavendish Road Cambridge CB1 3AF United Kingdom Company No. OC340192 VAT No. 971 3948 85 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Best way to reuse 'error page' code?
self.error() in webapp also clears anything that's previously been put into the response, so after the call to error() you can send a pretty error page with self.response.out.write() calls. On Sep 14, 8:06 pm, OvermindDL1 overmind...@gmail.com wrote: On Mon, Sep 14, 2009 at 2:58 PM, PatHaugen pathau...@gmail.com wrote: I'm with you, I prefer in scripting languages to have a single file to hold most of my project so I can backup and work on it anywhere easily. I used to store page output to a variable in PHP and add to it as the code executed, sending to the user only at the end of file and just trashing that variable if there was an error. Sounds similar to what you're hinting at. Basically yep. I created a tree structure in my classes like this: class someController(myBaseController): def index(request,response): # do stuff And if I set someController as a variable in another controller or I stuffed it in as the root controller, say I did a root controller, then anytime I did my_website.com/index then it would call the above. The request includes all headers parsed out, the full uri parsed out, and a lot of other stuff, it is designed to be immutable. The response has a header that you can stuff headers in, a content to stuff the response webpage/file/whatever into, etc... I can literally just do: response.reset(DefaultResponses.error500) And it kills the original response, overwriting it with the stuff in the pre-built error505 response, then I am free to edit the response again as I so wish. I just have it so if an error is occurred, I do something like this: class someController(myBaseController): def index(request,response): # this page will always just error 500 out if True: response.reset(DefaultResponses.error500) return It works quite well for me and my programming style when I am whipping up small things, very modular and capable. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Load Django Template from database
You should be able to do something like foo = db.get(templatekey).templatetext # or however else you want to fetch your template from the db... bar = template.Template(foo) self.response.out.write(bar.render(template_values)) Note: {% extends %} and other template tags that try to load stuff from the disk are going to fail horribly, unless of course you're only extending templates are are actually application files; I don't believe there's a good way to extend a template that's also stored in the db. On Sep 14, 9:11 pm, PatHaugen pathau...@gmail.com wrote: I usually store my custom templates in the database for web editing and version tracking. I was interested in Django with GAE, however with the inability to write out files to the disk, web editing wasn't possible since I found I couldn't call Django templates from the database: templatepage = 'templates?template=templatename' path = os.path.join(os.path.dirname(__file__), templatepage) self.response.out.write(template.render(path, template_values)) However I get TemplateDoesNotExist Is there an alternative way that enables Django loading of the file from the database anyone can think of? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Load Django Template from database
On Sep 15, 2:08 pm, Wooble geoffsp...@gmail.com wrote: self.response.out.write(bar.render(template_values)) correction: you'll need to wrap template_values in template.Context(); template.render() does this for you automagically. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: billing question
CPU billing is for CPU usage only, it has nothing to do with day-hours or request duration. Normally CPU usage is less than request duration. And, i am not sure about your archive download example. i think CPU usage would not be 1 min even if download lasts for 1 min. 2009/9/13 Martinfay dam...@gmail.com Hello I am going to start with Google App Engine but i have a doubt.The cpu quota limit is 6.5 hours.does it means for example that if i have a request that last 1 minute( download an archive).In 6.5 hours i could attend about 2 archives per cpu minute ? The cpu billing is only per duration of the requests,is not it? or does it means that i can only have my app on for 6.5 hours and the rest of the day i have to pay no matter if i have or not have request like in Amazon?. Sorry to for this simple question but english is not my first language and it is not clear to me. Well i will continue getting starting and learning more. Thanks Martin --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] 500 severe error Question!
hello,everyone! the data i put in datastore follows: User: ID/Name Date user 4029 2009-09-09 00:57:40.532377 cody and i would like to do the following: q = db.GqlQuery(SELECT * FROM User WHERE Date date(2009,09,10)) result = q.fetch(5) or: q = db.GqlQuery(SELECT * FROM User WHERE Date :1,date(2009,09,10)) result = q.fetch(5) The idea is to find a row that has been stored earlier... but every time i get a 500 severe error... type 'exceptions.TypeError': 'module' object is not callable Traceback (most recent call last): How can I solve this?? Thanks in advance,CODY --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] i am a GAE rookie
i will be glad to share and read opinions about GAE design --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] SearchableModel
Hi guys, I can't seem to find good resources for SearchableModel. Could you point me to those resources, please? Thank you! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Server error without any log
I've been using the standard 0.96 version of django built-in to appengine with my app and have had the same DeadlineExceededErrors for the past two weeks. My app has worked fine for the last 9 months. I've tried the last 5 versions of my app to see if the problem was related to any code changes I've made, but I get the DeadlineExceededErrors on all of them, so I don't think it's related to any of my code. It definitely seems like django is not getting properly loaded, as all the errors I've seen seem to be related to django modules not being found. Here is a one from this morning. class 'google.appengine.runtime.DeadlineExceededError': Traceback (most recent call last): File /base/data/home/apps/gqueues/beta2-7-9.336205351043982571/ gqueues.py, line 23, in module from controllers.admin import AdminHandler File /base/data/home/apps/gqueues/beta2-7-9.336205351043982571/ controllers/admin.py, line 10, in module from controllers.baserequest import BaseRequestHandler File /base/data/home/apps/gqueues/beta2-7-9.336205351043982571/ controllers/baserequest.py, line 6, in module from google.appengine.ext.webapp import template File /base/python_lib/versions/1/google/appengine/ext/webapp/ template.py, line 65, in module import django.template File /base/python_lib/versions/third_party/django-0.96/django/ template/__init__.py, line 918, in module add_to_builtins('django.template.defaultfilters') File /base/python_lib/versions/third_party/django-0.96/django/ template/__init__.py, line 915, in add_to_builtins builtins.append(get_library(module_name)) File /base/python_lib/versions/third_party/django-0.96/django/ template/__init__.py, line 904, in get_library mod = __import__(module_name, {}, {}, ['']) File /base/python_lib/versions/third_party/django-0.96/django/ template/defaultfilters.py, line 5, in module from django.utils.translation import gettext File /base/python_lib/versions/third_party/django-0.96/django/utils/ translation/__init__.py, line 1, in module from django.conf import settings File /base/python_dist/lib/python2.5/py_zipimport.py, line 105, in __init__ if not os.path.isfile(archive): File /base/python_dist/lib/python2.5/posixpath.py, line 208, in isfile st = os.stat(path) This is very frustrating and it would be nice if a Googler would at least explain what's going on. On Sep 12, 1:21 pm, Ernesto Ferro ernestofe...@gmail.com wrote: I have the same problem and I found a solution (at least it seems so) that works for me. If you are using django 1.02 or greater switch to 0.96. If it works for you please post about it. So far there's no errors in my logs and by now I should have many with the older version of my app. Regards On 11 sep, 18:37, Mike Wesner m...@konsole.net wrote: Any response from a googler on this? We are seeing this issue also. thanks! On Sep 11, 1:00 pm, Ernesto Ferro ernestofe...@gmail.com wrote: I'm having the same issue. I've made a REALLY simple site with django 1.02 (from app engine) trying to find the problem. The only thing that this app does is return an html with render_to_response. Nothing else ant yet it fail by deadline, imports or some disk i/o operations. Does google knows about this? Because it seems like the problem it's outside the users code. Regards --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: DataStore backup policies
Hello, Do we have any chance to get an integrated backup/restore tool in Google App Engine any time soon ? Is there a gaebar equivalent on java side ? Thanx for your help. François Bordeaux, FRANCE On 3 sep, 10:41, Nick Johnson (Google) nick.john...@google.com wrote: Hi Carlos, The short story is: We won't lose your data - we have a robust backup and recovery strategy - but we're not responsible for you losing your own data, so we suggest you keep your own backups so you can recover from bugs or mistakes in your code. -Nick Johnson On Mon, Aug 31, 2009 at 11:13 PM, Carlos Andres Echeverri Delgado caecheverr...@gmail.com wrote: Thank you for you response but it doesn't clear yet. If I use Google's Apps Engine service, what kind of guarantee Google offer me about my data? Exist some certified or something like that? Thanks 2009/8/31 Wooble geoffsp...@gmail.com You can probably trust Google's infrastructure to not lose your data; however, it's a good idea to make backups in case software problems in your own code cause data loss. On Aug 31, 2:46 pm, caecheverri caecheverr...@gmail.com wrote: Hi, I want to know what are the policies to make backup to data? Can I do it or it is done by Apps Engine administrator? How Apps Engine deal with data integrity and reliability?...I mean, if infraestructure crash, How is recovery the data? Thanks. -- Nick Johnson, Developer Programs Engineer, App Engine --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Problems adding developer to app
Hi there. A friend and myself are collaborating on a project. He sent a developer activation link to my gmail address, which I clicked on. Unfortunately the page that loaded said Unauthorized. You are not authorized to access this application. I've read through the body of the mail and it just says that I have to click the link, sign in and off we go. Suggestions? App name is sa-voice-drop-box. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] JPA mapping error
Hi all, I'm new to GAE, and i'm trying to migrate an application from tomcat/ hibernate/mysql to GAE/JPA. One of my problem rose at runtime when creating an EntityManager. Here the exception : javax.persistence.PersistenceException: Provider error. Provider: org.datanucleus.store.appengine.jpa.DatastorePersistenceProvider at javax.persistence.Persistence.createFactory(Persistence.java:176) at javax.persistence.Persistence.createEntityManagerFactory (Persistence.java:112) at javax.persistence.Persistence.createEntityManagerFactory (Persistence.java:66) at testjpa.server.JpaServlet.getEMF(JpaServlet.java:31) [...] Caused by: org.datanucleus.metadata.InvalidMetaDataException: Class testjpa.rpc.persist.AnBoardPosition has property hexDistance declared in MetaData, but its getter method doesnt exist in the class! at org.datanucleus.metadata.ClassMetaData.populateMemberMetaData (ClassMetaData.java:495) [...] No 'hexDistance' property are declared in 'AnBoardPosition' but there is a method 'public int getHexDistance(AnBoardPosition p_position)'. adding '@Transient' annontation don't change anything. I can change the method name to get rid of this error but: - Why gae make such a mistake (bug ?) as this method can't be a property ? - Why Transient annotation don't change anything to this behavior ? Other annotation ? - Is there any workaround as my app have a lot of transient method starting with getXxxx ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: SearchableModel
What do you mean by 'resources' ? The code is a good place to start: http://www.google.com/codesearch/p?hl=ensa=Ncd=1ct=rc#Qx8E-7HUBTk/trunk/google/appengine/ext/search/__init__.pyq=searchablemodel%20package:http://googleappengine%5C.googlecode%5C.com A websearch will find you other stuff too. On 15/09/2009, Randell Benavidez josephrandell.benavi...@gmail.com wrote: Hi guys, I can't seem to find good resources for SearchableModel. Could you point me to those resources, please? Thank you! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 'ReferenceProperty' query filtering?
I tested the filter you provided: query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) However it didn't work. I visited the doc you referenced, but the page does not mention anything about the style of query filters or any information on construction of queries with ReferenceProperty that I could find. Does the query filter you wrote work on your side? I broke our your query: PetOwner.all().filter('name =', 'johndoe') Which worked fine, however it was in placing it inside the query.filter that I get an error. Do you not get an error structured like this? On Sep 15, 4:36 am, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I think you are trying to filter the ReferenceProperty as a string, this won't work. You need to; query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) Doc on the Datastore ReferenceProperty; http://code.google.com/appengine/docs/python/datastore/entitiesandmod... Thanks, Arun Shanker Prasad. On Sep 15, 8:54 am, PatHaugen pathau...@gmail.com wrote: Jumping into GAE, I found the ReferenceProperty interesting but still don't fully understand it. My question can expand on the example from:http://code.google.com/appengine/docs/python/datastore/creatinggettin... class PetOwner(db.Model): name = db.StringProperty() class Pet(db.Model): name = db.StringProperty() type = db.StringProperty() # cat, dog, etc. owner = db.ReferenceProperty(PetOwner) Let's do a query to select all cats with a specific owner. query = db.Query(Pet) query = Pet.all() query.filter('type = ', 'Cat') results = query.fetch(limit=10) for result in results: output = result.name return output What can I add to this to filter only those where 'owner' is 'johndoe'? I tried: query.filter('owner = ', 'johndoe') However it fails to return me a result, and I know you can pull the owner name via 'pet.owner.name' however trying: query.filter('owner.name = ', 'johndoe') Also fails, though it made sense for what should work. Does anyone know the proper method? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Make number of task insertions per day a billable quota
I created a feature request for this: http://code.google.com/p/googleappengine/issues/detail?id=2126 Please vote if you would like to be able to submit more than 1 tasks per day. Benjamin On 15 Sep 2009, at 19:31, Benjamin Schuster-Böckler wrote: I use the task queue for some heavy lifting background updating. I create a single task for a URLfetch call and subsequent parsing, and storing, of data in a page. I would need a quota of ~2 per day, to keep a cycle of updating some 8 pages every 4 days. Are there any plans of extending this limitation, or making it a billable quota? The task queue is tremendously useful, but a hard limit for number of tasks per day defeats the purpose a little... Best, Benjamin -- Benjamin Schuster-Böckler Pear Computer LLP 86 Cavendish Road Cambridge CB1 3AF United Kingdom Company No. OC340192 VAT No. 971 3948 85 -- Benjamin Schuster-Böckler Pear Computer LLP 86 Cavendish Road Cambridge CB1 3AF United Kingdom Company No. OC340192 VAT No. 971 3948 85 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Make number of task insertions per day a billable quota
Hi Benjamin, We recently increased the task limit from 10,000 a day to 100,000 a day for billed apps. You can enable billing for your app, and it will get the increased quotas even if you don't ever exceed the free quotas. Please bear in mind that the task queue is still in labs; the limits today are unlikely to be representative of the limits once the task queue is out of labs. We don't currently intend to make tasks a billed quota, as tasks are already billed for the other billed resources they consume such as CPU seconds - the Task Queue quota falls into the same category as the other non-billed quotas you see on the Quota Details page. -Nick Johnson On Tue, Sep 15, 2009 at 6:31 PM, Benjamin Schuster-Böckler b...@pearcomp.com wrote: I use the task queue for some heavy lifting background updating. I create a single task for a URLfetch call and subsequent parsing, and storing, of data in a page. I would need a quota of ~2 per day, to keep a cycle of updating some 8 pages every 4 days. Are there any plans of extending this limitation, or making it a billable quota? The task queue is tremendously useful, but a hard limit for number of tasks per day defeats the purpose a little... Best, Benjamin -- Benjamin Schuster-Böckler Pear Computer LLP 86 Cavendish Road Cambridge CB1 3AF United Kingdom Company No. OC340192 VAT No. 971 3948 85 -- Nick Johnson, Developer Programs Engineer, App Engine --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 'ReferenceProperty' query filtering?
Hi, I am sorry I replied to the thread when I was not at my dev machine, did not test the code. I am not sure if putting the query inside the query.filter() will break it. owner = PetOwner.all().filter('name =', 'johndoe'),get() query.filter('owner = ', owner) This should work. Thanks, Arun Shanker Prasad. On Wed, Sep 16, 2009 at 12:50 AM, PatHaugen pathau...@gmail.com wrote: I tested the filter you provided: query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) However it didn't work. I visited the doc you referenced, but the page does not mention anything about the style of query filters or any information on construction of queries with ReferenceProperty that I could find. Does the query filter you wrote work on your side? I broke our your query: PetOwner.all().filter('name =', 'johndoe') Which worked fine, however it was in placing it inside the query.filter that I get an error. Do you not get an error structured like this? On Sep 15, 4:36 am, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I think you are trying to filter the ReferenceProperty as a string, this won't work. You need to; query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) Doc on the Datastore ReferenceProperty; http://code.google.com/appengine/docs/python/datastore/entitiesandmod... Thanks, Arun Shanker Prasad. On Sep 15, 8:54 am, PatHaugen pathau...@gmail.com wrote: Jumping into GAE, I found the ReferenceProperty interesting but still don't fully understand it. My question can expand on the example from: http://code.google.com/appengine/docs/python/datastore/creatinggettin... class PetOwner(db.Model): name = db.StringProperty() class Pet(db.Model): name = db.StringProperty() type = db.StringProperty() # cat, dog, etc. owner = db.ReferenceProperty(PetOwner) Let's do a query to select all cats with a specific owner. query = db.Query(Pet) query = Pet.all() query.filter('type = ', 'Cat') results = query.fetch(limit=10) for result in results: output = result.name return output What can I add to this to filter only those where 'owner' is 'johndoe'? I tried: query.filter('owner = ', 'johndoe') However it fails to return me a result, and I know you can pull the owner name via 'pet.owner.name' however trying: query.filter('owner.name = ', 'johndoe') Also fails, though it made sense for what should work. Does anyone know the proper method? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 'ReferenceProperty' query filtering?
Hi, I am sorry I replied to the thread when I was not at my dev machine, did not test the code. I am not sure if putting the query inside the query.filter() will break it. owner = PetOwner.all().filter('name =', 'johndoe'),get() query.filter('owner = ', owner) This should work. Thanks, Arun Shanker Prasad. On Sep 16, 12:20 am, PatHaugen pathau...@gmail.com wrote: I tested the filter you provided: query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) However it didn't work. I visited the doc you referenced, but the page does not mention anything about the style of query filters or any information on construction of queries with ReferenceProperty that I could find. Does the query filter you wrote work on your side? I broke our your query: PetOwner.all().filter('name =', 'johndoe') Which worked fine, however it was in placing it inside the query.filter that I get an error. Do you not get an error structured like this? On Sep 15, 4:36 am, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I think you are trying to filter the ReferenceProperty as a string, this won't work. You need to; query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) Doc on the Datastore ReferenceProperty; http://code.google.com/appengine/docs/python/datastore/entitiesandmod... Thanks, Arun Shanker Prasad. On Sep 15, 8:54 am, PatHaugen pathau...@gmail.com wrote: Jumping into GAE, I found the ReferenceProperty interesting but still don't fully understand it. My question can expand on the example from:http://code.google.com/appengine/docs/python/datastore/creatinggettin... class PetOwner(db.Model): name = db.StringProperty() class Pet(db.Model): name = db.StringProperty() type = db.StringProperty() # cat, dog, etc. owner = db.ReferenceProperty(PetOwner) Let's do a query to select all cats with a specific owner. query = db.Query(Pet) query = Pet.all() query.filter('type = ', 'Cat') results = query.fetch(limit=10) for result in results: output = result.name return output What can I add to this to filter only those where 'owner' is 'johndoe'? I tried: query.filter('owner = ', 'johndoe') However it fails to return me a result, and I know you can pull the owner name via 'pet.owner.name' however trying: query.filter('owner.name = ', 'johndoe') Also fails, though it made sense for what should work. Does anyone know the proper method? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Reaching 10 apps. Can someone at Google please help.
On Tue, 2009-09-15 at 15:53 +0100, Nick Johnson (Google) wrote: Hi observer, I've increased the number of apps you can create to 20. -Nick Johnson Thanks Google. Duong BaTien DBGROUPS and BudhNet On Mon, Sep 14, 2009 at 7:56 PM, observer247 prem...@gmail.com wrote: I like the app engine platform and have spent quite a lot of time to learn python and now I use app engine for most of the things I need to do on the web. I have already reached 9 apps and I have around 5 apps ready to be deployed. Can someone please increase the number of apps to 20. I have a billable account and I would like to work the legitimate way instead of trying to use others account etc. Thanks and will really appreciate this ! -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Reaching 10 apps. Can someone at Google please help.
Awesome ! Thanks. On Sep 15, 7:53 am, Nick Johnson (Google) nick.john...@google.com wrote: Hi observer, I've increased the number of apps you can create to 20. -Nick Johnson On Mon, Sep 14, 2009 at 7:56 PM, observer247 prem...@gmail.com wrote: I like the app engine platform and have spent quite a lot of time to learn python and now I use app engine for most of the things I need to do on the web. I have already reached 9 apps and I have around 5 apps ready to be deployed. Can someone please increase the number of apps to 20. I have a billable account and I would like to work the legitimate way instead of trying to use others account etc. Thanks and will really appreciate this ! -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] GAE, App Engine Patch, CRON (301) Issues
Hello, I'm wondering if anyone is having similar issues with GAE cron jobs / tasks via App Engine Patch? Intended Flow: 1. Cron job 'do/store/weekly' triggers the creation of a task to build html email. 2. Task executes, builds html email, and stores it in a DB email queue. 3. Some time after (e.g. +10 min) the 'do/store/weekly' job, another cron triggers the weekly collection of subscribers (email addresses, unsub token) -- How things get broken down at this point is TBD depending on timeout, cpu usage etc.-- 4+. Tasks executes the creation of 1 send email task per subscriber (collection of email, html etc), theses tasks in queue execute asap. Issues: 1. do/store/weekly' is always returning 301. In the response I've tried (lines 24-27) all result in 301 status. Cron returns 200 when user-initiated (hitting the url directly via browser). 2. Intermittent cpu_ms api_cpu_ms warnings. e.g. Sometimes '/do/ store/weekly' will run without warnings other times it will report: / do/store/weekly 301 1287ms 1613cpu_ms 0kb where both (1287 1613) are in red and with warning icons. GAE's cron jobs don't have auto- cancel conditions do they? 3. Cron consistently reporting on-time Failed. Code: http://dpaste.com/hold/94080/ Any insight would be very appreciated as my searches have come up short. I suspect (read: hope) my other issues are due largely in part to the 301 status, but maybe I've skewed something else up too. Thanks kindly, -ttk --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 'ReferenceProperty' query filtering?
Thanks for the response, works nice, however coming from PHP/MySQL this seems strange to me. We have two 'tables' and are trying to perform a query to link them, however this solution causes two queries on the 'database' to be performed, which are logged against you for your quotas. I'm used to joins: http://dev.mysql.com/doc/refman/5.0/en/join.html One query linking two or more tables for the data you need. Is Google App Engine's 'query' function not able to do anything like this? Is GQL better than GAE's 'Query'? On Sep 15, 12:41 pm, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I am sorry I replied to the thread when I was not at my dev machine, did not test the code. I am not sure if putting the query inside the query.filter() will break it. owner = PetOwner.all().filter('name =', 'johndoe'),get() query.filter('owner = ', owner) This should work. Thanks, Arun Shanker Prasad. On Sep 16, 12:20 am, PatHaugen pathau...@gmail.com wrote: I tested the filter you provided: query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) However it didn't work. I visited the doc you referenced, but the page does not mention anything about the style of query filters or any information on construction of queries with ReferenceProperty that I could find. Does the query filter you wrote work on your side? I broke our your query: PetOwner.all().filter('name =', 'johndoe') Which worked fine, however it was in placing it inside the query.filter that I get an error. Do you not get an error structured like this? On Sep 15, 4:36 am, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I think you are trying to filter the ReferenceProperty as a string, this won't work. You need to; query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) Doc on the Datastore ReferenceProperty; http://code.google.com/appengine/docs/python/datastore/entitiesandmod... Thanks, Arun Shanker Prasad. On Sep 15, 8:54 am, PatHaugen pathau...@gmail.com wrote: Jumping into GAE, I found the ReferenceProperty interesting but still don't fully understand it. My question can expand on the example from:http://code.google.com/appengine/docs/python/datastore/creatinggettin... class PetOwner(db.Model): name = db.StringProperty() class Pet(db.Model): name = db.StringProperty() type = db.StringProperty() # cat, dog, etc. owner = db.ReferenceProperty(PetOwner) Let's do a query to select all cats with a specific owner. query = db.Query(Pet) query = Pet.all() query.filter('type = ', 'Cat') results = query.fetch(limit=10) for result in results: output = result.name return output What can I add to this to filter only those where 'owner' is 'johndoe'? I tried: query.filter('owner = ', 'johndoe') However it fails to return me a result, and I know you can pull the owner name via 'pet.owner.name' however trying: query.filter('owner.name = ', 'johndoe') Also fails, though it made sense for what should work. Does anyone know the proper method? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Open Letter to Ryan Barrett and the AppEngine Team regarding high availability
hi peter! On Sep 15, 3:01 am, gae123 pa...@gae123.com wrote: Unfortunately, the reality I see and face in the ground for the past 16 months is different. As I am writing this, I have 2 GAE powered sites down for TWO DAYS[1] and I am still waiting. The root cause? Simple index count quotas reseting issues that Google can solve on thanks for the feedback, and apologies for the trouble. you're right, that particular quota has been troublesome for a long time, and when people have hit it, the only recourse has been to post to the group and wait for someone here to fix it manually. we've definitely been aware of this for a while, and we've known the status quo wasn't good enough. happily, your timing is good, since we managed to prioritize this just a couple weeks ago. in 1.2.6, the index count quota will be handled much better, both in real time and behind the scenes so that if it does skew, it will automatically be fixed. we follow a fairly agile process internally, so we don't usually schedule release dates ahead of time, but based on our track record so far - http://code.google.com/p/googleappengine/wiki/SdkReleaseNotes - we've put out releases roughly once a month, and 1.2.6 will probably follow that pattern. i also feel your pain in the support department. we wish we had the resources to provide more high-touch support! we're not a large team, though, so we have to ruthlessly prioritize. that often means less individual support, and it can also means prioritizing necessary but invisible internal changes over developer-visible features and bug fixes. personally, i favor the approach joel spolsky describes in http://www.joelonsoftware.com/articles/customerservice.html . naturally, when a developer hits a problem, we should try to fix it for them immediately if we have the resources. more importantly, though, we should try to change app engine so that problem doesn't happen at all. there are lots of possible app engine improvements like this, so some of them - like the index count quota - don't get fixed right away. we definitely try to keep track of them all, though, and get to them all eventually. (of course, as you mention, we can always improve the ways we communicate so that you know we're aware of a problem and do plan to work on it eventually.) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Datastore query
Hi guys, I just started learning app engine by developing a small application. I am facing following problem: 1) I have following model class Contact(db.Model): name = db.StringProperty() type = db.StringProperty() class PhoneNumber(db.Model): contact = db.ReferenceProperty(Contact, collection_name='phone_numbers') phone_type = db.StringProperty() number = db.PhoneNumberProperty() 2) I need to fetch all contacts that are type 'A' and those contacts should only contain phone numbers that have phone_type 'B' or 'C' 3) I have no idea how to solve this :) (One solution would be fetch contacts and filter out wrong phone_types at application level, but I think that is not best way to solve this) Thanks in advance, Tomi --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Upgrade from 1.2.4 to 1.2.5 fails on windows XP
I had the same problem (error code 2908). Thanks to Dmitriy and Perica for their helpful posts. First I uninstalled the old app engine from the windows control panel. Then I deleted the following key using regedit: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\ Installer\UserData\S-1-5-21-1123561945-1935655697-1060284298-1003\ Components\AD95649F068525549B26938D7D18FEA7 On Sep 12, 7:01 am, Perica Zivkovic perica.zivko...@gmail.com wrote: Hi there thanks to Dmitriy I fixed the problem. When you check add/remove programs everything was uninstalled but under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\ Installer\UserData\ there was an entry full with properties needed for google app engine. Removing it with regedit helped. Installation of 1.2.5 is working now :D kind regards and thanks to Dmitriy Perica On Sep 6, 6:06 pm, Dmitriy dmitriy.antone...@gmail.com wrote: Hi! try this solution:http://www.add-in-express.com/creating-addins-blog/2007/11/12/windows... I had the same problem. Deleting that key helps to solve 2908 problem. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Load Django Template from database
I tried your example a few different ways, still get an error: AttributeError: 'str' object has no attribute 'render' bar = # pulled template from DB self.response.out.write(bar.render(template.Context(template_values))) Tried again using what you did on 'bar' before: foo = # pulled template from DB bar = template.Template(foo) self.response.out.write(bar.render(template.Context(template_values))) Not sure if 'template.Template()' takes a str and makes it into a 'template' able to be rendered, does this code work on your side? I even tried scrapping the way I pull the template and using your method: foo = db.get(templatekey).templatetext Before that, I had to do another DB query to pull the key value of the template I wanted, regardless it still failed... On Sep 15, 11:09 am, Wooble geoffsp...@gmail.com wrote: On Sep 15, 2:08 pm, Wooble geoffsp...@gmail.com wrote: self.response.out.write(bar.render(template_values)) correction: you'll need to wrap template_values in template.Context(); template.render() does this for you automagically. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Load Django Template from database
I've thought of doing this too but it doesn't look easy. You'll need to dig deep into django in order to extract out the part that recursively loads template objects (as templates may extend from other templates recursively). Look in your google app engine install directory ... google/appengine/ ext/webapp/template.py for the code that is currently bootstrapping django and loading up your templates in the proper file path context. Stephen On Sep 15, 6:26 pm, PatHaugen pathau...@gmail.com wrote: I tried your example a few different ways, still get an error: AttributeError: 'str' object has no attribute 'render' bar = # pulled template from DB self.response.out.write(bar.render(template.Context(template_values))) Tried again using what you did on 'bar' before: foo = # pulled template from DB bar = template.Template(foo) self.response.out.write(bar.render(template.Context(template_values))) Not sure if 'template.Template()' takes a str and makes it into a 'template' able to be rendered, does this code work on your side? I even tried scrapping the way I pull the template and using your method: foo = db.get(templatekey).templatetext Before that, I had to do another DB query to pull the key value of the template I wanted, regardless it still failed... On Sep 15, 11:09 am, Wooble geoffsp...@gmail.com wrote: On Sep 15, 2:08 pm, Wooble geoffsp...@gmail.com wrote: self.response.out.write(bar.render(template_values)) correction: you'll need to wrap template_values in template.Context(); template.render() does this for you automagically. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Open Letter to Ryan Barrett and the AppEngine Team regarding high availability
On Sep 16, 12:04 am, ryan ryanb+appeng...@google.com wrote: (of course, as you mention, we can always improve the ways we communicate so that you know we're aware of a problem and do plan to work on it eventually.) How will you do this? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Can you switch billing to monthly instead of daily
It's a bit annoying to get daily billing emails and having 30 tiny charges on my credit card bill every month instead of one. In addition to being annoying, it complicates the accounting. I think every other hosting company charges on a monthly basis. Any chance App Engine could start using the traditional billing model? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Efficiency Conundrum
My application is comprised of semicolon delimited phrases or sentence fragments. When a user enters these phrases into a form textarea I split the contents into a list and then check to see if each phrase already exists as an entity in the datastore. This process is killing me on cpu cycles, but I'm not sure there's any alternative. Has anyone discovered techniques for efficiently searching through entity properties? I've thought about using a listproperty, but I'm not sure this will work. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Run your Lucene Applications on Google AppEngine with GAELucene
Hi Johnson, Here, http://so.3gmatrix.cn/news/search?q=3G, is an app built with GAELucene. The index size of 'news' is about 96Mb, docs number is 22651. The index was splitted into about 200 segments(GAEFileContent) when GAEFile.SEGMENT_LENGTH was set to 512000(bytes). You can check the indices use http://so.3gmatrix.cn/gaelucenedashboard/list On Sep 15, 11:09 pm, Nick Johnson (Google) nick.john...@google.com wrote: Hi lhelper, Interesting project! Have you tested it with a large corpus of text to search? -Nick Johnson On Mon, Sep 14, 2009 at 5:23 PM, lhelper lhel...@gmail.com wrote: Enlightened by the discussion Can I run Lucene in google app engine? [http://www.nabble.com/Can-I-run-Lucene-in-google-app-engine-- td23017742.html], I implemented a google datastore based Lucene component, GAELucene, which can help you to run search applications on google app engine. The main clazz of GAELucene include: * GAEDirectory - a read only Directory based on google datastore. * GAEFile - stands for an index file, the file's byte content will be splited into multi GAEFileContent. * GAEFileContent - stands for a segment of index file. * GAECategory - the identifier of different indices. * GAEIndexInput - a memory-resident IndexInput? implementation like the RAMInputStream. * GAEIndexReader - wrapper for IndexReader? that cached in GAEIndexReaderPool * GAEIndexReaderPool - pool for GAEIndexReader The following code snippet demonstrates the use of GAELucene do searching: Query queryObject = parserQuery(request); GAEIndexReaderPool readerPool =GAEIndexReaderPool.getInstance(); GAEIndexReader indexReader = readerPool.borrowReader (INDEX_CATEGORY_DEMO); IndexSearcher searcher =newIndexSearcher(indexReader); Hits hits = searcher.search(queryObject); readerPool.returnReader(indexReader); You can find more here 'http://code.google.com/p/gaelucene' -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: Efficiency Conundrum
as a follow up to this - would it be possible to use the phrases I describe below as entity keys so that I could just use the getbykey method rather than querying for each phrase to see if it exists in the Datastore? If so, does anyone know the limitations on keys - how long can they be and can they contain special characters like ) etc...? On Sep 16, 1:03 am, Larkin2 michael.mer...@gmail.com wrote: My application is comprised of semicolon delimited phrases or sentence fragments. When a user enters these phrases into a form textarea I split the contents into a list and then check to see if each phrase already exists as an entity in the datastore. This process is killing me on cpu cycles, but I'm not sure there's any alternative. Has anyone discovered techniques for efficiently searching through entity properties? I've thought about using a listproperty, but I'm not sure this will work. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---
[google-appengine] Re: 'ReferenceProperty' query filtering?
Hi, I am almost certain that there is no way to perform a JOIN in GQL :( The another way you can try is to use the Entity Groups; http://code.google.com/appengine/docs/python/datastore/keysandentitygroups.html#Entity_Groups_Ancestors_and_Paths This seems to be faster that two hits to the DB. The 'query' function work similar to the GQL query. Thanks, Arun Shanker Prasad. On Wed, Sep 16, 2009 at 3:47 AM, PatHaugen pathau...@gmail.com wrote: Thanks for the response, works nice, however coming from PHP/MySQL this seems strange to me. We have two 'tables' and are trying to perform a query to link them, however this solution causes two queries on the 'database' to be performed, which are logged against you for your quotas. I'm used to joins: http://dev.mysql.com/doc/refman/5.0/en/join.html One query linking two or more tables for the data you need. Is Google App Engine's 'query' function not able to do anything like this? Is GQL better than GAE's 'Query'? On Sep 15, 12:41 pm, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I am sorry I replied to the thread when I was not at my dev machine, did not test the code. I am not sure if putting the query inside the query.filter() will break it. owner = PetOwner.all().filter('name =', 'johndoe'),get() query.filter('owner = ', owner) This should work. Thanks, Arun Shanker Prasad. On Sep 16, 12:20 am, PatHaugen pathau...@gmail.com wrote: I tested the filter you provided: query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) However it didn't work. I visited the doc you referenced, but the page does not mention anything about the style of query filters or any information on construction of queries with ReferenceProperty that I could find. Does the query filter you wrote work on your side? I broke our your query: PetOwner.all().filter('name =', 'johndoe') Which worked fine, however it was in placing it inside the query.filter that I get an error. Do you not get an error structured like this? On Sep 15, 4:36 am, Arun Shanker Prasad arunshankerpra...@gmail.com wrote: Hi, I think you are trying to filter the ReferenceProperty as a string, this won't work. You need to; query.filter('owner = ', PetOwner.all().filter('name =', 'johndoe')) Doc on the Datastore ReferenceProperty; http://code.google.com/appengine/docs/python/datastore/entitiesandmod... Thanks, Arun Shanker Prasad. On Sep 15, 8:54 am, PatHaugen pathau...@gmail.com wrote: Jumping into GAE, I found the ReferenceProperty interesting but still don't fully understand it. My question can expand on the example from: http://code.google.com/appengine/docs/python/datastore/creatinggettin... class PetOwner(db.Model): name = db.StringProperty() class Pet(db.Model): name = db.StringProperty() type = db.StringProperty() # cat, dog, etc. owner = db.ReferenceProperty(PetOwner) Let's do a query to select all cats with a specific owner. query = db.Query(Pet) query = Pet.all() query.filter('type = ', 'Cat') results = query.fetch(limit=10) for result in results: output = result.name return output What can I add to this to filter only those where 'owner' is 'johndoe'? I tried: query.filter('owner = ', 'johndoe') However it fails to return me a result, and I know you can pull the owner name via 'pet.owner.name' however trying: query.filter('owner.name = ', 'johndoe') Also fails, though it made sense for what should work. Does anyone know the proper method? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~--~~~~--~~--~--~---