[appengine-java] Re: Unable to upload application

2010-03-18 Thread Peter Ondruska
Thanks, works fine now.

On Mar 19, 12:47 am, Jon McAlister  wrote:
> Yep, we had a bad admin console push and deploys were affected
> from 3:10pm PST until 4:30pm PST. All better now. Apologies.
>
>
>
> On Thu, Mar 18, 2010 at 3:50 PM, Huebi  wrote:
> > here as well :(
>
> > On 18 Mrz., 23:42, François Masurel  wrote:
> >> Same problem here too :-(
>
> >> On 18 mar, 23:30, Sandeep Sathaye  wrote:
>
> >> > I am having the same problem.
>
> >> > On Thu, Mar 18, 2010 at 6:26 PM, Peter Ondruska 
> >> > wrote:
>
> >> > > I am trying to upload my application but it fails everytime:
>
> >> > > com.google.appengine.tools.admin.AdminException: Unable to update app:
> >> > > Error posting to URL:
> >> > >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
> >> > > 500 Internal Server Error
>
> >> > > Server Error (500)
> >> > > A server error has occurred.
>
> >> > > at
> >> > > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> >> > > 62)
> >> > > at
>
> >> > > com.google.appengine.eclipse.core.proxy.AppEngineBridgeImpl.deploy(AppEngin
> >> > >  eBridgeImpl.java:
> >> > > 271)
> >> > > at
>
> >> > > com.google.appengine.eclipse.core.deploy.DeployProjectJob.runInWorkspace(De
> >> > >  ployProjectJob.java:
> >> > > 145)
> >> > > at
>
> >> > > org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorksp
> >> > >  aceJob.java:
> >> > > 38)
> >> > > at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
> >> > > Caused by: java.io.IOException: Error posting to URL:
>
> >> > >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
> >> > > 500 Internal Server Error
>
> >> > > Server Error (500)
> >> > > A server error has occurred.
>
> >> > > at
>
> >> > > com.google.appengine.tools.admin.ServerConnection.send(ServerConnection.jav
> >> > >  a:
> >> > > 149)
> >> > > at
>
> >> > > com.google.appengine.tools.admin.ServerConnection.post(ServerConnection.jav
> >> > >  a:
> >> > > 82)
> >> > > at
>
> >> > > com.google.appengine.tools.admin.AppVersionUpload.send(AppVersionUpload.jav
> >> > >  a:
> >> > > 532)
> >> > > at
>
> >> > > com.google.appengine.tools.admin.AppVersionUpload.beginTransaction(AppVersi
> >> > >  onUpload.java:
> >> > > 349)
> >> > > at
>
> >> > > com.google.appengine.tools.admin.AppVersionUpload.doUpload(AppVersionUpload
> >> > >  .java:
> >> > > 111)
> >> > > at
> >> > > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> >> > > 56)
> >> > > ... 4 more
>
> >> > > --
> >> > > 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 >> > >  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 
> > 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.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



[appengine-java] XMPP : Alert on user accepted invitation

2010-03-18 Thread Rahul
I was wondering is there a way to know that a user accepted an
invitation sent by the XMPP application ?

Suppose i send invitation to few people and as soon as one of them
accepts the invitation i want to send him some personalized message
welcoming him and telling him various application features.

Is it possible and how ? Appreciate your response or any pointer on
this ?

Thanks,
Rahul

-- 
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] Does memcache get clean when new version deployed and made to be the default one?

2010-03-18 Thread John Patterson

No.

On 19 Mar 2010, at 08:37, opok wrote:


Hi all, does memcache get clean when new version deployed and made to
be the default one?

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




--
You received this message because you are subscribed to the Google Groups "Google 
App Engine for Java" group.
To post to this group, send email to google-appengine-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 to properly persist an unowned object?

2010-03-18 Thread John Patterson


On 18 Mar 2010, at 20:27, Mark wrote:


Hi,

I'm not understanding how to implement a simple unowned relationship.
I have two classes like:

 class Farm {
   List mHorses;
 }

 class Horse {
   @PrimaryKey
   Key mKey;
 }

so a Farm can have some horses. I'd like to create a new horse, then
put it on a farm, in one transaction.


This requires Horse to be a descendant of Farm to be in the same  
entity group.  Therefore a horse could not move farms unless you  
delete and recreate it with a new Key.



But how do I know the key of the
horse during the transaction?:

 Farm farm = loadFarm(...);
 Horse horse = new Horse();
 horse.setName("Roger");
 try {
   tx = pm.currentTransaction();
   tx.begin();
   pm.makePersistent(horse); // is the key available now?
   farm.mHorses.add(horse.mKey);
   pm.makePersistent(farm);
   tx.commit();
 }

when is the Horse.mKey value actually set and ready for use?


As soon as you "put" an entity in the datastore without a key a new  
one will be generated with a unique long value.  So you can use this  
in the rest of the same transaction



Or do I
have to do this as two separate atomic operations:

 1) Save the horse which generates its mKey value.
 2) If that worked, add it to the farm, persist the farm again.
 3) If that worked, all good, if not, have to delete the horse cause
now it's in limbo?


You won't need to delete any horses if it is done in a transaction -  
rollback will take care of everything.


I know you are experimenting with JDO but just as an example in Twig  
to show how much cleaner it is without messing with Keys:


 class Farm {
   List mHorses;  // direct unowned reference
 }

 class Horse {
String name;
 }

No Keys are needed so your data models are actually more portable and  
natural than using JDO-GAE.


Then to store a horse with the Farm as its parent go:

farm.mHorses.add(myHorse);
datastore.store(myHorse, myFarm);
datastore.update(myFarm);

The store() command creates the Key and caches it so when you update  
the farm it already has the Key.


Hope some of this helps!

John

--
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] Google Blocking URLFetches to Yahoo?

2010-03-18 Thread A1programmer
Is Google blocking URL Fetch calls to Yahoo?

 Timeout while fetching: 
http://mail.yahooapis.com/ws/mail/v1.1/soap?appid=..-&WSSID=...

This works locally, but "instantly" fails with a "timeout" warning,
which makes no sense.

I had to resort to using the Yahoo mail API since I cannot send MMS
email from App Engine, with zero help from Google (although I have
made multiple attempts).

-- 
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] Does memcache get clean when new version deployed and made to be the default one?

2010-03-18 Thread opok
Hi all, does memcache get clean when new version deployed and made to
be the default one?

-- 
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: How to query for parent key property of an entity's key?

2010-03-18 Thread tempy
Ugorji,
This sounds good but I haven't found a way to accomplish it in JDO.
The closest is, I think, is described here:

http://code.google.com/appengine/docs/java/datastore/transactions.html#Using_Transactions
"To create an object with a system-generated numeric ID and an entity
group parent, you must use an entity group parent key field (such as
customerKey, above). Assign the key of the parent to the parent key
field, then leave the object's key field set to null. When the object
is saved, the datastore populates the key field with the complete key,
including the entity group parent."

Which doesn't work for me because I have to explicitly create the key
of the child.

Tristan,
I think your approach is the correct one.  The single-entity-group
write limit is something new to me, new and worrisome. =/  I need the
entity groups that I have for transactionality and faster read speeds,
but the write-limit is something I will have to deal with.

Thanks for the advice!

On Mar 18, 4:28 pm, Ugorji  wrote:
> Use an ancestor-is query. This will find all entities which have a
> given ancestor as parent. It even works in a kind-less query,
> returning different kinds of entities under that parent. It's also
> quite efficient (especially from a pricing/CPU cost perspective) since
> theoretically, all this can be done on a single database node.
>
> I'm not sure how to do ancestor-is query with JDO (I use my own type-
> safe wrapper over low-level API), but you could try something like:
>
> select from ... where ANCESTOR=... (like __key__, ANCESTOR seems to be
> a reserved name in app engine)
>
> On Mar 18, 7:56 am, tempy  wrote:
>
>
>
> > That's a good point, but in this case the resulting entity group
> > arrangement is intentional.  Lock-in isn't a worry, I can confidently
> > say that these entity-group arrangements will last as long as the
> > application does.
>
> > Though, as you point out, I can make a "parentKey" field on the child,
> > but since this parent key will also have to appear within the child's
> > key, having such a field is redundant and I would rather avoid it.
>
> > On Mar 18, 3:51 pm, Tristan  wrote:
>
> > > Something you may want to consider is that you are placing yourself
> > > within the limitations of entity groups by sticking children under
> > > parent keys. You may want to consider a model where the parent key is
> > > simply a field in the child and then run a simple query testing that
> > > the "parentKey" field is equal to the one you're looking for. This
> > > makes queries easier and prevents entity group lock-in.
>
> > > Cheers!
>
> > > On Mar 18, 8:55 am, tempy  wrote:
>
> > > > I want to retrieve all entities that are children of one other
> > > > particular entity, by checking if the parent-key property of the
> > > > child's key matches the parent key.  I have a reference to the parent
> > > > entity but I want to avoid loading all of its children (as there may
> > > > be many children, but I only need a few).  Thus I want a query that
> > > > looks something like this:
>
> > > >         query = pm.newQuery("select from " + ChildClass.class.getName() 
> > > > +
> > > > " where :parentID.contains(ChildIDProperty.ParentID) &&
> > > > SomeOtherProperty  > " + filterString);
>
> > > > But I'm not sure how to exactly address the parent key property of a
> > > > key in a query.
>
> > > > Thanks,
> > > > Mike

-- 
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: Unable to upload application

2010-03-18 Thread Jon McAlister
Yep, we had a bad admin console push and deploys were affected
from 3:10pm PST until 4:30pm PST. All better now. Apologies.

On Thu, Mar 18, 2010 at 3:50 PM, Huebi  wrote:
> here as well :(
>
> On 18 Mrz., 23:42, François Masurel  wrote:
>> Same problem here too :-(
>>
>> On 18 mar, 23:30, Sandeep Sathaye  wrote:
>>
>>
>>
>> > I am having the same problem.
>>
>> > On Thu, Mar 18, 2010 at 6:26 PM, Peter Ondruska 
>> > wrote:
>>
>> > > I am trying to upload my application but it fails everytime:
>>
>> > > com.google.appengine.tools.admin.AdminException: Unable to update app:
>> > > Error posting to URL:
>> > >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
>> > > 500 Internal Server Error
>>
>> > > Server Error (500)
>> > > A server error has occurred.
>>
>> > > at
>> > > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
>> > > 62)
>> > > at
>>
>> > > com.google.appengine.eclipse.core.proxy.AppEngineBridgeImpl.deploy(AppEngin
>> > >  eBridgeImpl.java:
>> > > 271)
>> > > at
>>
>> > > com.google.appengine.eclipse.core.deploy.DeployProjectJob.runInWorkspace(De
>> > >  ployProjectJob.java:
>> > > 145)
>> > > at
>>
>> > > org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorksp
>> > >  aceJob.java:
>> > > 38)
>> > > at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
>> > > Caused by: java.io.IOException: Error posting to URL:
>>
>> > >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
>> > > 500 Internal Server Error
>>
>> > > Server Error (500)
>> > > A server error has occurred.
>>
>> > > at
>>
>> > > com.google.appengine.tools.admin.ServerConnection.send(ServerConnection.jav
>> > >  a:
>> > > 149)
>> > > at
>>
>> > > com.google.appengine.tools.admin.ServerConnection.post(ServerConnection.jav
>> > >  a:
>> > > 82)
>> > > at
>>
>> > > com.google.appengine.tools.admin.AppVersionUpload.send(AppVersionUpload.jav
>> > >  a:
>> > > 532)
>> > > at
>>
>> > > com.google.appengine.tools.admin.AppVersionUpload.beginTransaction(AppVersi
>> > >  onUpload.java:
>> > > 349)
>> > > at
>>
>> > > com.google.appengine.tools.admin.AppVersionUpload.doUpload(AppVersionUpload
>> > >  .java:
>> > > 111)
>> > > at
>> > > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
>> > > 56)
>> > > ... 4 more
>>
>> > > --
>> > > 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> > >  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.
>
>

-- 
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: Unable to upload application

2010-03-18 Thread Huebi
here as well :(

On 18 Mrz., 23:42, François Masurel  wrote:
> Same problem here too :-(
>
> On 18 mar, 23:30, Sandeep Sathaye  wrote:
>
>
>
> > I am having the same problem.
>
> > On Thu, Mar 18, 2010 at 6:26 PM, Peter Ondruska 
> > wrote:
>
> > > I am trying to upload my application but it fails everytime:
>
> > > com.google.appengine.tools.admin.AdminException: Unable to update app:
> > > Error posting to URL:
> > >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
> > > 500 Internal Server Error
>
> > > Server Error (500)
> > > A server error has occurred.
>
> > > at
> > > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> > > 62)
> > > at
>
> > > com.google.appengine.eclipse.core.proxy.AppEngineBridgeImpl.deploy(AppEngin
> > >  eBridgeImpl.java:
> > > 271)
> > > at
>
> > > com.google.appengine.eclipse.core.deploy.DeployProjectJob.runInWorkspace(De
> > >  ployProjectJob.java:
> > > 145)
> > > at
>
> > > org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorksp
> > >  aceJob.java:
> > > 38)
> > > at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
> > > Caused by: java.io.IOException: Error posting to URL:
>
> > >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
> > > 500 Internal Server Error
>
> > > Server Error (500)
> > > A server error has occurred.
>
> > > at
>
> > > com.google.appengine.tools.admin.ServerConnection.send(ServerConnection.jav
> > >  a:
> > > 149)
> > > at
>
> > > com.google.appengine.tools.admin.ServerConnection.post(ServerConnection.jav
> > >  a:
> > > 82)
> > > at
>
> > > com.google.appengine.tools.admin.AppVersionUpload.send(AppVersionUpload.jav
> > >  a:
> > > 532)
> > > at
>
> > > com.google.appengine.tools.admin.AppVersionUpload.beginTransaction(AppVersi
> > >  onUpload.java:
> > > 349)
> > > at
>
> > > com.google.appengine.tools.admin.AppVersionUpload.doUpload(AppVersionUpload
> > >  .java:
> > > 111)
> > > at
> > > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> > > 56)
> > > ... 4 more
>
> > > --
> > > 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 > >  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: Unable to upload application

2010-03-18 Thread François Masurel
Same problem here too :-(

On 18 mar, 23:30, Sandeep Sathaye  wrote:
> I am having the same problem.
>
> On Thu, Mar 18, 2010 at 6:26 PM, Peter Ondruska 
> wrote:
>
>
>
> > I am trying to upload my application but it fails everytime:
>
> > com.google.appengine.tools.admin.AdminException: Unable to update app:
> > Error posting to URL:
> >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
> > 500 Internal Server Error
>
> > Server Error (500)
> > A server error has occurred.
>
> > at
> > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> > 62)
> > at
>
> > com.google.appengine.eclipse.core.proxy.AppEngineBridgeImpl.deploy(AppEngin 
> > eBridgeImpl.java:
> > 271)
> > at
>
> > com.google.appengine.eclipse.core.deploy.DeployProjectJob.runInWorkspace(De 
> > ployProjectJob.java:
> > 145)
> > at
>
> > org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorksp 
> > aceJob.java:
> > 38)
> > at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
> > Caused by: java.io.IOException: Error posting to URL:
>
> >https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5q...
> > 500 Internal Server Error
>
> > Server Error (500)
> > A server error has occurred.
>
> > at
>
> > com.google.appengine.tools.admin.ServerConnection.send(ServerConnection.jav 
> > a:
> > 149)
> > at
>
> > com.google.appengine.tools.admin.ServerConnection.post(ServerConnection.jav 
> > a:
> > 82)
> > at
>
> > com.google.appengine.tools.admin.AppVersionUpload.send(AppVersionUpload.jav 
> > a:
> > 532)
> > at
>
> > com.google.appengine.tools.admin.AppVersionUpload.beginTransaction(AppVersi 
> > onUpload.java:
> > 349)
> > at
>
> > com.google.appengine.tools.admin.AppVersionUpload.doUpload(AppVersionUpload 
> > .java:
> > 111)
> > at
> > com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> > 56)
> > ... 4 more
>
> > --
> > 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 > 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.



Re: [appengine-java] Unable to upload application

2010-03-18 Thread Sandeep Sathaye
I am having the same problem.

On Thu, Mar 18, 2010 at 6:26 PM, Peter Ondruska wrote:

> I am trying to upload my application but it fails everytime:
>
> com.google.appengine.tools.admin.AdminException: Unable to update app:
> Error posting to URL:
> https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5qt&version=2&;
> 500 Internal Server Error
>
> Server Error (500)
> A server error has occurred.
>
> 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: java.io.IOException: Error posting to URL:
>
> https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5qt&version=2&;
> 500 Internal Server Error
>
> Server Error (500)
> A server error has occurred.
>
> at
>
> com.google.appengine.tools.admin.ServerConnection.send(ServerConnection.java:
> 149)
> at
>
> com.google.appengine.tools.admin.ServerConnection.post(ServerConnection.java:
> 82)
> at
>
> com.google.appengine.tools.admin.AppVersionUpload.send(AppVersionUpload.java:
> 532)
> at
>
> com.google.appengine.tools.admin.AppVersionUpload.beginTransaction(AppVersionUpload.java:
> 349)
> at
>
> com.google.appengine.tools.admin.AppVersionUpload.doUpload(AppVersionUpload.java:
> 111)
> at
> com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
> 56)
> ... 4 more
>
> --
> 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] Unable to upload application

2010-03-18 Thread Peter Ondruska
I am trying to upload my application but it fails everytime:

com.google.appengine.tools.admin.AdminException: Unable to update app:
Error posting to URL: 
https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5qt&version=2&;
500 Internal Server Error

Server Error (500)
A server error has occurred.

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: java.io.IOException: Error posting to URL:
https://appengine.google.com/api/appversion/create?app_id=f72dzzn5q5qt&version=2&;
500 Internal Server Error

Server Error (500)
A server error has occurred.

at
com.google.appengine.tools.admin.ServerConnection.send(ServerConnection.java:
149)
at
com.google.appengine.tools.admin.ServerConnection.post(ServerConnection.java:
82)
at
com.google.appengine.tools.admin.AppVersionUpload.send(AppVersionUpload.java:
532)
at
com.google.appengine.tools.admin.AppVersionUpload.beginTransaction(AppVersionUpload.java:
349)
at
com.google.appengine.tools.admin.AppVersionUpload.doUpload(AppVersionUpload.java:
111)
at
com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:
56)
... 4 more

-- 
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] Datastore Delete raises wrong exception

2010-03-18 Thread Don Schwarz
Yes, it seems like we should be able to generate a better error message
here.

Can you file a bug in our issue tracker, please?

http://code.google.com/p/googleappengine/issues/list

Thanks,
Don

On Thu, Mar 18, 2010 at 4:42 PM, Mouseclicker wrote:

> Hi,
>
> I am using the low level datastore API and suspect that there is a bug
> in the current implementation when deleting entities.
>
> If I call delete() with an array of keys and one or more of the keys
> does no longer exist this results in a very strange exception:
>
> com.google.appengine.api.datastore.DatastoreFailureException:
> Unexpected error, please try again
>
> The behavior is also different on the development server. Here I do
> not receive an exception at all.
>
> Getting no meaningful exception makes debugging such issues very hard
> and I suspect that this behavior is a bug. Is this possible?
>
> Here is the full stacktrace:
> Uncaught exception from servlet
> com.google.appengine.api.datastore.DatastoreFailureException:
> Unexpected error, please try again.
>at
>
> com.google.appengine.api.datastore.DatastoreApiHelper.translateError(DatastoreApiHelper.java:
> 46)
>at
>
> com.google.appengine.api.datastore.DatastoreApiHelper.makeSyncCall(DatastoreApiHelper.java:
> 60)
>at com.google.appengine.api.datastore.DatastoreServiceImpl
> $3.run(DatastoreServiceImpl.java:225)
>at
>
> com.google.appengine.api.datastore.TransactionRunner.runInTransaction(TransactionRunner.java:
> 30)
>at
>
> com.google.appengine.api.datastore.DatastoreServiceImpl.delete(DatastoreServiceImpl.java:
> 211)
>at
>
> com.google.appengine.api.datastore.DatastoreServiceImpl.delete(DatastoreServiceImpl.java:
> 197)
>at
>
> org.yodooga.repository.RepositoryAdmin.processDeleteTask(RepositoryAdmin.java:
> 114)
>at org.yodooga.YoDooGAServlet.doPut(YoDooGAServlet.java:144)
>at javax.servlet.http.HttpServlet.service(HttpServlet.java:716)
>at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
>at
> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
> 487)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1093)
>at
>
> com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter(ParseBlobUploadFilter.java:
> 97)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1084)
>at
>
> com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter(SaveSessionFilter.java:
> 35)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1084)
>at
>
> com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
> 43)
>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.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:
> 238)
>at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 139)
>at org.mortbay.jetty.Server.handle(Server.java:313)
>at
> org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
> 506)
>at org.mortbay.jetty.HttpConnection
> $RequestHandler.headerComplete(HttpConnection.java:830)
>at
>
> com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable(RpcRequestParser.java:
> 76)
>at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
>at
>
> com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:
> 135)
>at
> com.google.apphosting.runtime.JavaRuntime.handleRequest(JavaRuntime.java:
> 235)
>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:
> 363)
>at com.google.net.rpc.impl.Server$2.run(Server.java:837)
>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:792)
>at co

Re: [appengine-java] Any way to call Java Compiler directly on GAE ?

2010-03-18 Thread Toby Reyelts
A built-in java compiler is not currently available on GAE, but you might
want to try out some other Java compilers designed for program embedding,
like Janino .

On Thu, Mar 18, 2010 at 10:01 AM, Didier Durand wrote:

> Hi there,
>
> Is there any way to call the java compiler itself in a GAE
> application ?
> I would like to port some Java code generator / compiler from regular
> servers to GAE but the prereq is to be able to compile directly on
> GAE.
>
> I don't  find appropriate call in the JRE white list (http://
> code.google.com/appengine/docs/java/jrewhitelist.html)
>
> thanks
> didier
>
> --
> 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] Datastore Delete raises wrong exception

2010-03-18 Thread Mouseclicker
Hi,

I am using the low level datastore API and suspect that there is a bug
in the current implementation when deleting entities.

If I call delete() with an array of keys and one or more of the keys
does no longer exist this results in a very strange exception:

com.google.appengine.api.datastore.DatastoreFailureException:
Unexpected error, please try again

The behavior is also different on the development server. Here I do
not receive an exception at all.

Getting no meaningful exception makes debugging such issues very hard
and I suspect that this behavior is a bug. Is this possible?

Here is the full stacktrace:
Uncaught exception from servlet
com.google.appengine.api.datastore.DatastoreFailureException:
Unexpected error, please try again.
at
com.google.appengine.api.datastore.DatastoreApiHelper.translateError(DatastoreApiHelper.java:
46)
at
com.google.appengine.api.datastore.DatastoreApiHelper.makeSyncCall(DatastoreApiHelper.java:
60)
at com.google.appengine.api.datastore.DatastoreServiceImpl
$3.run(DatastoreServiceImpl.java:225)
at
com.google.appengine.api.datastore.TransactionRunner.runInTransaction(TransactionRunner.java:
30)
at
com.google.appengine.api.datastore.DatastoreServiceImpl.delete(DatastoreServiceImpl.java:
211)
at
com.google.appengine.api.datastore.DatastoreServiceImpl.delete(DatastoreServiceImpl.java:
197)
at
org.yodooga.repository.RepositoryAdmin.processDeleteTask(RepositoryAdmin.java:
114)
at org.yodooga.YoDooGAServlet.doPut(YoDooGAServlet.java:144)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:716)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
487)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1093)
at
com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter(ParseBlobUploadFilter.java:
97)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter(SaveSessionFilter.java:
35)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
43)
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.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:
238)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
139)
at org.mortbay.jetty.Server.handle(Server.java:313)
at
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
506)
at org.mortbay.jetty.HttpConnection
$RequestHandler.headerComplete(HttpConnection.java:830)
at
com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable(RpcRequestParser.java:
76)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
at
com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:
135)
at
com.google.apphosting.runtime.JavaRuntime.handleRequest(JavaRuntime.java:
235)
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:
363)
at com.google.net.rpc.impl.Server$2.run(Server.java:837)
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:792)
at com.google.net.rpc.impl.Server.processRequest(Server.java:367)
at
com.google.net.rpc.impl.ServerConnection.messageReceived(ServerConnection.java:
448)
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.proces

Re: [appengine-java] Google App Engine error

2010-03-18 Thread Guillermo Schwarz

Svenska?

Saludos,
Guillermo Schwarz.

El 17-03-2010, a las 6:57, Olifant   
escribió:



Ik heb een probleem met de Google App Engine.
Lokaal draait het prima, maar als ik mijn project naar de Google App
Engine server heb gedeployed en het daar wil bekijken, gaat het
verkeerd.

Het gaat om de volgende foutmelding:

/index.jsp
java.lang.ClassCastException: java.lang.String cannot be cast to
java.lang.Boolean
   at
com.google.appengine.runtime.Request.process-45e9281fdbb0acf1 
(Request.java)

   at
org.datanucleus.store.appengine.DatastoreFieldManager.fetchBooleanField( 
DatastoreFieldManager.java:

453)
   at
org.datanucleus.state.AbstractStateManager.replacingBooleanField 
(AbstractStateManager.java:

1052)
   at project.Project.jdoReplaceField(Project.java)
   at project.Project.jdoReplaceFields(Project.java)
   at
org.datanucleus.state.JDOStateManagerImpl.replaceFields 
(JDOStateManagerImpl.java:

2772)
   at
org.datanucleus.state.JDOStateManagerImpl.replaceFields 
(JDOStateManagerImpl.java:

2791)
   at
org.datanucleus.store.appengine.DatastorePersistenceHandler.fetchObject( 
DatastorePersistenceHandler.java:

461)
   at
org.datanucleus.store.appengine.query.DatastoreQuery.entityToPojo 
(DatastoreQuery.java:

545)
   at
org.datanucleus.store.appengine.query.DatastoreQuery.entityToPojo 
(DatastoreQuery.java:

500)
   at org.datanucleus.store.appengine.query.DatastoreQuery.access
$300(DatastoreQuery.java:108)
   at org.datanucleus.store.appengine.query.DatastoreQuery
$6.apply(DatastoreQuery.java:618)
   at org.datanucleus.store.appengine.query.DatastoreQuery
$6.apply(DatastoreQuery.java:610)
   at
org.datanucleus.store.appengine.query.LazyResult.resolveNext 
(LazyResult.java:

94)
   at org.datanucleus.store.appengine.query.LazyResult
$LazyAbstractListIterator.computeNext(LazyResult.java:215)
   at
org.datanucleus.store.appengine.query.AbstractIterator.tryToComputeNext( 
AbstractIterator.java:

132)
   at
org.datanucleus.store.appengine.query.AbstractIterator.hasNext 
(AbstractIterator.java:

127)
   at org.datanucleus.store.appengine.query.LazyResult
$AbstractListIterator.hasNext(LazyResult.java:169)
   at project.GetProject.getProjectsDashboard(GetProject.java:33)
   at org.apache.jsp.index_jsp._jspService(index_jsp.java:52)
   at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java: 
94)

   at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
   at org.mortbay.jetty.servlet.ServletHolder.handle 
(ServletHolder.java:

487)
   at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1093)
   at
cwipstoremoteuserfilter.filter.CwipsToRemoteUserFilter.doFilter 
(CwipsToRemoteUserFilter.java:

78)
   at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
   at cwipsclient.cas.client.filter.CASFilter.doFilter(CASFilter.java:
79)
   at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
   at
com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter 
(ParseBlobUploadFilter.java:

97)
   at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
   at
com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter 
(SaveSessionFilter.java:

35)
   at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
   at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter 
(TransactionCleanupFilter.java:

43)
   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.runtime.jetty.AppVersionHandlerMap.handle 
(AppVersionHandlerMap.java:

238)
   at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
139)
   at org.mortbay.jetty.Server.handle(Server.java:313)
   at org.mortbay.jetty.HttpConnection.handleRequest 
(HttpConnection.java:

506)
   at org.mortbay.jetty.HttpConnection
$RequestHandler.headerComplete(HttpConnection.java:830)
   at
com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable 
(RpcRequestParser.java:

76)
   at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
   at
com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest( 
JettyServletEngineAdapter.java:

135)
   at
com.google.apphosting.runtime.JavaRuntime.handleRequest 
(JavaRuntime.java:

235)
   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
co

[appengine-java] Re: Timeout using GData API

2010-03-18 Thread Alexandru Farcas
i have the same problem ...

in some cases, for some searches I get this error and is very annoying
because I can not increase the timeout ...
It's very urgent to me ... so, if anyone can help me/us to resolve
this "problem"...

On Mar 18, 1:25 pm, Ice13ill  wrote:
> Everybody says that using the setConntectionTimeout() can set the
> maximum timeout to 10 seconds.
> I also tried setting service.setConnectionTimeout() (witch sets the
> timeout for the HttpUrlConnectiion object used to fetch data) but with
> no effect (contrary to what it says 
> here:http://code.google.com/appengine/docs/java/urlfetch/overview.html#Req...).
> I have read somewhere that this pb was fixed in an early release but
> it doesn't appear so.
> Can anyone help ?
>
> On Jan 20, 7:42 am, smile laugh  wrote:
>
>
>
> > I also get same error
>
> > is there someone can help me out

-- 
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: App instance recycling and response times - is there solution?

2010-03-18 Thread François Masurel
Thanx James, it's perfectly summarized !

Direct links to the related issues for starring :

http://code.google.com/p/googleappengine/issues/detail?id=2396
http://code.google.com/p/googleappengine/issues/detail?id=2456

On 18 mar, 18:44, "James Koch"  wrote:
> In my short time using GAE I've seen several issues discussed under the
> label "response times".  The lines between these issues are fuzzy, and we
> aren't all talking about "response times" using the same semantics.  As an
> example, Jake, you might not be seeing frequent restarts, you could also be
> seeing spinup of additional JVMs (even though you're low-traffic like me).
>
> Maybe enumerating them will help us all pull in the same direction?  Here
> are the issues I've seen mentioned:
>
> 1 - Slow JVM startup speed (5-7s for something that uses JDO and no other
> frameworks)
>
> 2 - Not affecting me personally, but startup cost of other frameworks
> (Struts, etc.) has definitely been mentioned.
>
> 3 - Frequent JVM restarts (after 1 min of inactivity) - This interval feels
> too short to me, as a small app developer.
>
> 4 - Frequent "server overload" caused by OTHER apps, which cause a request
> to be re-routed to a new JVM instead of a warm one, thus incurring the
> startup penalty regardless of user activity levels.
>
> 5 - "Request was aborted after waiting too long" on normally fast-loading
> pages.  Presumably similar to #3 (caused by "server overload" from OTHER
> apps) but something else is awry here as these occurs often occur after only
> 10s, not the expected 30s.  If you've got a 7s JVM spinup, that doesn't
> leave you a lot of wiggle room.  Also, this only shows up in logs as a
> "warning".  IMO, if a user can't receive a response, that's an "error".  
>
> Issue tracking:
> #5 covered by Issue #2396.
> #1-4 all munged together in massive Issues #2456
>
> James
>
>
>
> -Original Message-
> From: google-appengine-java@googlegroups.com
>
> [mailto:google-appengine-j...@googlegroups.com] On Behalf Of Jake
> Sent: Thursday, March 18, 2010 12:56 PM
> To: Google App Engine for Java
> Subject: [appengine-java] Re: App instance recycling and response times - is
> there solution?
>
> Hey,
>
> So, I've noticed several users complaining about *frequent* restarts,
> not long restarts.  I created this issue awhile back but no one has
> starred it.  My impression from the Google developers I've talked to
> is that this is not common enough to become a priority.  If you
> disagree, star the issue.
>
> http://code.google.com/p/googleappengine/issues/detail?id=2931
>
> If it truly isn't common, then I'll probably just end up creating
> another account and redeploying since it has been established that my
> application isn't the cause.
>
> Jake
>
> On Mar 17, 11:35 pm, James Koch  wrote:
> > As a followup, today (3/17) from 1-3PM PST I received several
> > instances of "Request
> > was aborted after waiting too long to attempt to service your request."
> This
> > is on my app w/ zero users, just 3 requests/minute of a blank page as a
> test
> > load.
>
> > On Thu, Mar 11, 2010 at 1:50 PM, Don Schwarz  wrote:
> > > Can you respond privately with your app id?
>
> > > On Thu, Mar 11, 2010 at 10:10 AM, James  wrote:
>
> > >> I setup some pings of my add a few minutes ago, and I'm still seeing
> > >> recycling :(
>
> > >> My ping setup can't go lower than 60s intervals, so I have two running
> > >> concurrently.  Here's a sample of 20 log entries over 10 minutes,
> > >> with .  Three recyclings occur, and they happen less than 10s after a
> > >> previous request.  Really Google, you're killing my JVM after TEN
> > >> SECONDS?  And I get to pay you for the ton of CPU each startup uses?
> > >> Sounds like the more recycling, the more profitable the App Engine
> > >> becomes.
>
> > >> -
> > >> * 03-11 08:02AM 38.506 /?Pragma=no-cache 200 2158ms 2235cpu_ms 0kb
> > >> Site 24 X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 08:02AM 23.144 /?Pragma=no-cache 200 53ms 19cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 08:01AM 06.134 /?Pragma=no-cache 200 75ms 19cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 08:00AM 51.707 /?Pragma=no-cache 200 49ms 19cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 08:00AM 05.823 /?Pragma=no-cache 200 49ms 58cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 07:59AM 51.499 /?Pragma=no-cache 200 56ms 38cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 07:59AM 05.584 /?Pragma=no-cache 200 47ms 19cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 07:58AM 51.274 /?Pragma=no-cache 200 61ms 38cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 07:58AM 05.371 /?Pragma=no-cache 200 64ms 19cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> > >>  03-11 07:57AM 51.025 /?Pragma=no-cache 200 74ms 19cpu_ms 0kb Site 24
> > >> X 7 RPT-HTTPClien

Re: [appengine-java] Filter's static variable is lost

2010-03-18 Thread Don Schwarz
Unlike most Java hosting providers, we load and unload your code on JVMs as
your load patterns change.  This will result in static variable static being
lost, and as a result you should only expect durability of data stored in
the datastore.  Transient data should generally be stored in memcache,
although data may be evicted from memcache as well.

For more information, see:

http://code.google.com/appengine/kb/java.html#What_Causes_Loading_Requests

On Thu, Mar 18, 2010 at 9:34 AM, Ali Ok  wrote:

> Hi,
> I am trying to implement Google App Engine support for Myfaces 2. You
> can see the work [1] [2].
> At the moment, I am making some trials to identify the problem at [2].
>
> I am experiencing an interesting problem. My filter's static variable
> is lost after some time(ie. 3 minutes)
> I have a filter like this:
> public class TestFilter implements Filter
> {
> ...
>   private static String myStaticVariable;
>
>   public void doFilter(ServletRequest arg0, ServletResponse arg1,
>FilterChain arg2) throws IOException, ServletException
>{
>log.warning("myStaticVariable" + myStaticVariable);
>if(myStaticVariable==null)
>myStaticVariable = "someValue";
>arg2.doFilter(arg0, arg1);
>}
> ...
> }
>
> When I make the first request, "myStaticVariable" is set to
> "someValue". If I make a request in a short period (ie. 20 seconds), I
> see that value of "myStaticVariable" is still "someValue".
> However, after 3 minutes, when I make another request, I see that
> "myStaticVariable" is set to its default value (null).
>
> Why are my static variables are gone? Am I doing something wrong?
>
> I can understand that the reconstruction of the filter and loss of
> instance variables; we are trying to run our application on cloud.
> But loss of static variables are completely weird.
>
> I couldn't find an issue on Google Code project, thus wanted to ask
> you before opening an issue.
>
> Thanks,
> Ali
>
>
> [1] https://issues.apache.org/jira/browse/MYFACES-2559
> [2] https://issues.apache.org/jira/browse/MYFACES-2606
>
> --
> 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: Is XMPPServiceFactory service down ?

2010-03-18 Thread Rahul
i was able to chat yesterday but when i tried few minutes back its not
working ?

On Mar 18, 4:15 pm, Don Schwarz  wrote:
> Can you respond privately with your app id?
>
>
>
> On Thu, Mar 18, 2010 at 3:12 PM, Rahul  wrote:
> > I am getting the following message again and again.
>
> > Error for /_ah/xmpp/message/chat/
> > java.lang.NoClassDefFoundError: com/google/appengine/api/xmpp/
> > XMPPServiceFactory
> > Caused by: java.lang.ClassNotFoundException:
> > com.google.appengine.api.xmpp.XMPPServiceFactory
> >        at
> > com.google.appengine.runtime.Request.process-82178f5b5feb9148(Request.java)
> >        at java.lang.ClassLoader.loadClass(Unknown Source)
> >        at java.lang.ClassLoader.loadClassInternal(Unknown Source)
>
> > Thanks,
> > Rahul
>
> > --
> > 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 > 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] Any way to call Java Compiler directly on GAE ?

2010-03-18 Thread Didier Durand
Hi there,

Is there any way to call the java compiler itself in a GAE
application ?
I would like to port some Java code generator / compiler from regular
servers to GAE but the prereq is to be able to compile directly on
GAE.

I don't  find appropriate call in the JRE white list (http://
code.google.com/appengine/docs/java/jrewhitelist.html)

thanks
didier

-- 
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] Filter's static variable is lost

2010-03-18 Thread Ali Ok
Hi,
I am trying to implement Google App Engine support for Myfaces 2. You
can see the work [1] [2].
At the moment, I am making some trials to identify the problem at [2].

I am experiencing an interesting problem. My filter's static variable
is lost after some time(ie. 3 minutes)
I have a filter like this:
public class TestFilter implements Filter
{
...
   private static String myStaticVariable;

   public void doFilter(ServletRequest arg0, ServletResponse arg1,
FilterChain arg2) throws IOException, ServletException
{
log.warning("myStaticVariable" + myStaticVariable);
if(myStaticVariable==null)
myStaticVariable = "someValue";
arg2.doFilter(arg0, arg1);
}
...
}

When I make the first request, "myStaticVariable" is set to
"someValue". If I make a request in a short period (ie. 20 seconds), I
see that value of "myStaticVariable" is still "someValue".
However, after 3 minutes, when I make another request, I see that
"myStaticVariable" is set to its default value (null).

Why are my static variables are gone? Am I doing something wrong?

I can understand that the reconstruction of the filter and loss of
instance variables; we are trying to run our application on cloud.
But loss of static variables are completely weird.

I couldn't find an issue on Google Code project, thus wanted to ask
you before opening an issue.

Thanks,
Ali


[1] https://issues.apache.org/jira/browse/MYFACES-2559
[2] https://issues.apache.org/jira/browse/MYFACES-2606

-- 
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 to properly persist an unowned object?

2010-03-18 Thread Mark
Hi,

I'm not understanding how to implement a simple unowned relationship.
I have two classes like:

  class Farm {
List mHorses;
  }

  class Horse {
@PrimaryKey
Key mKey;
  }

so a Farm can have some horses. I'd like to create a new horse, then
put it on a farm, in one transaction. But how do I know the key of the
horse during the transaction?:

  Farm farm = loadFarm(...);
  Horse horse = new Horse();
  horse.setName("Roger");
  try {
tx = pm.currentTransaction();
tx.begin();
pm.makePersistent(horse); // is the key available now?
farm.mHorses.add(horse.mKey);
pm.makePersistent(farm);
tx.commit();
  }

when is the Horse.mKey value actually set and ready for use? Or do I
have to do this as two separate atomic operations:

  1) Save the horse which generates its mKey value.
  2) If that worked, add it to the farm, persist the farm again.
  3) If that worked, all good, if not, have to delete the horse cause
now it's in limbo?

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] Can i upload a typical WAR file

2010-03-18 Thread suneesh
Can a typical WAR file used in tomcat be uploaded and used?

-- 
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: Ant with GWT 2.0

2010-03-18 Thread vbart
Read this - search for "devmode":
http://code.google.com/webtoolkit/doc/latest/tutorial/appengine.html

It works fine for me.

Vaclav


On Mar 17, 5:40 pm, Iqbal Yusuf Dipu  wrote:
> Hi
>
> Is it possible to use Ant to run development server for GWT 2.0? Is
> there any tutorial available?
>
> Thanks.
>
> Iqbal

-- 
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] Dyskusja na temat will-it-play-in-app-engine

2010-03-18 Thread MS
There is an excellent framework that suites GAE very well.
Play (playframework.org).
Probably the fastest framework for Gogle App Engine.
Works with Siena persistence framework (sienaproject.com) out of the
box.

-- 
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: Geospatial data management with GAE Java

2010-03-18 Thread Rahul Ravikumar
There is a java port of the Geomodel project in java which you can try
out.

On Mar 17, 1:39 am, fvisticot  wrote:
> I know that Geomodel is a solution for python users to manage
> geospatial information.
> What is available for GAE Java users in term of Geospatial data
> management ?
>
> What is the best solution ?
> Is there a native approach provided by GAE Java ?
>
> In case no solution is available, what are the workarrounds ? Is
> Google Maps Data Api the solution ?
>
> Fred.

-- 
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 to query datetime with persist?

2010-03-18 Thread jkubosc...@googlemail.com
I've got the following code:

PersistenceManager pm = PMF.get().getPersistenceManager();

query = "select from " + Email.class.getName() + " where groupName ==
'" + group + "' && date_sent >= "+fromStr+" && date_sent <= "+toStr
+"";

List emails = (List) pm.newQuery(query).execute();

messageSent = emails.size();

pm.close();


What I want to do is simply return all messages between fromStr and
toStr.

I've tried stuff like String fromStr = "DATETIME('1900-01-01
00:00:00')"; but I get an error message with that:

Uncaught exception from servlet
org.datanucleus.store.appengine.query.DatastoreQuery
$UnsupportedDatastoreFeatureException: Problem with query =
DATETIME('1900-01-01 00:00:00') && date_sent <= DATETIME('2011-01-01
00:00:00')>: Unsupported method  while parsing expression:
InvokeExpression{[null].DATETIME(Literal{1900-01-01 00:00:00})}
[.]

I've tried just '1900-01-01 00:00:00' but that didn't work either.
I've I build a query by hand near the dashboard on the webinterface, I
can use datetime just fine. I'm out of ideas. Help?

-- 
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] Suddenly getting "Unknown attribute type (com.google.appengine.api.datastore.Key) for attribute key."

2010-03-18 Thread Steve
Hi,
I've been successfully building my project each day.  Today I come to
it and attempt to start it in the debugger when I get the above
error.  Here is some of the stack trace:

org.apache.jasper.JasperException: /kickboxking.jsp(23,28) Unknown
attribute type (com.google.appengine.api.datastore.Key) for attribute
key.
at
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:
39)
at
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:
409)
at
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:
238)
at org.apache.jasper.compiler.Validator
$ValidateVisitor.checkXmlAttributes(Validator.java:932)
at org.apache.jasper.compiler.Validator
$ValidateVisitor.visit(Validator.java:696)
at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1441)
at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2213)
at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
at org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
at org.apache.jasper.compiler.Validator.validate(Validator.java:1475)
at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:
214)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:470)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:
511)
...


So, it's when compiling the JSP.  I don't know if it's when resolving
the tag or the jsp that it encounters this "unknown", but no matter -
neither has been changed(!) since it was compiling just fine.  Also, I
can see the appengine-api jar on the build path (as it was from when
the project was setup under Eclipse).

Here's an extract from the JSP:

<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page import="java.util.List" %>
<%@ page import="com.google.appengine.api.users.User" %>
<%@ page import="com.google.appengine.api.users.UserService" %>
<%@ page import="com.google.appengine.api.users.UserServiceFactory" %>
<%@ page import="com.google.appengine.api.datastore.Key" %>

<%@ taglib uri="/WEB-INF/kickboxking.tld" prefix="kbk" %>


  

<%
UserService userService = UserServiceFactory.getUserService();
if (session.getAttribute("activePlayerId") != null) {
%>
"/>! (You can
sign out.)

...

It's falling over on that  tag   Pure bit-rot
as it was fine when I was running it yesterday :-(

Steve

-- 
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] Google App Engine error

2010-03-18 Thread Olifant
Ik heb een probleem met de Google App Engine.
Lokaal draait het prima, maar als ik mijn project naar de Google App
Engine server heb gedeployed en het daar wil bekijken, gaat het
verkeerd.

Het gaat om de volgende foutmelding:

/index.jsp
java.lang.ClassCastException: java.lang.String cannot be cast to
java.lang.Boolean
at
com.google.appengine.runtime.Request.process-45e9281fdbb0acf1(Request.java)
at
org.datanucleus.store.appengine.DatastoreFieldManager.fetchBooleanField(DatastoreFieldManager.java:
453)
at
org.datanucleus.state.AbstractStateManager.replacingBooleanField(AbstractStateManager.java:
1052)
at project.Project.jdoReplaceField(Project.java)
at project.Project.jdoReplaceFields(Project.java)
at
org.datanucleus.state.JDOStateManagerImpl.replaceFields(JDOStateManagerImpl.java:
2772)
at
org.datanucleus.state.JDOStateManagerImpl.replaceFields(JDOStateManagerImpl.java:
2791)
at
org.datanucleus.store.appengine.DatastorePersistenceHandler.fetchObject(DatastorePersistenceHandler.java:
461)
at
org.datanucleus.store.appengine.query.DatastoreQuery.entityToPojo(DatastoreQuery.java:
545)
at
org.datanucleus.store.appengine.query.DatastoreQuery.entityToPojo(DatastoreQuery.java:
500)
at org.datanucleus.store.appengine.query.DatastoreQuery.access
$300(DatastoreQuery.java:108)
at org.datanucleus.store.appengine.query.DatastoreQuery
$6.apply(DatastoreQuery.java:618)
at org.datanucleus.store.appengine.query.DatastoreQuery
$6.apply(DatastoreQuery.java:610)
at
org.datanucleus.store.appengine.query.LazyResult.resolveNext(LazyResult.java:
94)
at org.datanucleus.store.appengine.query.LazyResult
$LazyAbstractListIterator.computeNext(LazyResult.java:215)
at
org.datanucleus.store.appengine.query.AbstractIterator.tryToComputeNext(AbstractIterator.java:
132)
at
org.datanucleus.store.appengine.query.AbstractIterator.hasNext(AbstractIterator.java:
127)
at org.datanucleus.store.appengine.query.LazyResult
$AbstractListIterator.hasNext(LazyResult.java:169)
at project.GetProject.getProjectsDashboard(GetProject.java:33)
at org.apache.jsp.index_jsp._jspService(index_jsp.java:52)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
487)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1093)
at
cwipstoremoteuserfilter.filter.CwipsToRemoteUserFilter.doFilter(CwipsToRemoteUserFilter.java:
78)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at cwipsclient.cas.client.filter.CASFilter.doFilter(CASFilter.java:
79)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter(ParseBlobUploadFilter.java:
97)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter(SaveSessionFilter.java:
35)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
43)
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.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:
238)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
139)
at org.mortbay.jetty.Server.handle(Server.java:313)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
506)
at org.mortbay.jetty.HttpConnection
$RequestHandler.headerComplete(HttpConnection.java:830)
at
com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable(RpcRequestParser.java:
76)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
at
com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:
135)
at
com.google.apphosting.runtime.JavaRuntime.handleRequest(JavaRuntime.java:
235)
at com.google.apphosting.base.RuntimePb$EvaluationRuntime
$6.handleBlockingRequest(RuntimePb.java:5485)
at com.google.apphosting.

Re: [appengine-java] Is XMPPServiceFactory service down ?

2010-03-18 Thread Don Schwarz
Can you respond privately with your app id?

On Thu, Mar 18, 2010 at 3:12 PM, Rahul  wrote:

> I am getting the following message again and again.
>
> Error for /_ah/xmpp/message/chat/
> java.lang.NoClassDefFoundError: com/google/appengine/api/xmpp/
> XMPPServiceFactory
> Caused by: java.lang.ClassNotFoundException:
> com.google.appengine.api.xmpp.XMPPServiceFactory
>at
> com.google.appengine.runtime.Request.process-82178f5b5feb9148(Request.java)
>at java.lang.ClassLoader.loadClass(Unknown Source)
>at java.lang.ClassLoader.loadClassInternal(Unknown Source)
>
> Thanks,
> Rahul
>
> --
> 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] Is XMPPServiceFactory service down ?

2010-03-18 Thread Rahul
I am getting the following message again and again.

Error for /_ah/xmpp/message/chat/
java.lang.NoClassDefFoundError: com/google/appengine/api/xmpp/
XMPPServiceFactory
Caused by: java.lang.ClassNotFoundException:
com.google.appengine.api.xmpp.XMPPServiceFactory
at
com.google.appengine.runtime.Request.process-82178f5b5feb9148(Request.java)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)

Thanks,
Rahul

-- 
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] Discussion on will-it-play-in-app-engine

2010-03-18 Thread luijar
Any idea what components of JEE6 are supported?

-- 
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: java.io.IOException: Could not fetch URL problem and google spreadsheet api

2010-03-18 Thread Rahul
Any body got any clues on this ?



On Mar 17, 12:44 pm, Rahul  wrote:
> I am trying to open a connection to the following service 
> :http://translate.thoughtclicks.com/translateService/german/good
> morning which is definitely taking less then 5 seconds but i am still
> getting this exception any clue on this folks.
>
> My code to open the url connection is as follows.
>
>             URL url = new URL(THIS_IS_THE_URL_MENTIONED_ABOVE);
>             //make connection, use post mode, and send query
>             URLConnection urlc = url.openConnection();
>             urlc.setDoOutput(true);
>             //retrieve result
>             BufferedReader br = new BufferedReader(new
> InputStreamReader(urlc.getInputStream()));
>
> Any Clues on this folks ?
>
> Thanks,
> Rahul
>
> On Mar 17, 12:27 pm, Rahul  wrote:
>
>
>
> > Did you find the solution for this as i am having the problem ?
> > Any help appreciated.
>
> > Thanks,
> > Rahul
>
> > On Mar 16, 10:31 am, dominity  wrote:
>
> > > Hi, guys.
>
> > > When my application trying to put user credentials into spreadsheet
> > > service, I've got this exception:
>
> > > com.google.gdata.util.AuthenticationException: Error connecting with
> > > login URI
> > >         at
> > > com.google.gdata.client.GoogleAuthTokenFactory.getAuthToken(GoogleAuthToken
> > >  Factory.java:
> > > 479)
> > >         at
> > > com.google.gdata.client.GoogleAuthTokenFactory.setUserCredentials(GoogleAut
> > >  hTokenFactory.java:
> > > 336)
> > >         at
> > > com.google.gdata.client.GoogleService.setUserCredentials(GoogleService.java
> > >  :
> > > 362)
> > >         at
> > > com.google.gdata.client.GoogleService.setUserCredentials(GoogleService.java
> > >  :
> > > 317)
> > >         at
> > > com.google.gdata.client.GoogleService.setUserCredentials(GoogleService.java
> > >  :
> > > 301)
> > > Caused by: java.io.IOException: Could not fetch 
> > > URL:https://www.google.com/accounts/ClientLogin
> > >         at
> > > com.google.appengine.api.urlfetch.URLFetchServiceImpl.convertApplicationExc
> > >  eption(URLFetchServiceImpl.java:
> > > 106)
> > >         at
> > > com.google.appengine.api.urlfetch.URLFetchServiceImpl.fetch(URLFetchService
> > >  Impl.java:
> > > 39)
> > >         at
> > > com.google.apphosting.utils.security.urlfetch.URLFetchServiceStreamHandler
> > > $Connection.fetchResponse(URLFetchServiceStreamHandler.java:404)
> > >         at
> > > com.google.apphosting.utils.security.urlfetch.URLFetchServiceStreamHandler
> > > $Connection.getInputStream(URLFetchServiceStreamHandler.java:283)
> > >         at
> > > com.google.apphosting.utils.security.urlfetch.URLFetchServiceStreamHandler
> > > $Connection.getResponseCode(URLFetchServiceStreamHandler.java:136)
> > >         at
> > > com.google.gdata.client.GoogleAuthTokenFactory.makePostRequest(GoogleAuthTo
> > >  kenFactory.java:
> > > 550)
> > >         at
> > > com.google.gdata.client.GoogleAuthTokenFactory.getAuthToken(GoogleAuthToken
> > >  Factory.java:
> > > 477)
>
> > > I'm using Eclipse Plug-In and GAE SDK v1.3.1. Also, I was trying my
> > > code with version 1.3.0 and 1.2.9. And I can tell you that this
> > > happens only with development server, error disappears on production
> > > server. That's point - I can't even do any debugging stuff. So, could
> > > you give me any feedback on this issue?
>
> > > Best regards, Alexander.

-- 
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: App instance recycling and response times - is there solution?

2010-03-18 Thread James Koch
In my short time using GAE I've seen several issues discussed under the
label "response times".  The lines between these issues are fuzzy, and we
aren't all talking about "response times" using the same semantics.  As an
example, Jake, you might not be seeing frequent restarts, you could also be
seeing spinup of additional JVMs (even though you're low-traffic like me).

Maybe enumerating them will help us all pull in the same direction?  Here
are the issues I've seen mentioned:

1 - Slow JVM startup speed (5-7s for something that uses JDO and no other
frameworks)

2 - Not affecting me personally, but startup cost of other frameworks
(Struts, etc.) has definitely been mentioned.

3 - Frequent JVM restarts (after 1 min of inactivity) - This interval feels
too short to me, as a small app developer.

4 - Frequent "server overload" caused by OTHER apps, which cause a request
to be re-routed to a new JVM instead of a warm one, thus incurring the
startup penalty regardless of user activity levels.

5 - "Request was aborted after waiting too long" on normally fast-loading
pages.  Presumably similar to #3 (caused by "server overload" from OTHER
apps) but something else is awry here as these occurs often occur after only
10s, not the expected 30s.  If you've got a 7s JVM spinup, that doesn't
leave you a lot of wiggle room.  Also, this only shows up in logs as a
"warning".  IMO, if a user can't receive a response, that's an "error".  

Issue tracking:
#5 covered by Issue #2396.
#1-4 all munged together in massive Issues #2456




James







-Original Message-
From: google-appengine-java@googlegroups.com
[mailto:google-appengine-j...@googlegroups.com] On Behalf Of Jake
Sent: Thursday, March 18, 2010 12:56 PM
To: Google App Engine for Java
Subject: [appengine-java] Re: App instance recycling and response times - is
there solution?

Hey,

So, I've noticed several users complaining about *frequent* restarts,
not long restarts.  I created this issue awhile back but no one has
starred it.  My impression from the Google developers I've talked to
is that this is not common enough to become a priority.  If you
disagree, star the issue.

http://code.google.com/p/googleappengine/issues/detail?id=2931

If it truly isn't common, then I'll probably just end up creating
another account and redeploying since it has been established that my
application isn't the cause.

Jake

On Mar 17, 11:35 pm, James Koch  wrote:
> As a followup, today (3/17) from 1-3PM PST I received several
> instances of "Request
> was aborted after waiting too long to attempt to service your request."
This
> is on my app w/ zero users, just 3 requests/minute of a blank page as a
test
> load.
>
> On Thu, Mar 11, 2010 at 1:50 PM, Don Schwarz  wrote:
> > Can you respond privately with your app id?
>
> > On Thu, Mar 11, 2010 at 10:10 AM, James  wrote:
>
> >> I setup some pings of my add a few minutes ago, and I'm still seeing
> >> recycling :(
>
> >> My ping setup can't go lower than 60s intervals, so I have two running
> >> concurrently.  Here's a sample of 20 log entries over 10 minutes,
> >> with .  Three recyclings occur, and they happen less than 10s after a
> >> previous request.  Really Google, you're killing my JVM after TEN
> >> SECONDS?  And I get to pay you for the ton of CPU each startup uses?
> >> Sounds like the more recycling, the more profitable the App Engine
> >> becomes.
>
> >> -
> >> * 03-11 08:02AM 38.506 /?Pragma=no-cache 200 2158ms 2235cpu_ms 0kb
> >> Site 24 X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:02AM 23.144 /?Pragma=no-cache 200 53ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:01AM 06.134 /?Pragma=no-cache 200 75ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:00AM 51.707 /?Pragma=no-cache 200 49ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:00AM 05.823 /?Pragma=no-cache 200 49ms 58cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:59AM 51.499 /?Pragma=no-cache 200 56ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:59AM 05.584 /?Pragma=no-cache 200 47ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:58AM 51.274 /?Pragma=no-cache 200 61ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:58AM 05.371 /?Pragma=no-cache 200 64ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:57AM 51.025 /?Pragma=no-cache 200 74ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >> * 03-11 07:56AM 57.327 /?Pragma=no-cache 200 7835ms 2119cpu_ms 0kb
> >> Site 24 X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:56AM 50.784 /?Pragma=no-cache 200 75ms 58cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:55AM 57.008 /?Pragma=no-cache 200 50ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >> * 03-11 07:55AM 46.384 /?Pragma=no-cache 200 4250ms 2060cpu_ms 0

Re: [appengine-java] Re: Why do custom indexes require single-property indexes?

2010-03-18 Thread Tristan Slominski
Thanks :)

On Thu, Mar 18, 2010 at 11:55 AM, Jeff Schnitzer wrote:

> Here's a link:
>
> http://groups.google.com/group/google-appengine/browse_thread/thread/2f6aa695a80fd5de
>
> Jeff
>
> On Thu, Mar 18, 2010 at 9:22 AM, Tristan 
> wrote:
> > Jeff,
> >
> > Sounds to me like you're correct in the "not only don't set single-
> > property indexes, but also don't include the property in any custom
> > indexes" interpretation of setUnindexedProperty. Can you post the link
> > to the continuation post? I'm curious what Googlers have to say about
> > it.
> >
> > Tristan
> >
> >
> >
> > On Mar 18, 11:13 am, Jeff Schnitzer  wrote:
> >> This doesn't make sense to me.
> >>
> >> Every scrap of documentation I've found says that GAE queries only
> >> follow a single index (the one exception being zigzag merges, which
> >> don't apply here).  This means that to answer my query.filter(foo,
> >> "fooValue1").sort("-bar"), there must be an index that contains the
> >> foo and bar data sorted appropriately, no?  Ie:
> >>
> >> /Thing/foo:fooValue1/bar:bar9/[thekeyvalue]
> >> /Thing/foo:fooValue1/bar:bar8/[thekeyvalue]
> >> /Thing/foo:fooValue1/bar:bar7/[thekeyvalue]
> >> /Thing/foo:fooValue2/bar:bar8/[thekeyvalue]
> >> /Thing/foo:fooValue2/bar:bar7/[thekeyvalue]
> >>
> >> To satisfy this query, GAE should start following this custom index
> >> and that's pretty much it.  There's no reason for it to touch the
> >> single-property indexes (foo ASC, foo DESC, bar ASC, and bar DESC).
> >>
> >> ...and in my test, if I remove the custom index from
> >> datastore-indexes.xml, it doesn't work.  But also if I use
> >> setUnindexedProperty, it doesn't work.
> >>
> >> It's like setUnindexedProperty is being interpreted as "not only don't
> >> set single-property indexes, but also don't include the property in
> >> any custom indexes".  This is counterintuitive - if I wanted the index
> >> not to be built, I can just remove the index.
> >>
> >> I realize now that perhaps I posted this to the wrong mailing list.
> >> The guys who created the I/O videos about the datastore seem to be
> >> python fans, so I'll retry my original post on the google-appengine
> >> list.
> >>
> >> Jeff
> >>
> >>
> >>
> >> On Thu, Mar 18, 2010 at 8:00 AM, Tristan 
> wrote:
> >> > Not official but been doing this for a while.
> >>
> >> > Your custom index is most likely build from the query. So, when you
> >> > do
> >>
> >> >Query query = new Query("Thing");
> >> >query.addFilter("foo", FilterOperator.EQUAL, "fooValue");
> >> >query.addSort("bar", SortDirection.DESCENDING);
> >>
> >> > That is what builds your custom index.
> >>
> >> > However, when you setUnindexedProperty here
> >>
> >> >Entity ent = new Entity("Thing");
> >> >ent.setUnindexedProperty("foo", "fooValue");
> >> >ent.setUnindexedProperty("bar", 123L);
> >>
> >> > You are not generating any index entries.
> >>
> >> > So the issue isn't that "adding custom indexes after-the-fact [is]
> >> > really, really painful" but that you are not generating any indexes
> >> > for the datastore to run the queries against when you use
> >> > setUnindexedProperty(). In other words, when you execute a query, it
> >> > checks the index to give you results. But you marked your data as
> >> > "don't index me," so there is nothing for query to work with, as far
> >> > as it is concerned, there's nothing in the datastore.
> >>
> >> > Cheers!
> >>
> >> > On Mar 16, 4:07 pm, Jeff Schnitzer  wrote:
> >> >> On Mon, Mar 15, 2010 at 11:04 PM, John Patterson <
> jdpatter...@gmail.com> wrote:
> >>
> >> >> > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
> >>
> >> >> >> I'm puzzled by the behavior of custom indexes.  I have a simple
> test
> >> >> >> case below, a simple equality filter on one property combined with
> a
> >> >> >> descending sort on another property.  If I set the properties with
> >> >> >> setUnindexedProperty(), the query fails to find the result.  If I
> set
> >> >> >> the properties with setProperty(), it does.
> >>
> >> >> > I also wondered why - I assume that the custom index build reads
> the single
> >> >> > property indexes directly which must be more efficient than reading
> the
> >> >> > Entities "table".
> >>
> >> >> I guess that is possible, but seems like a poor design decision.  It
> >> >> makes adding custom indexes after-the-fact really, really painful.
> >>
> >> >> Can someone official chime in on this?  Is it intended behavior, or
> >> >> should we file an issue against it?  The documentation doesn't say
> >> >> much on the subject, and all the conceptual explanation of queries
> >> >> suggests that these extra single-property indexes will be unused.
> >>
> >> >> Jeff
> >>
> >> > --
> >> > 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

Re: [appengine-java] Re: Why do custom indexes require single-property indexes?

2010-03-18 Thread Jeff Schnitzer
Here's a link:
http://groups.google.com/group/google-appengine/browse_thread/thread/2f6aa695a80fd5de

Jeff

On Thu, Mar 18, 2010 at 9:22 AM, Tristan  wrote:
> Jeff,
>
> Sounds to me like you're correct in the "not only don't set single-
> property indexes, but also don't include the property in any custom
> indexes" interpretation of setUnindexedProperty. Can you post the link
> to the continuation post? I'm curious what Googlers have to say about
> it.
>
> Tristan
>
>
>
> On Mar 18, 11:13 am, Jeff Schnitzer  wrote:
>> This doesn't make sense to me.
>>
>> Every scrap of documentation I've found says that GAE queries only
>> follow a single index (the one exception being zigzag merges, which
>> don't apply here).  This means that to answer my query.filter(foo,
>> "fooValue1").sort("-bar"), there must be an index that contains the
>> foo and bar data sorted appropriately, no?  Ie:
>>
>> /Thing/foo:fooValue1/bar:bar9/[thekeyvalue]
>> /Thing/foo:fooValue1/bar:bar8/[thekeyvalue]
>> /Thing/foo:fooValue1/bar:bar7/[thekeyvalue]
>> /Thing/foo:fooValue2/bar:bar8/[thekeyvalue]
>> /Thing/foo:fooValue2/bar:bar7/[thekeyvalue]
>>
>> To satisfy this query, GAE should start following this custom index
>> and that's pretty much it.  There's no reason for it to touch the
>> single-property indexes (foo ASC, foo DESC, bar ASC, and bar DESC).
>>
>> ...and in my test, if I remove the custom index from
>> datastore-indexes.xml, it doesn't work.  But also if I use
>> setUnindexedProperty, it doesn't work.
>>
>> It's like setUnindexedProperty is being interpreted as "not only don't
>> set single-property indexes, but also don't include the property in
>> any custom indexes".  This is counterintuitive - if I wanted the index
>> not to be built, I can just remove the index.
>>
>> I realize now that perhaps I posted this to the wrong mailing list.
>> The guys who created the I/O videos about the datastore seem to be
>> python fans, so I'll retry my original post on the google-appengine
>> list.
>>
>> Jeff
>>
>>
>>
>> On Thu, Mar 18, 2010 at 8:00 AM, Tristan  wrote:
>> > Not official but been doing this for a while.
>>
>> > Your custom index is most likely build from the query. So, when you
>> > do
>>
>> >        Query query = new Query("Thing");
>> >        query.addFilter("foo", FilterOperator.EQUAL, "fooValue");
>> >        query.addSort("bar", SortDirection.DESCENDING);
>>
>> > That is what builds your custom index.
>>
>> > However, when you setUnindexedProperty here
>>
>> >        Entity ent = new Entity("Thing");
>> >        ent.setUnindexedProperty("foo", "fooValue");
>> >        ent.setUnindexedProperty("bar", 123L);
>>
>> > You are not generating any index entries.
>>
>> > So the issue isn't that "adding custom indexes after-the-fact [is]
>> > really, really painful" but that you are not generating any indexes
>> > for the datastore to run the queries against when you use
>> > setUnindexedProperty(). In other words, when you execute a query, it
>> > checks the index to give you results. But you marked your data as
>> > "don't index me," so there is nothing for query to work with, as far
>> > as it is concerned, there's nothing in the datastore.
>>
>> > Cheers!
>>
>> > On Mar 16, 4:07 pm, Jeff Schnitzer  wrote:
>> >> On Mon, Mar 15, 2010 at 11:04 PM, John Patterson  
>> >> wrote:
>>
>> >> > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
>>
>> >> >> I'm puzzled by the behavior of custom indexes.  I have a simple test
>> >> >> case below, a simple equality filter on one property combined with a
>> >> >> descending sort on another property.  If I set the properties with
>> >> >> setUnindexedProperty(), the query fails to find the result.  If I set
>> >> >> the properties with setProperty(), it does.
>>
>> >> > I also wondered why - I assume that the custom index build reads the 
>> >> > single
>> >> > property indexes directly which must be more efficient than reading the
>> >> > Entities "table".
>>
>> >> I guess that is possible, but seems like a poor design decision.  It
>> >> makes adding custom indexes after-the-fact really, really painful.
>>
>> >> Can someone official chime in on this?  Is it intended behavior, or
>> >> should we file an issue against it?  The documentation doesn't say
>> >> much on the subject, and all the conceptual explanation of queries
>> >> suggests that these extra single-property indexes will be unused.
>>
>> >> Jeff
>>
>> > --
>> > 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 
>> > 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 em

[appengine-java] Re: App instance recycling and response times - is there solution?

2010-03-18 Thread Jake
Hey,

So, I've noticed several users complaining about *frequent* restarts,
not long restarts.  I created this issue awhile back but no one has
starred it.  My impression from the Google developers I've talked to
is that this is not common enough to become a priority.  If you
disagree, star the issue.

http://code.google.com/p/googleappengine/issues/detail?id=2931

If it truly isn't common, then I'll probably just end up creating
another account and redeploying since it has been established that my
application isn't the cause.

Jake

On Mar 17, 11:35 pm, James Koch  wrote:
> As a followup, today (3/17) from 1-3PM PST I received several
> instances of "Request
> was aborted after waiting too long to attempt to service your request." This
> is on my app w/ zero users, just 3 requests/minute of a blank page as a test
> load.
>
> On Thu, Mar 11, 2010 at 1:50 PM, Don Schwarz  wrote:
> > Can you respond privately with your app id?
>
> > On Thu, Mar 11, 2010 at 10:10 AM, James  wrote:
>
> >> I setup some pings of my add a few minutes ago, and I'm still seeing
> >> recycling :(
>
> >> My ping setup can't go lower than 60s intervals, so I have two running
> >> concurrently.  Here's a sample of 20 log entries over 10 minutes,
> >> with .  Three recyclings occur, and they happen less than 10s after a
> >> previous request.  Really Google, you're killing my JVM after TEN
> >> SECONDS?  And I get to pay you for the ton of CPU each startup uses?
> >> Sounds like the more recycling, the more profitable the App Engine
> >> becomes.
>
> >> -
> >> * 03-11 08:02AM 38.506 /?Pragma=no-cache 200 2158ms 2235cpu_ms 0kb
> >> Site 24 X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:02AM 23.144 /?Pragma=no-cache 200 53ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:01AM 06.134 /?Pragma=no-cache 200 75ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:00AM 51.707 /?Pragma=no-cache 200 49ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 08:00AM 05.823 /?Pragma=no-cache 200 49ms 58cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:59AM 51.499 /?Pragma=no-cache 200 56ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:59AM 05.584 /?Pragma=no-cache 200 47ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:58AM 51.274 /?Pragma=no-cache 200 61ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:58AM 05.371 /?Pragma=no-cache 200 64ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:57AM 51.025 /?Pragma=no-cache 200 74ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >> * 03-11 07:56AM 57.327 /?Pragma=no-cache 200 7835ms 2119cpu_ms 0kb
> >> Site 24 X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:56AM 50.784 /?Pragma=no-cache 200 75ms 58cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:55AM 57.008 /?Pragma=no-cache 200 50ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >> * 03-11 07:55AM 46.384 /?Pragma=no-cache 200 4250ms 2060cpu_ms 0kb
> >> Site 24 X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:54AM 56.782 /?Pragma=no-cache 200 70ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:54AM 46.157 /?Pragma=no-cache 200 54ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:53AM 56.586 /?Pragma=no-cache 200 52ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:53AM 45.934 /?Pragma=no-cache 200 51ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:52AM 56.240 /?Pragma=no-cache 200 62ms 38cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >>  03-11 07:52AM 45.718 /?Pragma=no-cache 200 57ms 19cpu_ms 0kb Site 24
> >> X 7 RPT-HTTPClient/0.3-3E,gzip(gfe)
> >> -
>
> >> On Jan 30, 11:02 pm, Alyxandor 
> >> wrote:
> >> > If you are experiencing failed requests on your long-running /
> >> > requests, consider performing some kind of "pre-warming" procedure of
> >> > your own...  If you are getting timeout errors, Ping a do-nothing url,
> >> > and wait for it to return before running the big job.  If it's a big
> >> > job, users should expect to wait anyway {and you should tell them they
> >> > are waiting!}, so the ping ensures {almost} that a warm JVM is running
> >> > in the server nearest said users, and then the big /request can
> >> > {usually} avoid getting killed with extra spin up time.  Very unlucky
> >> > users would get a /ping on an old JVM, and /request a new one, but...
> >> > Technology isn't perfect...  YET!
>
> >> --
> >> 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
> >> .
>

[appengine-java] Re: Why do custom indexes require single-property indexes?

2010-03-18 Thread Tristan
Jeff,

Sounds to me like you're correct in the "not only don't set single-
property indexes, but also don't include the property in any custom
indexes" interpretation of setUnindexedProperty. Can you post the link
to the continuation post? I'm curious what Googlers have to say about
it.

Tristan



On Mar 18, 11:13 am, Jeff Schnitzer  wrote:
> This doesn't make sense to me.
>
> Every scrap of documentation I've found says that GAE queries only
> follow a single index (the one exception being zigzag merges, which
> don't apply here).  This means that to answer my query.filter(foo,
> "fooValue1").sort("-bar"), there must be an index that contains the
> foo and bar data sorted appropriately, no?  Ie:
>
> /Thing/foo:fooValue1/bar:bar9/[thekeyvalue]
> /Thing/foo:fooValue1/bar:bar8/[thekeyvalue]
> /Thing/foo:fooValue1/bar:bar7/[thekeyvalue]
> /Thing/foo:fooValue2/bar:bar8/[thekeyvalue]
> /Thing/foo:fooValue2/bar:bar7/[thekeyvalue]
>
> To satisfy this query, GAE should start following this custom index
> and that's pretty much it.  There's no reason for it to touch the
> single-property indexes (foo ASC, foo DESC, bar ASC, and bar DESC).
>
> ...and in my test, if I remove the custom index from
> datastore-indexes.xml, it doesn't work.  But also if I use
> setUnindexedProperty, it doesn't work.
>
> It's like setUnindexedProperty is being interpreted as "not only don't
> set single-property indexes, but also don't include the property in
> any custom indexes".  This is counterintuitive - if I wanted the index
> not to be built, I can just remove the index.
>
> I realize now that perhaps I posted this to the wrong mailing list.
> The guys who created the I/O videos about the datastore seem to be
> python fans, so I'll retry my original post on the google-appengine
> list.
>
> Jeff
>
>
>
> On Thu, Mar 18, 2010 at 8:00 AM, Tristan  wrote:
> > Not official but been doing this for a while.
>
> > Your custom index is most likely build from the query. So, when you
> > do
>
> >        Query query = new Query("Thing");
> >        query.addFilter("foo", FilterOperator.EQUAL, "fooValue");
> >        query.addSort("bar", SortDirection.DESCENDING);
>
> > That is what builds your custom index.
>
> > However, when you setUnindexedProperty here
>
> >        Entity ent = new Entity("Thing");
> >        ent.setUnindexedProperty("foo", "fooValue");
> >        ent.setUnindexedProperty("bar", 123L);
>
> > You are not generating any index entries.
>
> > So the issue isn't that "adding custom indexes after-the-fact [is]
> > really, really painful" but that you are not generating any indexes
> > for the datastore to run the queries against when you use
> > setUnindexedProperty(). In other words, when you execute a query, it
> > checks the index to give you results. But you marked your data as
> > "don't index me," so there is nothing for query to work with, as far
> > as it is concerned, there's nothing in the datastore.
>
> > Cheers!
>
> > On Mar 16, 4:07 pm, Jeff Schnitzer  wrote:
> >> On Mon, Mar 15, 2010 at 11:04 PM, John Patterson  
> >> wrote:
>
> >> > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
>
> >> >> I'm puzzled by the behavior of custom indexes.  I have a simple test
> >> >> case below, a simple equality filter on one property combined with a
> >> >> descending sort on another property.  If I set the properties with
> >> >> setUnindexedProperty(), the query fails to find the result.  If I set
> >> >> the properties with setProperty(), it does.
>
> >> > I also wondered why - I assume that the custom index build reads the 
> >> > single
> >> > property indexes directly which must be more efficient than reading the
> >> > Entities "table".
>
> >> I guess that is possible, but seems like a poor design decision.  It
> >> makes adding custom indexes after-the-fact really, really painful.
>
> >> Can someone official chime in on this?  Is it intended behavior, or
> >> should we file an issue against it?  The documentation doesn't say
> >> much on the subject, and all the conceptual explanation of queries
> >> suggests that these extra single-property indexes will be unused.
>
> >> Jeff
>
> > --
> > 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 
> > 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.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



Re: [appengine-java] Re: it's terrible slow when loading resource files

2010-03-18 Thread Don Schwarz
On Wed, Mar 17, 2010 at 9:25 PM, firestoke  wrote:

> hi,
>
> If the latency only get 75-85ms, it surely is fine I think.
> The performance I expected is that the latency should be always under
> 300ms. But it always exceed 1 second from my PC testing.
> So it should be common network delay from my PC to app engine server.
> I am not a America user, and my PC is on Taiwan.
>

Yeah, this sounds like network congestion or some other kind of additional
latency being imposed outside of the Google network to me, but it's hard to
be sure.

Just to confirm, does App engine server provide a mirror mechanism?
>
>
Not at this time.


> I will install the "Page Speed" plugin to do more testing. Thanks! :^)
> Have a nice day!
>
>
Good luck.


>
> On 3月18日, 上午3時03分, Don Schwarz  wrote:
> > I'm getting 304 responses for your application with about a 75-85ms
> latency
> > above my ping times.  I've confirmed that you're using our optimized
> serving
> > infrastructure for static files.
> >
> > What kind of performance are you expecting to see?
> >
> > I would also try this tool:
> >
> > http://code.google.com/speed/page-speed/
> >
> > It may have additional advice about optimizing your javascript.
> >
> >
> >
> > On Wed, Mar 17, 2010 at 9:11 AM, firestoke  wrote:
> > > hi Don Schwarz,
> >
> > > My app id is "fstoke-mypage".
> > > And the full url is
> > >http://fstoke-mypage.appspot.com/
> > > Thanks! :^)
> >
> > > On 3月17日, 上午1時22分, Don Schwarz  wrote:
> > > > On Tue, Mar 16, 2010 at 8:04 AM, firestoke 
> wrote:
> > > > > hi,
> >
> > > > > The average ping time is as the following:
> > > > > Reply from 72.14.203.141: bytes=32 time=96ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=95ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=94ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=95ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=99ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=98ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=97ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=95ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=97ms TTL=51
> > > > > Reply from 72.14.203.141: bytes=32 time=98ms TTL=51
> >
> > > > Hmm, interesting.  What about doing something like 'time curlhttp://
> > > yourapp.appspot.com/.../a-small-file'?
> >
> > > > Also, you mentioned resource files.  Just to confirm, are you talking
> > > about
> > > > serving static files, or are you serving these files (and doing the
> 304
> > > > handling) yourself with Java code?  If you send me your app id
> privately
> > > I
> > > > can double-check this for you.
> >
> > > > > It looks like just normal. I found the page initialize spent time
> is
> > > > > quite different on different browsers.
> > > > > My testing behavior is always press "F5" to reload the page. The
> spent
> > > > > time compare is as the following:
> >
> > > > >  Firefox 3.6 < IE 8 << Chrome 4.1 = Safari 4.04
> >
> > > > > Safari & Chrome is very very very very very SLOW to initialize the
> > > > > page. The average spent time is about 10~14 seconds when page
> reload.
> > > > > Firefox just spent 3~4 seconds to finish initialize the page. Even
> IE8
> > > > > (spent 5 ~ 6 seconds) is faster than Chrome and Safari, very
> > > > > strange... ( In my memory, IE should be the worst browser of them.
> )
> > > > > For a normal web service, a page init time should not over 3
> seconds I
> > > > > think. Any suggestions?
> >
> > > > Have you tried YSlow or something equivalent?  That may be useful.
> >
> > > > > BTW, If I set billing to add "Bandwidth Out" resource will improve
> the
> > > > > server response time?
> >
> > > > No.  We don't do any throttling of bandwidth.
> >
> > > > > The reason why I choose to deploy on Google App Engine is that I
> think
> > > > > the server response and performance should be extremely fast like
> > > > > other Google web services.
> > > > > But the result is quite different as I wonder. :(((
> >
> > > > > On 3月16日, 上午1時54分, Don Schwarz  wrote:
> > > > > > It looks like your files are taking about 400ms each, which may
> not
> > > be
> > > > > that
> > > > > > bad depending on where you are located relative to App Engine's
> > > > > datacenters.
> > > > > >  What's an average ping time to your application's appspot.compage?
> >
> > > > > > I believe that the beige bars in the graph are time spent waiting
> due
> > > to
> > > > > > your browser's per-host connection limit.  You should try
> something
> > > like
> > > > > > YSlow (http://developer.yahoo.com/yslow/) for advice on how to
> > > > > concatenate
> > > > > > CSS and JS files, merge images, etc.
> >
> > > > > > On Mon, Mar 15, 2010 at 7:43 AM, firestoke 
> > > wrote:
> > > > > > > hi,
> >
> > > > > > > I write a HTML page that use many jQuery plugins and AJAX call.
> And
> > > I
> > > > > > > import many css and js files in this page. After I deploy it on
> > > Google
> > > > > > > App Engine server 

Re: [appengine-java] Re: Why do custom indexes require single-property indexes?

2010-03-18 Thread Jeff Schnitzer
This doesn't make sense to me.

Every scrap of documentation I've found says that GAE queries only
follow a single index (the one exception being zigzag merges, which
don't apply here).  This means that to answer my query.filter(foo,
"fooValue1").sort("-bar"), there must be an index that contains the
foo and bar data sorted appropriately, no?  Ie:

/Thing/foo:fooValue1/bar:bar9/[thekeyvalue]
/Thing/foo:fooValue1/bar:bar8/[thekeyvalue]
/Thing/foo:fooValue1/bar:bar7/[thekeyvalue]
/Thing/foo:fooValue2/bar:bar8/[thekeyvalue]
/Thing/foo:fooValue2/bar:bar7/[thekeyvalue]

To satisfy this query, GAE should start following this custom index
and that's pretty much it.  There's no reason for it to touch the
single-property indexes (foo ASC, foo DESC, bar ASC, and bar DESC).

...and in my test, if I remove the custom index from
datastore-indexes.xml, it doesn't work.  But also if I use
setUnindexedProperty, it doesn't work.

It's like setUnindexedProperty is being interpreted as "not only don't
set single-property indexes, but also don't include the property in
any custom indexes".  This is counterintuitive - if I wanted the index
not to be built, I can just remove the index.

I realize now that perhaps I posted this to the wrong mailing list.
The guys who created the I/O videos about the datastore seem to be
python fans, so I'll retry my original post on the google-appengine
list.

Jeff

On Thu, Mar 18, 2010 at 8:00 AM, Tristan  wrote:
> Not official but been doing this for a while.
>
> Your custom index is most likely build from the query. So, when you
> do
>
>        Query query = new Query("Thing");
>        query.addFilter("foo", FilterOperator.EQUAL, "fooValue");
>        query.addSort("bar", SortDirection.DESCENDING);
>
> That is what builds your custom index.
>
> However, when you setUnindexedProperty here
>
>        Entity ent = new Entity("Thing");
>        ent.setUnindexedProperty("foo", "fooValue");
>        ent.setUnindexedProperty("bar", 123L);
>
> You are not generating any index entries.
>
> So the issue isn't that "adding custom indexes after-the-fact [is]
> really, really painful" but that you are not generating any indexes
> for the datastore to run the queries against when you use
> setUnindexedProperty(). In other words, when you execute a query, it
> checks the index to give you results. But you marked your data as
> "don't index me," so there is nothing for query to work with, as far
> as it is concerned, there's nothing in the datastore.
>
> Cheers!
>
>
> On Mar 16, 4:07 pm, Jeff Schnitzer  wrote:
>> On Mon, Mar 15, 2010 at 11:04 PM, John Patterson  
>> wrote:
>>
>> > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
>>
>> >> I'm puzzled by the behavior of custom indexes.  I have a simple test
>> >> case below, a simple equality filter on one property combined with a
>> >> descending sort on another property.  If I set the properties with
>> >> setUnindexedProperty(), the query fails to find the result.  If I set
>> >> the properties with setProperty(), it does.
>>
>> > I also wondered why - I assume that the custom index build reads the single
>> > property indexes directly which must be more efficient than reading the
>> > Entities "table".
>>
>> I guess that is possible, but seems like a poor design decision.  It
>> makes adding custom indexes after-the-fact really, really painful.
>>
>> Can someone official chime in on this?  Is it intended behavior, or
>> should we file an issue against it?  The documentation doesn't say
>> much on the subject, and all the conceptual explanation of queries
>> suggests that these extra single-property indexes will be unused.
>>
>> Jeff
>
> --
> 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: Why do custom indexes require single-property indexes?

2010-03-18 Thread Tristan
Ugorji,

I don't know if they will support re-indexing things based on new
index definition, however, I did put in an issue back in August 2009
to be able to create a custom index term on the fly. See if this would
partially solve the issue (again, it doesn't address reindexing
already put entities).

http://code.google.com/p/googleappengine/issues/detail?id=1935

Cheers!

On Mar 18, 10:37 am, Ugorji  wrote:
> +1 big-time on this. With the restriction that every index'able
> property must be indexed at put-time when put into the datastore
> (using setProperty as opposed to setUnindexedProperty), it has 2 MAJOR
> disadvantages with far-reaching repercussions:
>
> - you cannot index entities after they have been put (even with a
> custom index). You will have to re-write the entity to index it.
> - Each put is 4X more expensive in latency/clock-time (potentially),
> CPU-cost and storage. This seems un-necessary, especially if a single
> custom index will suffice all your querying needs.
>
> I was really hoping to use custom indexes to buy major performance
> savings (in latency, CPU-cost and storage), and also be able to re-
> index every entity after the fact. But this restriction is heavy
> (preventing direct solution to a problem everyone may end up facing),
> and very expensive (costing us big-time). Can one of the google guys
> respond to this, before we file a bug?
>
> Thanks.
>
> On Mar 16, 2:07 pm, Jeff Schnitzer  wrote:
>
>
>
> > On Mon, Mar 15, 2010 at 11:04 PM, John Patterson  
> > wrote:
>
> > > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
>
> > >> I'm puzzled by the behavior of custom indexes.  I have a simple test
> > >> case below, a simple equality filter on one property combined with a
> > >> descending sort on another property.  If I set the properties with
> > >> setUnindexedProperty(), the query fails to find the result.  If I set
> > >> the properties with setProperty(), it does.
>
> > > I also wondered why - I assume that the custom index build reads the 
> > > single
> > > property indexes directly which must be more efficient than reading the
> > > Entities "table".
>
> > I guess that is possible, but seems like a poor design decision.  It
> > makes adding custom indexes after-the-fact really, really painful.
>
> > Can someone official chime in on this?  Is it intended behavior, or
> > should we file an issue against it?  The documentation doesn't say
> > much on the subject, and all the conceptual explanation of queries
> > suggests that these extra single-property indexes will be unused.
>
> > Jeff

-- 
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: Why do custom indexes require single-property indexes?

2010-03-18 Thread Ugorji
+1 big-time on this. With the restriction that every index'able
property must be indexed at put-time when put into the datastore
(using setProperty as opposed to setUnindexedProperty), it has 2 MAJOR
disadvantages with far-reaching repercussions:

- you cannot index entities after they have been put (even with a
custom index). You will have to re-write the entity to index it.
- Each put is 4X more expensive in latency/clock-time (potentially),
CPU-cost and storage. This seems un-necessary, especially if a single
custom index will suffice all your querying needs.

I was really hoping to use custom indexes to buy major performance
savings (in latency, CPU-cost and storage), and also be able to re-
index every entity after the fact. But this restriction is heavy
(preventing direct solution to a problem everyone may end up facing),
and very expensive (costing us big-time). Can one of the google guys
respond to this, before we file a bug?

Thanks.

On Mar 16, 2:07 pm, Jeff Schnitzer  wrote:
> On Mon, Mar 15, 2010 at 11:04 PM, John Patterson  
> wrote:
>
> > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
>
> >> I'm puzzled by the behavior of custom indexes.  I have a simple test
> >> case below, a simple equality filter on one property combined with a
> >> descending sort on another property.  If I set the properties with
> >> setUnindexedProperty(), the query fails to find the result.  If I set
> >> the properties with setProperty(), it does.
>
> > I also wondered why - I assume that the custom index build reads the single
> > property indexes directly which must be more efficient than reading the
> > Entities "table".
>
> I guess that is possible, but seems like a poor design decision.  It
> makes adding custom indexes after-the-fact really, really painful.
>
> Can someone official chime in on this?  Is it intended behavior, or
> should we file an issue against it?  The documentation doesn't say
> much on the subject, and all the conceptual explanation of queries
> suggests that these extra single-property indexes will be unused.
>
> Jeff

-- 
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: How to query for parent key property of an entity's key?

2010-03-18 Thread Ugorji
Use an ancestor-is query. This will find all entities which have a
given ancestor as parent. It even works in a kind-less query,
returning different kinds of entities under that parent. It's also
quite efficient (especially from a pricing/CPU cost perspective) since
theoretically, all this can be done on a single database node.

I'm not sure how to do ancestor-is query with JDO (I use my own type-
safe wrapper over low-level API), but you could try something like:

select from ... where ANCESTOR=... (like __key__, ANCESTOR seems to be
a reserved name in app engine)

On Mar 18, 7:56 am, tempy  wrote:
> That's a good point, but in this case the resulting entity group
> arrangement is intentional.  Lock-in isn't a worry, I can confidently
> say that these entity-group arrangements will last as long as the
> application does.
>
> Though, as you point out, I can make a "parentKey" field on the child,
> but since this parent key will also have to appear within the child's
> key, having such a field is redundant and I would rather avoid it.
>
> On Mar 18, 3:51 pm, Tristan  wrote:
>
>
>
> > Something you may want to consider is that you are placing yourself
> > within the limitations of entity groups by sticking children under
> > parent keys. You may want to consider a model where the parent key is
> > simply a field in the child and then run a simple query testing that
> > the "parentKey" field is equal to the one you're looking for. This
> > makes queries easier and prevents entity group lock-in.
>
> > Cheers!
>
> > On Mar 18, 8:55 am, tempy  wrote:
>
> > > I want to retrieve all entities that are children of one other
> > > particular entity, by checking if the parent-key property of the
> > > child's key matches the parent key.  I have a reference to the parent
> > > entity but I want to avoid loading all of its children (as there may
> > > be many children, but I only need a few).  Thus I want a query that
> > > looks something like this:
>
> > >         query = pm.newQuery("select from " + ChildClass.class.getName() +
> > > " where :parentID.contains(ChildIDProperty.ParentID) &&
> > > SomeOtherProperty  > " + filterString);
>
> > > But I'm not sure how to exactly address the parent key property of a
> > > key in a query.
>
> > > Thanks,
> > > Mike

-- 
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: How to query for parent key property of an entity's key?

2010-03-18 Thread Tristan
Although having a "parentKey" is redundant, that's the beauty of
denormalization in non-relational datastore. It's easier and it
doesn't take much to do. (ie in non-relational datastore logic should
be done on writes not on reads if it can be helped). hehe... I'm not
biased at all :)

About the entity group thing. I'm sure the entity-group arrangements
will stick around. Schema change isn't the issue though. I ran into a
problem with datastore writes. There is a limit on writes within an
entity group, (about 10 per second). So if you have a lot of children
and you want to update 100 of them and they are in the same entity
group, guess what happens.  If you're aware of that, that's fine, just
wanted to point that out. It was a surprise to me, but it's something
Max Ross brought up in Google I/O presentations.

Cheers!

On Mar 18, 9:56 am, tempy  wrote:
> That's a good point, but in this case the resulting entity group
> arrangement is intentional.  Lock-in isn't a worry, I can confidently
> say that these entity-group arrangements will last as long as the
> application does.
>
> Though, as you point out, I can make a "parentKey" field on the child,
> but since this parent key will also have to appear within the child's
> key, having such a field is redundant and I would rather avoid it.
>
> On Mar 18, 3:51 pm, Tristan  wrote:
>
>
>
> > Something you may want to consider is that you are placing yourself
> > within the limitations of entity groups by sticking children under
> > parent keys. You may want to consider a model where the parent key is
> > simply a field in the child and then run a simple query testing that
> > the "parentKey" field is equal to the one you're looking for. This
> > makes queries easier and prevents entity group lock-in.
>
> > Cheers!
>
> > On Mar 18, 8:55 am, tempy  wrote:
>
> > > I want to retrieve all entities that are children of one other
> > > particular entity, by checking if the parent-key property of the
> > > child's key matches the parent key.  I have a reference to the parent
> > > entity but I want to avoid loading all of its children (as there may
> > > be many children, but I only need a few).  Thus I want a query that
> > > looks something like this:
>
> > >         query = pm.newQuery("select from " + ChildClass.class.getName() +
> > > " where :parentID.contains(ChildIDProperty.ParentID) &&
> > > SomeOtherProperty  > " + filterString);
>
> > > But I'm not sure how to exactly address the parent key property of a
> > > key in a query.
>
> > > Thanks,
> > > Mike

-- 
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: Why do custom indexes require single-property indexes?

2010-03-18 Thread Tristan
Not official but been doing this for a while.

Your custom index is most likely build from the query. So, when you
do

Query query = new Query("Thing");
query.addFilter("foo", FilterOperator.EQUAL, "fooValue");
query.addSort("bar", SortDirection.DESCENDING);

That is what builds your custom index.

However, when you setUnindexedProperty here

Entity ent = new Entity("Thing");
ent.setUnindexedProperty("foo", "fooValue");
ent.setUnindexedProperty("bar", 123L);

You are not generating any index entries.

So the issue isn't that "adding custom indexes after-the-fact [is]
really, really painful" but that you are not generating any indexes
for the datastore to run the queries against when you use
setUnindexedProperty(). In other words, when you execute a query, it
checks the index to give you results. But you marked your data as
"don't index me," so there is nothing for query to work with, as far
as it is concerned, there's nothing in the datastore.

Cheers!


On Mar 16, 4:07 pm, Jeff Schnitzer  wrote:
> On Mon, Mar 15, 2010 at 11:04 PM, John Patterson  
> wrote:
>
> > On 16 Mar 2010, at 12:25, Jeff Schnitzer wrote:
>
> >> I'm puzzled by the behavior of custom indexes.  I have a simple test
> >> case below, a simple equality filter on one property combined with a
> >> descending sort on another property.  If I set the properties with
> >> setUnindexedProperty(), the query fails to find the result.  If I set
> >> the properties with setProperty(), it does.
>
> > I also wondered why - I assume that the custom index build reads the single
> > property indexes directly which must be more efficient than reading the
> > Entities "table".
>
> I guess that is possible, but seems like a poor design decision.  It
> makes adding custom indexes after-the-fact really, really painful.
>
> Can someone official chime in on this?  Is it intended behavior, or
> should we file an issue against it?  The documentation doesn't say
> much on the subject, and all the conceptual explanation of queries
> suggests that these extra single-property indexes will be unused.
>
> Jeff

-- 
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: How to query for parent key property of an entity's key?

2010-03-18 Thread tempy
That's a good point, but in this case the resulting entity group
arrangement is intentional.  Lock-in isn't a worry, I can confidently
say that these entity-group arrangements will last as long as the
application does.

Though, as you point out, I can make a "parentKey" field on the child,
but since this parent key will also have to appear within the child's
key, having such a field is redundant and I would rather avoid it.

On Mar 18, 3:51 pm, Tristan  wrote:
> Something you may want to consider is that you are placing yourself
> within the limitations of entity groups by sticking children under
> parent keys. You may want to consider a model where the parent key is
> simply a field in the child and then run a simple query testing that
> the "parentKey" field is equal to the one you're looking for. This
> makes queries easier and prevents entity group lock-in.
>
> Cheers!
>
> On Mar 18, 8:55 am, tempy  wrote:
>
>
>
> > I want to retrieve all entities that are children of one other
> > particular entity, by checking if the parent-key property of the
> > child's key matches the parent key.  I have a reference to the parent
> > entity but I want to avoid loading all of its children (as there may
> > be many children, but I only need a few).  Thus I want a query that
> > looks something like this:
>
> >         query = pm.newQuery("select from " + ChildClass.class.getName() +
> > " where :parentID.contains(ChildIDProperty.ParentID) &&
> > SomeOtherProperty  > " + filterString);
>
> > But I'm not sure how to exactly address the parent key property of a
> > key in a query.
>
> > Thanks,
> > Mike

-- 
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: How to query for parent key property of an entity's key?

2010-03-18 Thread Tristan
Something you may want to consider is that you are placing yourself
within the limitations of entity groups by sticking children under
parent keys. You may want to consider a model where the parent key is
simply a field in the child and then run a simple query testing that
the "parentKey" field is equal to the one you're looking for. This
makes queries easier and prevents entity group lock-in.

Cheers!

On Mar 18, 8:55 am, tempy  wrote:
> I want to retrieve all entities that are children of one other
> particular entity, by checking if the parent-key property of the
> child's key matches the parent key.  I have a reference to the parent
> entity but I want to avoid loading all of its children (as there may
> be many children, but I only need a few).  Thus I want a query that
> looks something like this:
>
>         query = pm.newQuery("select from " + ChildClass.class.getName() +
> " where :parentID.contains(ChildIDProperty.ParentID) &&
> SomeOtherProperty  > " + filterString);
>
> But I'm not sure how to exactly address the parent key property of a
> key in a query.
>
> Thanks,
> Mike

-- 
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 to query for parent key property of an entity's key?

2010-03-18 Thread tempy
I want to retrieve all entities that are children of one other
particular entity, by checking if the parent-key property of the
child's key matches the parent key.  I have a reference to the parent
entity but I want to avoid loading all of its children (as there may
be many children, but I only need a few).  Thus I want a query that
looks something like this:

query = pm.newQuery("select from " + ChildClass.class.getName() +
" where :parentID.contains(ChildIDProperty.ParentID) &&
SomeOtherProperty  > " + filterString);

But I'm not sure how to exactly address the parent key property of a
key in a query.

Thanks,
Mike

-- 
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: GAE Java + Authsub + GData

2010-03-18 Thread s8
Thanks for your response. I did look at that documentation. It is more
apt for applications that are not on the App Engine. If the same logic
is used on the App Engine, the user will be redirected to a login page
again even though he is already logged into the App Engine application
using the very same Google Apps credentials.

If any of the following is supported, it would be helpful:

1. When the user is redirected to a login page from my GAEJ
application, I use the UserService for redirection. Can we log the
user into the App Engine domain and GData Services in one shot using
something like this:

String authSubUrl = AuthSubUtil.getRequestUrl(url, scope, secure,
session);
userService.createLoginURL(authSubUrl);

Someone tried it and ran into issues in production:
http://groups.google.com/group/google-appengine-java/browse_thread/thread/6db6eea6ab183cfe/299810d80d921be7?lnk=gst&q=gdata+login#299810d80d921be7

2. Once the user logs in, fetch the session information from the App
Engine session and create an AuthSub session token for the GData
Services using this session. This does not seem possible based on
this:

http://groups.google.com/group/google-appengine-java/browse_thread/thread/3f3066dd0bd3bdeb/0260a196d798d757?lnk=gst&q=gdata+authsub#0260a196d798d757

I am trying to avoid asking the user to login twice. It seems
unavoidable. An integrated login would make perfect sense. Adding this
feature would be very helpful for many.

Thanks,
s8


On Mar 17, 12:09 am, seleronm  wrote:
> Hi,
> Though it is likely already to have tried
> This link might be useful.
>
> http://code.google.com/intl/us/apis/gdata/docs/auth/authsub.html
>
> Please Try.
> thanks.
>
>
>
> > Hi -
>
> > My App Engine Java application is restricted to a Google Apps domain.
> > Users are authenticated in my application using the App Engine
> > UserService. How do I obtain a AuthSub session token for the user that
> > is already logged into my application to push data into a spreadsheet
> > in his Google Apps account?
>
> > The following URL talks about GData access from GAE Python. How can
> > this be achieved in the Java version?
>
> >http://code.google.com/appengine/articles/gdata.html
>
> > Thanks,
> > s8

-- 
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: Timeout using GData API

2010-03-18 Thread Ice13ill
Everybody says that using the setConntectionTimeout() can set the
maximum timeout to 10 seconds.
I also tried setting service.setConnectionTimeout() (witch sets the
timeout for the HttpUrlConnectiion object used to fetch data) but with
no effect (contrary to what it says here:
http://code.google.com/appengine/docs/java/urlfetch/overview.html#Requests).
I have read somewhere that this pb was fixed in an early release but
it doesn't appear so.
Can anyone help ?


On Jan 20, 7:42 am, smile laugh  wrote:
> I also get same error
>
> is there someone can help me out

-- 
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: elegant way of implementing sequence generator

2010-03-18 Thread legendlink
thanks for the link.

have tried the @version with shards. the output counter seems not to
be unique... i think there is no other way to mimic the sequence
generator like other rdbms without using normal transactions with
optimistic locking of the entity.

On Mar 12, 1:49 am, datanucleus  wrote:
> > could you give me simple example on how to use the @version,
>
> The DataNucleus docs define that, and much 
> morehttp://www.datanucleus.org/products/accessplatform/jdo/orm/versioning...

-- 
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] Slim3 1.0.0 Released

2010-03-18 Thread Yasuo Higa
Hi all,

We are pleased to announce the release of Slim3 1.0.0.

Slim3 is a full-stack MVC framework optimized for Google App Engine/Java.

The main features of Slim3 are as follows:
* Global Transactions
* Faster than JDO/JPA
* Fast spin-up
* HOT reloading
* Type safe query

You can find more information about Slim3 here:
http://slim3.org

Release Notes:
http://sites.google.com/site/slim3appengine/release-notes

Download:
http://slim3.googlecode.com/files/slim3-blank-1.0.0.zip

Thanks,

Yasuo Higa

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