Re: [appengine-java] Initialize local datastore exception
»»» EXCEPTION ««« Exception in thread main java.lang.NullPointerException: No API environment is registered for this thread. This generally means you haven't set things up properly. Follow the directions: http://code.google.com/appengine/docs/java/tools/localunittesting.html Wayne -- 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-j...@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: Best way to perform search on DataStore - Design Question
Hello, I am wondering if text search is actually on the official road map and if so when it will be available. If not, would it make sense to start a google code project to do our own implementation? I am thinking of something simple and light without the need of lots of jar. I think it is quite some work and it would be worthless if GAE will have this feature in the near future. Also I guess it can be implemented more efficiently on google side reusing all the infrastructure that they have already in place. Cheers, Toby On Mar 29, 6:32 am, Tristan tristan.slomin...@gmail.com wrote: another way is to implement a full-textsearchyourself... implementing this would work: http://www.miislita.com/term-vector/term-vector-3.html (use tri-grams instead of full words as tokens) i would recommend low-level datastore api for that, also, your index term entities will blow up beyond 1MB, i built mindash-datastore to handle that :) or you can wait for a few months for Google On Mar 25, 3:05 pm, niraj njun...@gmail.com wrote: I am debating if I should use Compass or wait for Google to release something. I can wait for 3-4 months as my website is going to take that amount of time to complete. Niraj On Mar 16, 3:16 am, Toby toby.ro...@gmail.com wrote: I am using compass as well and it works fine. The indexing part is costly and you might need to do task queue if you reindex large amount of data. Starting thesearchmanager is slow and it happens a lot due to the suspend policy. You can also take a look at this project:http://code.google.com/p/gaelucene/ I hope there will be a native solution by GAE one day (is there an issue to vote for?) On Mar 16, 10:21 am, yjun hu itswa...@gmail.com wrote: haha, up to now,i use compass okay! On Tue, Mar 16, 2010 at 8:53 AM, objectuser kevin.k.le...@gmail.com wrote: I think there are a lot of posts here that conclude Compass is not viable. Has that changed? On Mar 15, 12:23 am, yjun hu itswa...@gmail.com wrote: you can try compass to make you project searchable. a simple demo herehttp://hapeblog.appspot.com/blog.shtml?id=7002 On Sun, Mar 14, 2010 at 8:36 PM, John Patterson jdpatter...@gmail.com wrote: Interesting to see the existence protected Query.setFullTextSearch(String) method when you open the Query class in Eclipse. I suppose it won't be too far away. I can't wait to see if they just give us a take-it-or-leave-it solution or also the tools required to roll your own. On 14 Mar 2010, at 15:05, Robert Lancer wrote: Haha, like many of us you probably thought that GOOGLE app engine would have decenttextsearchcapabilities. It looks like your doing all you can do by creating the inverse table, you may just want to star http://code.google.com/p/googleappengine/issues/detail?id=217 On Mar 13, 8:59 pm, niraj njun...@gmail.com wrote: My case: I am building a website that has several searchable fields from various entities (example Artist names from artist entity , Album names from album entity). To have an efficientsearchcapability I have defined another Entity - SearchType which carries the Searchable string and the Foreign key to the Entity. Instead of querying all the Entities one my one - I query SearchType. My preliminary tests indicate that the query performance on SearchType is not great (the names are indexed) . I need google suggest like quick results in a drop down. What is the best way to design this. I have considered Memcache , but I dont think I can run queries on Memcache . i.e I am running a startsWith() query on JDO today. Any best practices . -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2B unsubscr...@googlegroups.com google-appengine-java%2bunsubscr...@googlegroups.comgoogle-appengine-java %252bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2B unsubscr...@googlegroups.com
Re: [appengine-java] Re: Best way to perform search on DataStore - Design Question
Yes full text search is on the road map. It can't be far away because some of the implementation has already slipped into the current release. See the protected method Query.setFullTextSearch() On 6 Apr 2010, at 16:04, Toby wrote: Hello, I am wondering if text search is actually on the official road map and if so when it will be available. If not, would it make sense to start a google code project to do our own implementation? I am thinking of something simple and light without the need of lots of jar. I think it is quite some work and it would be worthless if GAE will have this feature in the near future. Also I guess it can be implemented more efficiently on google side reusing all the infrastructure that they have already in place. Cheers, Toby On Mar 29, 6:32 am, Tristan tristan.slomin...@gmail.com wrote: another way is to implement a full-textsearchyourself... implementing this would work: http://www.miislita.com/term-vector/term-vector-3.html (use tri-grams instead of full words as tokens) i would recommend low-level datastore api for that, also, your index term entities will blow up beyond 1MB, i built mindash-datastore to handle that :) or you can wait for a few months for Google On Mar 25, 3:05 pm, niraj njun...@gmail.com wrote: I am debating if I should use Compass or wait for Google to release something. I can wait for 3-4 months as my website is going to take that amount of time to complete. Niraj On Mar 16, 3:16 am, Toby toby.ro...@gmail.com wrote: I am using compass as well and it works fine. The indexing part is costly and you might need to do task queue if you reindex large amount of data. Starting thesearchmanager is slow and it happens a lot due to the suspend policy. You can also take a look at this project:http://code.google.com/p/gaelucene/ I hope there will be a native solution by GAE one day (is there an issue to vote for?) On Mar 16, 10:21 am, yjun hu itswa...@gmail.com wrote: haha, up to now,i use compass okay! On Tue, Mar 16, 2010 at 8:53 AM, objectuser kevin.k.le...@gmail.com wrote: I think there are a lot of posts here that conclude Compass is not viable. Has that changed? On Mar 15, 12:23 am, yjun hu itswa...@gmail.com wrote: you can try compass to make you project searchable. a simple demo herehttp://hapeblog.appspot.com/blog.shtml?id=7002 On Sun, Mar 14, 2010 at 8:36 PM, John Patterson jdpatter...@gmail.com wrote: Interesting to see the existence protected Query.setFullTextSearch(String) method when you open the Query class in Eclipse. I suppose it won't be too far away. I can't wait to see if they just give us a take-it-or-leave-it solution or also the tools required to roll your own. On 14 Mar 2010, at 15:05, Robert Lancer wrote: Haha, like many of us you probably thought that GOOGLE app engine would have decenttextsearchcapabilities. It looks like your doing all you can do by creating the inverse table, you may just want to star http://code.google.com/p/googleappengine/issues/detail?id=217 On Mar 13, 8:59 pm, niraj njun...@gmail.com wrote: My case: I am building a website that has several searchable fields from various entities (example Artist names from artist entity , Album names from album entity). To have an efficientsearchcapability I have defined another Entity - SearchType which carries the Searchable string and the Foreign key to the Entity. Instead of querying all the Entities one my one - I query SearchType. My preliminary tests indicate that the query performance on SearchType is not great (the names are indexed) . I need google suggest like quick results in a drop down. What is the best way to design this. I have considered Memcache , but I dont think I can run queries on Memcache . i.e I am running a startsWith() query on JDO today. Any best practices . -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle- appengine-java%2B unsubscr...@googlegroups.com google-appengine-java%2bunsubscr...@googlegroups.comgoogle- appengine-java %252bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle- appengine-java%2B unsubscr...@googlegroups.com google-appengine-java%2bunsubscr...@googlegroups.comgoogle- appengine-java %252bunsubscr...@googlegroups.com . For more options, visit this group at
[appengine-java] Re: JAXB Support
I've been working with the tutorial mentioned above and it runs fine in my local environment, but when I deploy to GAE JAXB is throwing the exception detailed above. I'm baffled as to why this is running locally but failing on GAE. I though the local environment was supposed to replicate the actual GAE production environment? Does anyone have any ideas? I'm really stuck with this one... On 2 Apr, 17:37, L. Kirven lrkir...@gmail.com wrote: Brian, I am doing exactly the same thing. I followed the blog below and didn't have any problems. I hope that this helps. http://tugdualgrall.blogspot.com/2010/02/create-and-deploy-jax-rs-res... On Fri, Apr 2, 2010 at 9:55 AM, Brian hannawaybr...@googlemail.com wrote: Hi, I've run into an issue with JAXB on GAE. I have set up a simple project using Jersey to expose a RESTful web service and am using JAXB for marshalling/unmarshalling. The project runs fine in my local eclipse environment but when I upload to GAE and send a request to the web service I am getting a JAXB exception (see stack trace below). I am using the latest version of JAXB and the latest version of GAE SDK. According to the white list JAXB should now be supported so I'm not sure what's going on. Any help to resolve this issue would be greatly appreciated. Uncaught exception from servlet java.lang.ExceptionInInitializerError at com.sun.xml.bind.v2.runtime.reflect.opt.AccessorInjector.prepare(AccessorIn jector.java: 79) at com.sun.xml.bind.v2.runtime.reflect.opt.OptimizedAccessorFactory.get(Optimi zedAccessorFactory.java: 165) at com.sun.xml.bind.v2.runtime.reflect.Accessor $FieldReflection.optimize(Accessor.java:256) at com.sun.xml.bind.v2.runtime.property.ArrayProperty.init(ArrayProperty.jav a: 65) at com.sun.xml.bind.v2.runtime.property.ArrayERProperty.init(ArrayERProperty .java: 84) at com.sun.xml.bind.v2.runtime.property.ArrayElementProperty.init(ArrayEleme ntProperty.java: 96) at com.sun.xml.bind.v2.runtime.property.ArrayElementNodeProperty.init(ArrayE lementNodeProperty.java: 58) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Constructor.java:33) at com.sun.xml.bind.v2.runtime.property.PropertyFactory.create(PropertyFactory .java: 124) at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.init(ClassBeanInfoImpl.java : 179) at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(JAXBContextImpl.jav a: 515) at com.sun.xml.bind.v2.runtime.JAXBContextImpl.init(JAXBContextImpl.java: 330) at com.sun.xml.bind.v2.runtime.JAXBContextImpl $JAXBContextBuilder.build(JAXBContextImpl.java:1140) at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java: 154) at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java: 121) at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java: 202) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:159) at javax.xml.bind.ContextFinder.find(ContextFinder.java:311) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at com.sun.jersey.server.impl.wadl.WadlApplicationContextImpl.init(WadlAppli cationContextImpl.java: 66) at com.sun.jersey.server.impl.wadl.WadlFactory.init(WadlFactory.java: 94) at com.sun.jersey.server.impl.application.WebApplicationImpl.initWadl(WebAppli cationImpl.java: 1207) at com.sun.jersey.server.impl.application.WebApplicationImpl.processRootResour ces(WebApplicationImpl.java: 1106) at com.sun.jersey.server.impl.application.WebApplicationImpl.initiate(WebAppli cationImpl.java: 912) at com.sun.jersey.server.impl.application.WebApplicationImpl.initiate(WebAppli cationImpl.java: 589) at com.sun.jersey.spi.container.servlet.ServletContainer.initiate(ServletConta iner.java: 403) at com.sun.jersey.spi.container.servlet.ServletContainer $InternalWebComponent.initiate(ServletContainer.java:252) at com.sun.jersey.spi.container.servlet.WebComponent.load(WebComponent.java: 550) at
[appengine-java] Issue with google plugin for eclipse
The plugin doesn't allow me to create a new Servlet, when calling the create servlet wizard the project field appears greyed and empty. I can create a class, or any file, but of course, much more things to write are needed. just curious to know if it's a normal behaviour or some bug? I'm using Ubuntu karmic and eclipse ganimedes for java EE, with latests google plugin and sdks (just made a fresh install 3 days ago.) thx -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@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 can I place JSession into cookie. Google app engine.
Сould you please tell me how to place the session identifier into the cookie, if you are working with google app engine. 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-j...@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] Eclipse
eclipse.buildId=unknown java.version=1.6.0_18 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=zh_CN Command-line arguments: -os win32 -ws win32 -arch x86 Error Tue Apr 06 14:38:47 CST 2010 Unable to update app: Failed to compile the generated JSP java files. See the deployment console for more details com.google.appengine.tools.admin.AdminException: Unable to update app: Failed to compile the generated JSP java files. at com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java: 62) at com.google.appengine.eclipse.core.proxy.AppEngineBridgeImpl.deploy(AppEngineBridgeImpl.java: 271) at com.google.appengine.eclipse.core.deploy.DeployProjectJob.runInWorkspace(DeployProjectJob.java: 145) at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java: 38) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55) Caused by: com.google.appengine.tools.admin.JspCompilationException: Failed to compile the generated JSP java files. at com.google.appengine.tools.admin.Application.compileJavaFiles(Application.java: 432) at com.google.appengine.tools.admin.Application.compileJsps(Application.java: 392) at com.google.appengine.tools.admin.Application.createStagingDirectory(Application.java: 268) at com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java: 54) ... 4 more why? web.xml Source Code? -- 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-j...@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] Adding Task-Queue Tasks in Batch?
Aloha, The docs for the Java implementation of the Task Queue mentions this: maximum number of tasks that can be added in a batch - 100 However, I can't find any reference to adding tasks in a batch. What does the above mean, and where can I find more information about it? I'd like to be able to add many tasks in a batch, if that's possible. I am aware of the 5 tasks per transaction limit. Thanks! Seth -- 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-j...@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: Adding Task-Queue Tasks in Batch?
From http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/labs/taskqueue/Queue.html add(java.lang.IterableTaskOptions taskOptions) Submits tasks to this queue. On Apr 6, 9:54 am, Seth Ladd sethl...@gmail.com wrote: Aloha, The docs for the Java implementation of the Task Queue mentions this: maximum number of tasks that can be added in a batch - 100 However, I can't find any reference to adding tasks in a batch. What does the above mean, and where can I find more information about it? I'd like to be able to add many tasks in a batch, if that's possible. I am aware of the 5 tasks per transaction limit. Thanks! Seth -- 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-j...@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] Funny behavior with memcache.increment() below zero
Hi all, I am trying to use memcache.increment to move to negative values, starting at 0. According to the javadoc[1]: To facilitate use as an atomic countdown, incrementing by a negative value (i.e. decrementing) will not go below zero: incrementing 2 by -5 will return 0, not -3. However, due to the way numbers are stored, decrementing -3 by -5 will result in -8; so the zero-floor rule only applies to decrementing numbers that were positive. What is the rationale behind this, and why is 0 considered positive? I may have missed something, but I did not understand a similar behavior in python's memcache.decr() docs. If my counter can hold positive or negative values, what options do I have apart from initializing at 2^30? -- Nacho [1] http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/memcache/MemcacheService.html#increment(java.lang.Object,%20long) -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] JDO Relationship Performance Problems - what am I doing wrong?
For speed, you'll get the most gains if you denormalize when possible - yes, the relational purists are going to riot, but you don't have many of the benefits of normalization anyway such as foreign key constraints or native joins. If that isn't an option - and I really do recommend looking into it where it makes sense - if you're able to retrieve keys, we may also be able to make use of batch queries by key. On Mon, Apr 5, 2010 at 2:59 PM, Matt Hall matt.h...@gmail.com wrote: Hi Everyone, I've been trying for the past while to get our relatively simple JDO based site to run at a reasonable speed, but I'm failing and I'd love any suggestions. I'll describe it as succinctly as possible to hopefully keep your interest :) * The basic structure is a User - Order - Line items type structure. * The main query performed is Orders for a user. * A user usually has around 10 orders, each order has under 100 line items. * The Order - Items relationship is done as a One-to-many owned relationship. My problem is that the basic request the site handles: Get all orders for a user and do something based on the line items is very slow. In real response time, my average is now 1.5 seconds, and some of the users are seeing 20 second response times. Clearly not ok. What appears to be slow, after profiling with the new app stats tool is that each line item is getting loaded as it's used (lazy loading), which works great in some cases but terrible in this case since each item takes 20-30ms to load. I have tried: * Moving items into the default fetch group for orders, seems to have no effect (may not even be possible due to limitations of joins) * Level 2 caching with memcache - not much effect either since only the individual line items are cached, not the whole List, so we still pay a price in round trip to the cache on each line item. * A sort of wacky cache that I wrote on top of the JDO managed relationship to cache the whole collection. This went poorly and resulted in odd data inconsistencies, probably because I did something wrong but the whole thing felt wrong. So my question is - what am I doing wrong? What's the best/standard way to represent a Master - Detail type relationship, where the total items for a user will be relatively small but requests need to work with a fair number of them. Thanks for any suggestions, I'd be happy to answer any questions if what I've written isn't clear. Matt -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] uncaught exception from servlet
Can you post your project somewhere? On Mon, Apr 5, 2010 at 8:07 PM, Jeevan jeevan.don...@gmail.com wrote: Am developing an app for ma college called cloud based teaching system and am making use of blogger data api. Am getting an severe error in the appengine Logs called uncaught exception fron servlet here is the issue Uncaught exception from servlet javax.servlet.UnavailableException: Initialization failed. at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.createHandler(AppVersionHandlerMap.java: 200) at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.getHandler(AppVersionHandlerMap.java: 168) at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java: 123) at com.google.apphosting.runtime.JavaRuntime.handleRequest(JavaRuntime.java: 243) at com.google.apphosting.base.RuntimePb$EvaluationRuntime $6.handleBlockingRequest(RuntimePb.java:5485) at com.google.apphosting.base.RuntimePb$EvaluationRuntime $6.handleBlockingRequest(RuntimePb.java:5483) at com.google.net.rpc.impl.BlockingApplicationHandler.handleRequest(BlockingApplicationHandler.java: 24) at com.google.net.rpc.impl.RpcUtil.runRpcInApplication(RpcUtil.java: 398) at com.google.net.rpc.impl.Server$2.run(Server.java:852) at com.google.tracing.LocalTraceSpanRunnable.run(LocalTraceSpanRunnable.java: 56) at com.google.tracing.LocalTraceSpanBuilder.internalContinueSpan(LocalTraceSpanBuilder.java: 536) at com.google.net.rpc.impl.Server.startRpc(Server.java:807) at com.google.net.rpc.impl.Server.processRequest(Server.java:369) at com.google.net.rpc.impl.ServerConnection.messageReceived(ServerConnection.java: 442) at com.google.net.rpc.impl.RpcConnection.parseMessages(RpcConnection.java: 319) at com.google.net.rpc.impl.RpcConnection.dataReceived(RpcConnection.java: 290) at com.google.net.async.Connection.handleReadEvent(Connection.java: 474) at com.google.net.async.EventDispatcher.processNetworkEvents(EventDispatcher.java: 831) at com.google.net.async.EventDispatcher.internalLoop(EventDispatcher.java: 207) at com.google.net.async.EventDispatcher.loop(EventDispatcher.java: 103) at com.google.net.rpc.RpcService.runUntilServerShutdown(RpcService.java: 251) at com.google.apphosting.runtime.JavaRuntime $RpcRunnable.run(JavaRuntime.java:404) at java.lang.Thread.run(Unknown Source) How do i debug this,let me know thank you -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] Issue with google plugin for eclipse
What kind of project have you created? This looks like the issue filed here: http://code.google.com/p/googleappengine/issues/detail?id=2306 http://code.google.com/p/googleappengine/issues/detail?id=2306You'll have to provide more detail, though. How are you creating the project? On Tue, Apr 6, 2010 at 5:31 AM, joradom jora...@gmail.com wrote: The plugin doesn't allow me to create a new Servlet, when calling the create servlet wizard the project field appears greyed and empty. I can create a class, or any file, but of course, much more things to write are needed. just curious to know if it's a normal behaviour or some bug? I'm using Ubuntu karmic and eclipse ganimedes for java EE, with latests google plugin and sdks (just made a fresh install 3 days ago.) thx -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@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] changes regarding 1000-result query limit
hi, Does the 1000-query result limit still hold for an individual query? (I know that the use of query cursors now allows 1000 results total to be fetched). Comments such as this: http://groups.google.com/group/google-appengine-java/browse_thread/thread/88bb6df3d8cf5f78/5a98f713e9bc665f?lnk=gstq=1000+result+limit#5a98f713e9bc665f cursors are a way for you to work with datasets larger than 1000. lead me to think that a single query fetch will still *not* return more than 1000 results. Is this right? If so, I can't seem to find it in the documentation anywhere. (I have no current datasets this large, so thought I would ask to see if someone already knows the answer definitively). -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] How can I place JSession into cookie. Google app engine.
This seems redundant, even outside of App Engine. You wouldn't want to place a JSessionId into a cookie, since that is identified *by* a cookie. Likely what you are looking for is servlet session support. App Engine supports this, albeit with gotchas: http://code.google.com/appengine/docs/java/config/appconfig.html http://code.google.com/appengine/docs/java/config/appconfig.htmlNote that since session data is stored in a combination of memcache and persistent store that you'll have to resave objects when they mutate. You'll also need to manually garbage collect your session data. 2010/4/6 Alexander Rodnin alexander.rod...@gmail.com Сould you please tell me how to place the session identifier into the cookie, if you are working with google app engine. 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] Funny behavior with memcache.increment() below zero
I'm looking at the standard memcached documentation: http://github.com/memcached/memcached/blob/master/doc/protocol.txt http://github.com/memcached/memcached/blob/master/doc/protocol.txtNote that underflow in the decr command is caught: if a client tries to decrease the value below 0, the new value will be 0. Overflow in the incr command will wrap around the 64 bit mark. I'm not sure why our version of memcached behaves the way it does. I suspect it has to do with storing numbers as either signed or unsigned ints depending on what you first set the value to, with unsigned ints being the 90% case. When in doubt, use the solution that results in the least confusion. And document. On Tue, Apr 6, 2010 at 9:09 AM, Nacho Coloma icol...@gmail.com wrote: Hi all, I am trying to use memcache.increment to move to negative values, starting at 0. According to the javadoc[1]: To facilitate use as an atomic countdown, incrementing by a negative value (i.e. decrementing) will not go below zero: incrementing 2 by -5 will return 0, not -3. However, due to the way numbers are stored, decrementing -3 by -5 will result in -8; so the zero-floor rule only applies to decrementing numbers that were positive. What is the rationale behind this, and why is 0 considered positive? I may have missed something, but I did not understand a similar behavior in python's memcache.decr() docs. If my counter can hold positive or negative values, what options do I have apart from initializing at 2^30? -- Nacho [1] http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/memcache/MemcacheService.html#increment(java.lang.Object,%20long) -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] Re: JAXB Support
It looks like you're bundling the latest 2.2 JAXB RI. Apparently they made a change in that release which requires access to the protected method, ClassLoader.findLoadedClass. This makes it incompatible with App Engine. If you can use the previous release (2.1.2), a built-in version of JAXB, or even possibly a different implementation of 2.2, then you shouldn't see this problem anymore. On Tue, Apr 6, 2010 at 7:43 AM, Brian hannawaybr...@googlemail.com wrote: I've been working with the tutorial mentioned above and it runs fine in my local environment, but when I deploy to GAE JAXB is throwing the exception detailed above. I'm baffled as to why this is running locally but failing on GAE. I though the local environment was supposed to replicate the actual GAE production environment? The local environment is just a simulation of the production environment. We put a lot of effort into emulating it, but there are some edge-cases that are much more difficult to handle than others. Does anyone have any ideas? I'm really stuck with this one... On 2 Apr, 17:37, L. Kirven lrkir...@gmail.com wrote: Brian, I am doing exactly the same thing. I followed the blog below and didn't have any problems. I hope that this helps. http://tugdualgrall.blogspot.com/2010/02/create-and-deploy-jax-rs-res... On Fri, Apr 2, 2010 at 9:55 AM, Brian hannawaybr...@googlemail.com wrote: Hi, I've run into an issue with JAXB on GAE. I have set up a simple project using Jersey to expose a RESTful web service and am using JAXB for marshalling/unmarshalling. The project runs fine in my local eclipse environment but when I upload to GAE and send a request to the web service I am getting a JAXB exception (see stack trace below). I am using the latest version of JAXB and the latest version of GAE SDK. According to the white list JAXB should now be supported so I'm not sure what's going on. Any help to resolve this issue would be greatly appreciated. Uncaught exception from servlet java.lang.ExceptionInInitializerError at com.sun.xml.bind.v2.runtime.reflect.opt.AccessorInjector.prepare(AccessorIn jector.java: 79) at com.sun.xml.bind.v2.runtime.reflect.opt.OptimizedAccessorFactory.get(Optimi zedAccessorFactory.java: 165) at com.sun.xml.bind.v2.runtime.reflect.Accessor $FieldReflection.optimize(Accessor.java:256) at com.sun.xml.bind.v2.runtime.property.ArrayProperty.init(ArrayProperty.jav a: 65) at com.sun.xml.bind.v2.runtime.property.ArrayERProperty.init(ArrayERProperty .java: 84) at com.sun.xml.bind.v2.runtime.property.ArrayElementProperty.init(ArrayEleme ntProperty.java: 96) at com.sun.xml.bind.v2.runtime.property.ArrayElementNodeProperty.init(ArrayE lementNodeProperty.java: 58) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Constructor.java:33) at com.sun.xml.bind.v2.runtime.property.PropertyFactory.create(PropertyFactory .java: 124) at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.init(ClassBeanInfoImpl.java : 179) at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(JAXBContextImpl.jav a: 515) at com.sun.xml.bind.v2.runtime.JAXBContextImpl.init(JAXBContextImpl.java: 330) at com.sun.xml.bind.v2.runtime.JAXBContextImpl $JAXBContextBuilder.build(JAXBContextImpl.java:1140) at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java: 154) at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java: 121) at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java: 202) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:159) at javax.xml.bind.ContextFinder.find(ContextFinder.java:311) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at com.sun.jersey.server.impl.wadl.WadlApplicationContextImpl.init(WadlAppli cationContextImpl.java: 66) at com.sun.jersey.server.impl.wadl.WadlFactory.init(WadlFactory.java: 94) at
[appengine-java] List of sub entities does not obay list order
Hi, I need to have a one to many owned relationship and be able to reorder the list. The list is stored in the data store with new elements at the end although I add the sub entity first in the ArrayList. Any suggestions? This is the result from my test servlet. deleted all objects persisted entity: 23 before add MyEntity [keyId=23, myList=[]] added sub-entity one after add: MyEntity [keyId=23, myList=[SubEntity [name=one, id=24]]] query MyEntity [keyId=23, myList=[SubEntity [name=one, id=24]]] SubEntity [name=one, id=24] - before add MyEntity [keyId=23, myList=[SubEntity [name=one, id=24]]] added sub-entity two after add: MyEntity [keyId=23, myList=[SubEntity [name=two, id=25], SubEntity [name=one, id=24]]] query MyEntity [keyId=23, myList=[SubEntity [name=one, id=24], SubEntity [name=two, id=25]]] SubEntity [name=one, id=24] SubEntity [name=two, id=25] - before add MyEntity [keyId=23, myList=[SubEntity [name=two, id=25], SubEntity [name=one, id=24]]] added sub-entity three after add: MyEntity [keyId=23, myList=[SubEntity [name=three, id=26], SubEntity [name=two, id=25], SubEntity [name=one, id=24]]] query MyEntity [keyId=23, myList=[SubEntity [name=one, id=24], SubEntity [name=two, id=25], SubEntity [name=three, id=26]]] SubEntity [name=one, id=24] SubEntity [name=two, id=25] SubEntity [name=three, id=26] - before reorder MyEntity [keyId=23, myList=[SubEntity [name=three, id=26], SubEntity [name=two, id=25], SubEntity [name=one, id=24]]] reordered object: MyEntity [keyId=23, myList=[SubEntity [name=two, id=25], SubEntity [name=one, id=24], SubEntity [name=three, id=26]]] query MyEntity [keyId=23, myList=[SubEntity [name=one, id=24], SubEntity [name=two, id=25], SubEntity [name=three, id=26]]] SubEntity [name=one, id=24] SubEntity [name=two, id=25] SubEntity [name=three, id=26] - -- 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-j...@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: Funny behavior with memcache.increment() below zero
Ok, thanks. I'm moving values to start at 10^8 instead of zero, and it seems to work fine. On Apr 6, 7:18 pm, Ikai L (Google) ika...@google.com wrote: I'm looking at the standard memcached documentation: http://github.com/memcached/memcached/blob/master/doc/protocol.txt http://github.com/memcached/memcached/blob/master/doc/protocol.txtNote that underflow in the decr command is caught: if a client tries to decrease the value below 0, the new value will be 0. Overflow in the incr command will wrap around the 64 bit mark. I'm not sure why our version of memcached behaves the way it does. I suspect it has to do with storing numbers as either signed or unsigned ints depending on what you first set the value to, with unsigned ints being the 90% case. When in doubt, use the solution that results in the least confusion. And document. On Tue, Apr 6, 2010 at 9:09 AM, Nacho Coloma icol...@gmail.com wrote: Hi all, I am trying to use memcache.increment to move to negative values, starting at 0. According to the javadoc[1]: To facilitate use as an atomic countdown, incrementing by a negative value (i.e. decrementing) will not go below zero: incrementing 2 by -5 will return 0, not -3. However, due to the way numbers are stored, decrementing -3 by -5 will result in -8; so the zero-floor rule only applies to decrementing numbers that were positive. What is the rationale behind this, and why is 0 considered positive? I may have missed something, but I did not understand a similar behavior in python's memcache.decr() docs. If my counter can hold positive or negative values, what options do I have apart from initializing at 2^30? -- Nacho [1] http://code.google.com/appengine/docs/java/javadoc/com/google/appengi...) -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Enginehttp://googleappengine.blogspot.com|http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] Re: Database cursor for back cursor?
Offset doesn't fetch data - it does an index scan. Going to the 10,000th result using offset will require us to pass 10,000 results first in our index, but we won't be retrieving those objects. Here's a bit of a simplification of indexes, entities and how these queries work. As you know, Bigtable is a key-value store with the ability to perform range scans. Suppose you have a Person entity. Your entries may look like this: Key Value -- APPID:Person:1 { name: Ikai, favorite_food: donuts } APPID:Person:2 { name: Wesley, favorite_food: tacos } Index:APPID:Person:favorite_food:ASC:donuts:1 [ empty ] Index:APPID:Person:favorite_food:ASC:tacos:2 [ empty ] *order of values in keys may not match how we actually do it, it's just to illustrate my point ** argh, non-monospaced fonts. Sorry for the hideous table When we look for Person entities sorted by favorite_food, we essentially ask Bigtable to return all Keys that match: Index:APPID:Person:favorite_food:ASC* We get a list of Keys back and figure out keys. Using offsets, we would just pass the first N entries per the supplied offset. Cursors work by serializing the query position via the last index, allow us to go straight to the index in constant time and continue the range query. We've got a lot of content about how this works, though we probably haven't done the best job organizing it. I'd start here: http://code.google.com/appengine/articles/storage_breakdown.html I've been meaning to collect all of our talks and place them into a set of YouTube playlists. Why don't I do that right now ... On Sat, Apr 3, 2010 at 8:16 AM, John Patterson jdpatter...@gmail.comwrote: How many pages do your users really want to see? Even Google search sets a limit - I think 1000 results. Although the number of results can exceed 1000 the offset is still limited so you would need to filter out results to continue past 1K. That would be slow. If you really need to return more than 1000 results and access them in forward and backward directions you could sort them by __key__ or some other unique combination and use that as you own cursor. You could define both ascending and descending indexes on your chosen property(s) to let you iterate in both directions. On 3 Apr 2010, at 19:32, Arny wrote: But isn't it getting slower and slower on higher pages, since it fetches ALL data (according to docs) and discards the offset value? So Range(0,10) is faster than Range(1,10) ? Anyone did some performance tests? Regards On Apr 3, 7:49 am, John Patterson jdpatter...@gmail.com wrote: Probably you should set an offset and limit instead for your paging. I believe cursors are really intended for processing a lot of data off- line. Remember there is no longer a 1000 result limit on fetches. On 3 Apr 2010, at 02:57, Arny wrote: Hi, Is there a way to get a cursor to page back to a previous page? If not, whats the point of paging forward only? I'm not building an ajax page. Regards -- 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.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group athttp:// groups.google.com/group/google-appengine-java?hl=en . -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to
Re: [appengine-java] Re: Database cursor for back cursor?
We get a list of Keys back and figure out keys. I just realized how confusing this is - we get a list of INDEX keys back. These don't have any value; we do all storage inside the Key. We extract the keys of the Entity from the returned Index keys and do a query. On Tue, Apr 6, 2010 at 11:42 AM, Ikai L (Google) ika...@google.com wrote: Offset doesn't fetch data - it does an index scan. Going to the 10,000th result using offset will require us to pass 10,000 results first in our index, but we won't be retrieving those objects. Here's a bit of a simplification of indexes, entities and how these queries work. As you know, Bigtable is a key-value store with the ability to perform range scans. Suppose you have a Person entity. Your entries may look like this: Key Value -- APPID:Person:1 { name: Ikai, favorite_food: donuts } APPID:Person:2 { name: Wesley, favorite_food: tacos } Index:APPID:Person:favorite_food:ASC:donuts:1 [ empty ] Index:APPID:Person:favorite_food:ASC:tacos:2 [ empty ] *order of values in keys may not match how we actually do it, it's just to illustrate my point ** argh, non-monospaced fonts. Sorry for the hideous table When we look for Person entities sorted by favorite_food, we essentially ask Bigtable to return all Keys that match: Index:APPID:Person:favorite_food:ASC* We get a list of Keys back and figure out keys. Using offsets, we would just pass the first N entries per the supplied offset. Cursors work by serializing the query position via the last index, allow us to go straight to the index in constant time and continue the range query. We've got a lot of content about how this works, though we probably haven't done the best job organizing it. I'd start here: http://code.google.com/appengine/articles/storage_breakdown.html I've been meaning to collect all of our talks and place them into a set of YouTube playlists. Why don't I do that right now ... On Sat, Apr 3, 2010 at 8:16 AM, John Patterson jdpatter...@gmail.comwrote: How many pages do your users really want to see? Even Google search sets a limit - I think 1000 results. Although the number of results can exceed 1000 the offset is still limited so you would need to filter out results to continue past 1K. That would be slow. If you really need to return more than 1000 results and access them in forward and backward directions you could sort them by __key__ or some other unique combination and use that as you own cursor. You could define both ascending and descending indexes on your chosen property(s) to let you iterate in both directions. On 3 Apr 2010, at 19:32, Arny wrote: But isn't it getting slower and slower on higher pages, since it fetches ALL data (according to docs) and discards the offset value? So Range(0,10) is faster than Range(1,10) ? Anyone did some performance tests? Regards On Apr 3, 7:49 am, John Patterson jdpatter...@gmail.com wrote: Probably you should set an offset and limit instead for your paging. I believe cursors are really intended for processing a lot of data off- line. Remember there is no longer a 1000 result limit on fetches. On 3 Apr 2010, at 02:57, Arny wrote: Hi, Is there a way to get a cursor to page back to a previous page? If not, whats the point of paging forward only? I'm not building an ajax page. Regards -- 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.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group athttp:// groups.google.com/group/google-appengine-java?hl=en . -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs
Re: [appengine-java] is createFederatedLoginURL() working?
Hi I just noticed createFederatedLoginURL() but could not find any documentation for it (except for JavaDoc). Is this intended for native support for Google Marketplace? Would really appreciate some documentation on this. I am trying this out in 1.3.2 but get an error, The API package 'user' or call 'CreateFederatedLoginURL()' was not found. Viðar On Sat, Mar 27, 2010 at 10:27 AM, dflorey daniel.flo...@gmail.com wrote: Hi, I'm trying to replace the Step2 stuff with the new createFederatedLoginURL(), but I just get server errors in the provided /_ah/ servlets. Are these methods supposed to work and can someone please post an example how to authenticate and authorize a user? Thanks a lot, Daniel -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@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: URLFetch to localhost counts as out/inbound traffic?
Anyone did some testing whether it's increasing the in/outbound traffic? On Apr 5, 3:55 pm, Arny arny...@googlemail.com wrote: Hi, are the URLFetches to localhost count as in/outbound traffic? Regards -- 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-j...@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: Initialize local datastore exception
I know I haven't setup properly. But I don't want to do unit testing either. I would like some sample configuration file or steps in order to access the datastore outside the development server. What I have in mind is more like a batch file/operation :) Regards António Casqueiro On Apr 6, 5:00 am, Wayne Fay wayne...@gmail.com wrote: »»» EXCEPTION ««« Exception in thread main java.lang.NullPointerException: No API environment is registered for this thread. This generally means you haven't set things up properly. Follow the directions:http://code.google.com/appengine/docs/java/tools/localunittesting.html Wayne -- 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-j...@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 Relationship Performance Problems - what am I doing wrong?
Thanks for the response, could you point me to somewhere where I can read about batched queries by key in JDO? Or do I need to go to the low level API for that? I think the conclusion I'm coming to here is 1) I shouldn't have made the detail for each order as a separate object, (although this has huge problems for querying later as in how many people have bought item x), and 2) JDO managed relationships get slow with small numbers of child objects, are hard to optimize, and probably not worth the trouble overall. Is that pretty much what I should be concluding? Thanks again, I'm really trying to understand how to translate what's a basic structure in RDMS land into something that will work in app engine beyond toy implementations. On Apr 6, 12:54 pm, Ikai L (Google) ika...@google.com wrote: For speed, you'll get the most gains if you denormalize when possible - yes, the relational purists are going to riot, but you don't have many of the benefits of normalization anyway such as foreign key constraints or native joins. If that isn't an option - and I really do recommend looking into it where it makes sense - if you're able to retrieve keys, we may also be able to make use of batch queries by key. On Mon, Apr 5, 2010 at 2:59 PM, Matt Hall matt.h...@gmail.com wrote: Hi Everyone, I've been trying for the past while to get our relatively simple JDO based site to run at a reasonable speed, but I'm failing and I'd love any suggestions. I'll describe it as succinctly as possible to hopefully keep your interest :) * The basic structure is a User - Order - Line items type structure. * The main query performed is Orders for a user. * A user usually has around 10 orders, each order has under 100 line items. * The Order - Items relationship is done as a One-to-many owned relationship. My problem is that the basic request the site handles: Get all orders for a user and do something based on the line items is very slow. In real response time, my average is now 1.5 seconds, and some of the users are seeing 20 second response times. Clearly not ok. What appears to be slow, after profiling with the new app stats tool is that each line item is getting loaded as it's used (lazy loading), which works great in some cases but terrible in this case since each item takes 20-30ms to load. I have tried: * Moving items into the default fetch group for orders, seems to have no effect (may not even be possible due to limitations of joins) * Level 2 caching with memcache - not much effect either since only the individual line items are cached, not the whole List, so we still pay a price in round trip to the cache on each line item. * A sort of wacky cache that I wrote on top of the JDO managed relationship to cache the whole collection. This went poorly and resulted in odd data inconsistencies, probably because I did something wrong but the whole thing felt wrong. So my question is - what am I doing wrong? What's the best/standard way to represent a Master - Detail type relationship, where the total items for a user will be relatively small but requests need to work with a fair number of them. Thanks for any suggestions, I'd be happy to answer any questions if what I've written isn't clear. Matt -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2B unsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Enginehttp://googleappengine.blogspot.com|http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] elegant way of implementing sequence generator
Memcache data is never persisted to disk, so in the event of a Memcache server restart, you will lose all the data in Memcache. In addition, Memcache evicts items based on an LRU cache: if you don't use data for a while and space is needed, the item will be removed from your cache to allow for your new items. You can read more about Memcache here: http://code.google.com/p/memcached/wiki/FAQ http://code.google.com/p/memcached/wiki/FAQ On Sat, Apr 3, 2010 at 12:59 AM, aswath satrasala aswath.satras...@gmail.com wrote: Hello Ikai, I am interested in Sequences, sequence starting from a initial value and increments. Can you little bit elaborate here on what is the risk with volatile here when using memcache. Regards -Aswath On Sat, Mar 6, 2010 at 1:05 AM, Ikai L (Google) ika...@google.com wrote: Have you looked into Memcache's INCR? http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/memcache/MemcacheService.html#increment(java.lang.Objecthttp://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/memcache/MemcacheService.html#increment%28java.lang.Object , long) This'll do it atomically, but you run the risk of it being volatile, so you'll have to account for that in your client code. On Tue, Mar 2, 2010 at 11:40 PM, legendlink gregc...@gmail.com wrote: hi, i wanted to have a sequence generator that increments by x value everytime it generates a value. if i would create the sequence generator by using the datastore, it is likely that data contention would occurr if there is high access times. i have looked into the sample code of max ross in the google code repository (SequenceExamplesJDO.java) and think this is limited to increment by 1 only and not increment by x value. if sharding technique is used, my concern is that i might not get the right sequence. what is the best/elegant way of doing sequence generator that increments x value? -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@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 Relationship Performance Problems - what am I doing wrong?
Before proposing a solution, what is your expected active user base. 1000's or 1,000,000s or something in between. Steve On Apr 6, 3:50 pm, Matt Hall matt.h...@gmail.com wrote: Thanks for the response, could you point me to somewhere where I can read about batched queries by key in JDO? Or do I need to go to the low level API for that? I think the conclusion I'm coming to here is 1) I shouldn't have made the detail for each order as a separate object, (although this has huge problems for querying later as in how many people have bought item x), and 2) JDO managed relationships get slow with small numbers of child objects, are hard to optimize, and probably not worth the trouble overall. Is that pretty much what I should be concluding? Thanks again, I'm really trying to understand how to translate what's a basic structure in RDMS land into something that will work in app engine beyond toy implementations. On Apr 6, 12:54 pm, Ikai L (Google) ika...@google.com wrote: For speed, you'll get the most gains if you denormalize when possible - yes, the relational purists are going to riot, but you don't have many of the benefits of normalization anyway such as foreign key constraints or native joins. If that isn't an option - and I really do recommend looking into it where it makes sense - if you're able to retrieve keys, we may also be able to make use of batch queries by key. On Mon, Apr 5, 2010 at 2:59 PM, Matt Hall matt.h...@gmail.com wrote: Hi Everyone, I've been trying for the past while to get our relatively simple JDO based site to run at a reasonable speed, but I'm failing and I'd love any suggestions. I'll describe it as succinctly as possible to hopefully keep your interest :) * The basic structure is a User - Order - Line items type structure. * The main query performed is Orders for a user. * A user usually has around 10 orders, each order has under 100 line items. * The Order - Items relationship is done as a One-to-many owned relationship. My problem is that the basic request the site handles: Get all orders for a user and do something based on the line items is very slow. In real response time, my average is now 1.5 seconds, and some of the users are seeing 20 second response times. Clearly not ok. What appears to be slow, after profiling with the new app stats tool is that each line item is getting loaded as it's used (lazy loading), which works great in some cases but terrible in this case since each item takes 20-30ms to load. I have tried: * Moving items into the default fetch group for orders, seems to have no effect (may not even be possible due to limitations of joins) * Level 2 caching with memcache - not much effect either since only the individual line items are cached, not the whole List, so we still pay a price in round trip to the cache on each line item. * A sort of wacky cache that I wrote on top of the JDO managed relationship to cache the whole collection. This went poorly and resulted in odd data inconsistencies, probably because I did something wrong but the whole thing felt wrong. So my question is - what am I doing wrong? What's the best/standard way to represent a Master - Detail type relationship, where the total items for a user will be relatively small but requests need to work with a fair number of them. Thanks for any suggestions, I'd be happy to answer any questions if what I've written isn't clear. Matt -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2B unsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Enginehttp://googleappengine.blogspot.com|http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] Blogger API
You'll want to read the GData docs here: http://code.google.com/apis/blogger/docs/2.0/developers_guide.html Here are the Java specific docs: http://code.google.com/apis/blogger/docs/2.0/developers_guide_java.html On Mon, Apr 5, 2010 at 3:04 AM, Jeevan jeevan.don...@gmail.com wrote: hello am developing an application which is to be hosted on app engine,i wanna make use of blogger api, i am not able to run the blogger data api,am not able to understand how do i make use of the same please help me... 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] appcfg.sh update keeping asking for email/password
Are you still having this issue? Does it give you an error trace? On Sun, Apr 4, 2010 at 1:17 PM, Bendanpa benda...@gmail.com wrote: I am very sure that I gave correct email/password. Anybody have the same issue? Thanks, Bendanpa -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en. -- Ikai Lan Developer Programs Engineer, Google App Engine http://googleappengine.blogspot.com | http://twitter.com/app_engine -- You received this message because you are subscribed to the Google Groups Google App Engine for Java group. To post to this group, send email to google-appengine-j...@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: Trying a clean compile gives The parameter is incorrect
Thanks to the guys on the GWT forum for helping me solve this problem. It did turn out to be a classpath problem and there follows an explanation of the steps I took to discover the issue and how I solved it: To find out the classpath used: In Eclipse select Debug view by going to Window|Open Perspective|Debug and then select the debug window by going to Window|Show View|Debug then right click the last item in the list shown and select properties I found that my appengine SDK path was being references about 21 times as: C:\Program Files\eclipse\plugins \com.google.appengine.eclipse.sdkbundle. 1.3.2_1.3.2.v201003241245\appengine-java-sdk-1.3.2 so I copied it to C:\appengine-java-sdk-1.3.2 And then linked to it by doing the following: In Eclipse select the Java view by going to Window|Open Perspective| Java and then select the project properties by going to Project| Properties then select Google|App Engine and click on Configure SDK's then click Add on the right hand side and select the path you just created eg C:\appengine-java-sdk-1.3.2 and add a Display Name eg Short App Engine SDK. Click OK as needed to close all the windows, and everything should start working again!!! Good Luck, John On Apr 5, 5:20 pm, John V Denley johnvden...@googlemail.com wrote: Im on the train now... hoping my connection holds up, but just incase it helps, I have now rolled back to a version of the code that I comiled and deployed successfully last night, and Im still getting this error, so something else has changed, and its not me thats changed it... this must be something that Eclipse or Java compiler is picking up from somewhere else!. On Apr 5, 3:54 pm, John V Denley johnvden...@googlemail.com wrote: What is this message telling me? 'DataNucleus Enhancer' has encountered a problem Cannot run program C:\Program Files\Java\jre6\bin\javaw.exe (in directory C:\Documents and Settings\John\My Documents\_DeBa\ideba \iDeBanet): CreateProcess error=87, The parameter is incorrect Cannot run program C:\Program Files\Java\jre6\bin\javaw.exe (in directory C:\Documents and Settings\John\My Documents\_DeBa\ideba \iDeBanet): CreateProcess error=87, The parameter is incorrect I cant seem to find anything helpful anywhere on the web, all I can find is suggestions that my classpath is too long for windows, but I dont know where to figure out what my classpath length is, plus its not THAT big a project, so im surprised ive hit any kind of limit, although I HAVE just included one additional *.java file in my client directory, but I have tried taking that out and recompiling clean, and its still happening! Is this aGWTproblem? or an Eclipse problem or a Java problem? Any pointers would be really helpful, as i have a deadline for tomorrow, the code is all done, I just cant seem to deploy it! Thanks, John PS Im posting this on theGWTgrouptoo, as I have to catch a train now, and will be back later to see if anyone has replied! -- 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-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] JPA: Query contains stale data (bug or future)?
It looks like you are changing the elements of the List themselves and not the List. You'll have to mark the object as dirty: https://groups.google.com/group/google-appengine-java/browse_thread/thread/152cdafdded18611?pli=1auth=DQAAALsysGgvSS7DADt9mTLjZVIfRcR3Ia0xnDJnZbMuAemwe776lEU-XNeYHi4XHpY5Bifg1xWbsctkBvQx5zML0axYXo2NlqltSM4p3KzBugUeNMAkhXyhYebPm0lQcCpCpuEMiZJ5JGfnPurgwrr9v8ED7wmeYMVS1mNUkJlDtsjLTiBUckaN4zVpHE9A954YDaNF86Ph7tzt99WvOJSlKPpB5IElWR-LPXslY-8v_KJTBvSm2gqRVhib-1IBIh9QxBo https://groups.google.com/group/google-appengine-java/browse_thread/thread/152cdafdded18611?pli=1auth=DQAAALsysGgvSS7DADt9mTLjZVIfRcR3Ia0xnDJnZbMuAemwe776lEU-XNeYHi4XHpY5Bifg1xWbsctkBvQx5zML0axYXo2NlqltSM4p3KzBugUeNMAkhXyhYebPm0lQcCpCpuEMiZJ5JGfnPurgwrr9v8ED7wmeYMVS1mNUkJlDtsjLTiBUckaN4zVpHE9A954YDaNF86Ph7tzt99WvOJSlKPpB5IElWR-LPXslY-8v_KJTBvSm2gqRVhib-1IBIh9QxBoI'm not completely sure this is what's going on here, as I just did a quick read through of your code. Can you give this a try? On Fri, Mar 26, 2010 at 11:47 PM, danblack firewor...@gmail.com wrote: Hello. I'm using JPA support for managing the App Engine datastore. And I've got some problems. I've got an entity Container than contains entities Item(s). Here is my actions. I starts transaction then updates entity then flush updates to database. Than I gets all entities Item(s) for a container which contains my updated Item. But the list of retrieved items contains Item that does not have my changes. What is wrong with my code??? I've modelled this problem. (see code) @Entity public class Container implements Serializable { private static final long serialVersionUID = 1L; @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Key key; @OneToMany(mappedBy = container, fetch = FetchType.LAZY) private ListItem items = new ArrayListItem(); public void setKey(Key key) { this.key = key; } public Key getKey() { return key; } public void setItems(ListItem items) { this.items = items; } public ListItem getItems() { return items; } } @Entity public class Item implements Serializable { private static final long serialVersionUID = 1L; @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Key key; @ManyToOne(fetch = FetchType.LAZY) private Container container; @Column private String value; public void setKey(Key key) { this.key = key; } public Key getKey() { return key; } public void setContainer(Container container) { this.container = container; } public Container getContainer() { return container; } public void setValue(String value) { this.value = value; } public String getValue() { return value; } @Override public String toString() { return Item [key= + key + , value= + value + ]; } } @Service(TestLocalService) public class LocalService { protected final Log logger = LogFactory.getLog(getClass()); @Autowired @Qualifier(jpaTemplate) protected JpaTemplate jpaTemplate; @Transactional(propagation = Propagation.REQUIRED) public Key createContainer() { Container container = new Container(); jpaTemplate.persist(container); jpaTemplate.flush(); logger.fatal(new container + container.getKey()); return container.getKey(); } @Transactional(propagation = Propagation.REQUIRED) public Key generateItems(Key containerKey) { Container container = jpaTemplate.find(Container.class, containerKey); Key key = null; for (int i = 0; i 5; i++) { Item item = new Item(); item.setContainer(container); item.setValue(Integer.toString(i)); jpaTemplate.persist(item); jpaTemplate.flush(); key = item.getKey(); logger.fatal(new item + item); } return key; } @Transactional(propagation = Propagation.REQUIRED) public void changeItems(Key containerKey, Key itemKey) { Container container = jpaTemplate.find(Container.class, containerKey); Item changedItem = jpaTemplate.find(Item.class, itemKey); changedItem.setValue(xxx); // --- PROBLEM HERE jpaTemplate.flush(); logger.fatal(changed item: + changedItem);
Re: [appengine-java] Re: JDO Relationship Performance Problems - what am I doing wrong?
The most important number in my mind is the number of line items in an order. If you're seeing 20s+ queries, it must be a pretty large number. Objectify (and Twig) support queryable collections of embedded objects, so you can put all the line items in a single order object. There are some practical limits to this approach, though - the collection can have at most 5k items and the total entity size cannot exceed 1MB. Also, writing out indexed collections with 5,000 entries is *very* expensive in terms of $, so if you have a high churn rate you'll burn through your budget pretty fast. Obviously serialization is an option, but then you won't be able to query for orders by line item data. If it makes the most sense to keep the line items as separate objects (because of churn or simple volume of line items) you can still use the memcache to your advantage. You'll want a bidirectional relationship, with Keys stored in the Order pointing to the LineItems as well as vice-versa. You can load an Order and use the LineItem keys to perform a batch get, hopefully most of which will come out of the memcache. It's hard to suggest a strategy without knowing the shape of the data, the query expected profile, and the churn rate. Jeff On Tue, Apr 6, 2010 at 2:23 PM, Steve Pritchard steve...@gmail.com wrote: Before proposing a solution, what is your expected active user base. 1000's or 1,000,000s or something in between. Steve On Apr 6, 3:50 pm, Matt Hall matt.h...@gmail.com wrote: Thanks for the response, could you point me to somewhere where I can read about batched queries by key in JDO? Or do I need to go to the low level API for that? I think the conclusion I'm coming to here is 1) I shouldn't have made the detail for each order as a separate object, (although this has huge problems for querying later as in how many people have bought item x), and 2) JDO managed relationships get slow with small numbers of child objects, are hard to optimize, and probably not worth the trouble overall. Is that pretty much what I should be concluding? Thanks again, I'm really trying to understand how to translate what's a basic structure in RDMS land into something that will work in app engine beyond toy implementations. On Apr 6, 12:54 pm, Ikai L (Google) ika...@google.com wrote: For speed, you'll get the most gains if you denormalize when possible - yes, the relational purists are going to riot, but you don't have many of the benefits of normalization anyway such as foreign key constraints or native joins. If that isn't an option - and I really do recommend looking into it where it makes sense - if you're able to retrieve keys, we may also be able to make use of batch queries by key. On Mon, Apr 5, 2010 at 2:59 PM, Matt Hall matt.h...@gmail.com wrote: Hi Everyone, I've been trying for the past while to get our relatively simple JDO based site to run at a reasonable speed, but I'm failing and I'd love any suggestions. I'll describe it as succinctly as possible to hopefully keep your interest :) * The basic structure is a User - Order - Line items type structure. * The main query performed is Orders for a user. * A user usually has around 10 orders, each order has under 100 line items. * The Order - Items relationship is done as a One-to-many owned relationship. My problem is that the basic request the site handles: Get all orders for a user and do something based on the line items is very slow. In real response time, my average is now 1.5 seconds, and some of the users are seeing 20 second response times. Clearly not ok. What appears to be slow, after profiling with the new app stats tool is that each line item is getting loaded as it's used (lazy loading), which works great in some cases but terrible in this case since each item takes 20-30ms to load. I have tried: * Moving items into the default fetch group for orders, seems to have no effect (may not even be possible due to limitations of joins) * Level 2 caching with memcache - not much effect either since only the individual line items are cached, not the whole List, so we still pay a price in round trip to the cache on each line item. * A sort of wacky cache that I wrote on top of the JDO managed relationship to cache the whole collection. This went poorly and resulted in odd data inconsistencies, probably because I did something wrong but the whole thing felt wrong. So my question is - what am I doing wrong? What's the best/standard way to represent a Master - Detail type relationship, where the total items for a user will be relatively small but requests need to work with a fair number of them. Thanks for any suggestions, I'd be happy to answer any questions if what I've written isn't clear. Matt -- You received this message because you are subscribed to the Google Groups Google App Engine
[appengine-java] A catch-all servlet?
Hi, I'm using GWT and GAE. I want to serve my project's one and only jsp file no matter what url is entered by the user in their browser. So the web.xml file looks like this: welcome-file-list welcome-fileUserMaps.jsp/welcome-file /welcome-file-list servlet servlet-nameindexpage/servlet-name jsp-fileUserMaps.jsp/jsp-file /servlet servlet-mapping servlet-nameindexpage/servlet-name url-pattern/*/url-pattern /servlet-mapping when I run this locally, it works fine. Any of the following urls serve my gwt app with UserMaps.jsp: http://localhost:/ http://localhost:/JohnDoe http://localhost:/JaneDoe when I publish to GAE, it stops working, none of the urls can find UserMaps.jsp: http://usermaps.appspot.com/ http://usermaps.appspot.com/JohnDoe/ http://usermaps.appspot.com/JaneDoe/ I'm not sure if this should work, I'm looking at the reference here: http://code.google.com/appengine/docs/java/config/webxml.html#The_Welcome_File_List My real goal is to support a twitter-like url mapping scheme where a user can enter my domain/username, and I'll show them their customized user page (by pulling some info out of the data store and dynamically rendering a page for them), 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-j...@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.