[appengine-java] JDO - Deleted data reappears

2010-06-09 Thread Andrew
Hi,

I'm in the very early stages of building an app with GAE and am trying
to do my first "CRUD" process.

Unfortunately I've run into a problem where when I delete items they
seem to disappear during the current session in development, but when
I stop and restart the development server they reappear.

I've pasted my DAO code here if anyone is able to give me some advice
on what I may have done wrong:

http://java.pastebin.com/Jr23cMTc

Best regards,
Andrew.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-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] Ctrl+C doesnt stop development server

2010-06-09 Thread shekhar
Hi,

Anyone knows how to stop development server? I am starting it on
command prompt using ANT script but when I try to stop server using
Ctrl+C, server doesnt stop. I can see development server process
running by using Windwos Task Manager and I have to kill that process
in order to stop server. I want to avoid killing process.


Please enlighten 

-- 
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 stop development server from command line?

2010-06-09 Thread shekhar
Thank you IKai Lan for taking time to answer my question, but I know
how to kill a process and currently I am stopping server by doing the
same. I usually dont like to KILL anyone (even a process) . So is
there any command to stop development server? Or is that google forgot
to provide any command for stopping server?


On Jun 7, 11:58 pm, "Ikai L (Google)"  wrote:
> Bit of a hack but:
>
> http://www.howtogeek.com/howto/windows/kill-processes-from-the-window...
>
> Just
> a warning: I have never tried this before, though I've done similar things
> in Linux using ps, kill and killall before.
>
>
>
>
>
> On Mon, Jun 7, 2010 at 2:09 AM, shekhar  wrote:
> > Hi,
>
> >    I am not able to stop development server. I am starting it from
> > command prompt using ANT script. I have created ANT script (build.xml)
> > according to tutorial given by Google itself.
>
> >     My development App server starts successfully and I am able to
> > test my app also. But when I press Ctrl+C, only ANT script stops and
> > development server keeps running in background. I have to stop it
> > manually by killing the process using Windows  Task Manager.
>
> > Does anyone knows how to stop server through ANT script?
>
> > --
> > 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.
>
> --
> Ikai Lan
> Developer Programs Engineer, Google App Engine
> Blog:http://googleappengine.blogspot.com
> Twitter:http://twitter.com/app_engine
> Reddit:http://www.reddit.com/r/appengine- Hide quoted text -
>
> - Show quoted text -

-- 
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 aborted requests be repeated?

2010-06-09 Thread dmitrygusev
Hi,

I see "Request was aborted after waiting too long to attempt to
service your request" in logs.

The request was initiated by cron job (which triggers in every 1 hours
rate).

It is important to me this call to be executed nearly once per hour.
Is it possible somehow to make this request repeated if it was aborted
by a reason of waiting too long?

(Maybe put cron requests to some queue?)

-- 
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: Unnecessary memcache request from jetty SessionManager?

2010-06-09 Thread dmitrygusev
Peter,

you're right.

So if value in memcache is not of primitive type (and it can't be of
primitive type, because cache operates with objects), you can skip
cache.containsKey() call and analyze result of cache.get() with
equality to null.

In production cache.containsKey() tooks ~20 milliseconds (which is
more than 10% of my request processing time), and I believe this also
uses cpu which makes this call billable. The same time required to
invoke cache.get().

But comparing Object with null tooks almost nothing, so I think this
is the preferable way.

Isn't it?

On Jun 8, 2:01 pm, Peter Ondruska  wrote:
> How I understand memcache:
>
> cache.containsKey("some-key") tells you whether there is such key in
> memcache
> and cache.get("some-key") retrieves the value for key
>
> You could skip asking for existence of the key in memcache only in
> case you expect to return non-null values (and null being non-existent
> object), I may be wrong but this is how I understand memcache.
>
> On Jun 8, 11:07 am, dmitrygusev  wrote:
>
> > Can somebody comment on:
>
> >http://code.google.com/p/googleappengine/issues/detail?id=3319
>
>

-- 
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] Can't end my thread properly after a DeadlineExceededException

2010-06-09 Thread John Patterson
I haven't noticed a problem calling System.currentTimeMillis().  Would  
be surprising if this was using a lot of CPU.


On 10 Jun 2010, at 11:16, Felipe Quintella Correia wrote:


Hi John,

I managed to implement this and now I can do a proper clean up after  
25seconds. But now I'm getting cpu_ms red warnings for every task I  
run. I think that's exactly because it runs a method to calculate  
the time spent in every iteration... Have you been able to optimize  
this somehow? Or maybe it isn't even because of that, but if you  
have some advice, I'm happy to take it.


Thank you again.

#06-09 08:25PM 26.600 /canalparser?main=updateShows&tasknumber=1 200  
8262ms 2175cpu_ms 1320api_cpu_ms 0kb AppEngine-Google; (+http://code.google.com/appengine)

 See details

 0.1.0.2 - - [09/Jun/2010:20:25:34 -0700] "GET /canalparser? 
main=updateShows&tasknumber=1 HTTP/1.1" 200 0 "http://tvguidebr.appspot.com/canalparser?main=scheduleShowsUpdate 
" "AppEngine-Google; (+http://code.google.com/appengine)"


 I 06-09 08:25PM 26.608 braziltvguide.ParseCanaisServlet doGet:  
Starting thread
 I 06-09 08:25PM 26.778 [tvguidebr/1.342561233485567613].:  
Updating Shows for AXN (1 of 112)
 I 06-09 08:25PM 26.778 braziltvguide.ParseCanaisServlet  
updateShows: Updating Shows for AXN (1 of 112)
 I 06-09 08:25PM 34.855 braziltvguide.ParseCanaisServlet doGet:  
Ending thread - Timer: 8247ms


#06-09 08:24PM 59.092 /canalparser?main=updateShows&tasknumber=0 200  
17491ms 2666cpu_ms 1364api_cpu_ms 0kb AppEngine-Google; (+http://code.google.com/appengine)

 See details

 0.1.0.2 - - [09/Jun/2010:20:25:16 -0700] "GET /canalparser? 
main=updateShows&tasknumber=0 HTTP/1.1" 200 0 "http://tvguidebr.appspot.com/canalparser?main=scheduleShowsUpdate 
" "AppEngine-Google; (+http://code.google.com/appengine)"


  I 06-09 08:24PM 59.391 braziltvguide.ParseCanaisServlet doGet:  
Starting thread
  I 06-09 08:24PM 59.572 [tvguidebr/1.342561233485567613].:  
Updating Shows for A&E Mundo (0 of 112)
  I 06-09 08:24PM 59.572 braziltvguide.ParseCanaisServlet  
updateShows: Updating Shows for A&E Mundo (0 of 112)
  I 06-09 08:25PM 16.572 braziltvguide.ParseCanaisServlet doGet:  
Ending thread - Timer: 17181ms



#06-09 08:24PM 58.807 /canalparser?main=scheduleShowsUpdate 200  
569ms 1369cpu_ms 1039api_cpu_ms 0kb Mozilla/5.0 (Macintosh; U; Intel  
Mac OS X 10.6; en-US; rv:1.9.2.3) Gecko/20100401 Firefox/ 
3.6.3,gzip(gfe)

 See details

 201.29.172.42 - - [09/Jun/2010:20:24:59 -0700] "GET / 
canalparser?main=scheduleShowsUpdate HTTP/1.1" 200 0 - "Mozilla/5.0  
(Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.3) Gecko/ 
20100401 Firefox/3.6.3,gzip(gfe)"


  I 06-09 08:24PM 58.821 braziltvguide.ParseCanaisServlet doGet:  
Starting thread
  I 06-09 08:24PM 59.115 braziltvguide.ParseCanaisServlet  
scheduleShowsUpdate: Scheduling ShowsUpdate for channel 1 of 3
  I 06-09 08:24PM 59.344 braziltvguide.ParseCanaisServlet  
scheduleShowsUpdate: Scheduling ShowsUpdate for channel 2 of 3
  I 06-09 08:24PM 59.370 braziltvguide.ParseCanaisServlet  
scheduleShowsUpdate: Scheduling ShowsUpdate for channel 3 of 3
  I 06-09 08:24PM 59.370 braziltvguide.ParseCanaisServlet doGet:  
Ending thread - Timer: 549ms





Felipe Quintella



2010/6/7 John Patterson :
> Yes just use System.currentTimeMillis() to check in every  
iteration of your

> tasks main loop.
>
> On 7 Jun 2010, at 09:57, Felipe Quintella Correia wrote:
>
>> I'll try this approach and start my clean up around 25seconds.
>>
>> Do you know any reliable timer I can count on? Or do I have to make
>> one of my own?
>>
>> Thank you very much.
>>
>> Felipe Quintella
>>
>>
>>
>> 2010/6/6 John Patterson :
>>>
>>> It looks like after catching the DEE a HardDEError is probably  
thrown

>>> which
>>> causes the server instance to quit and the next request will  
cause a new

>>> instance to be spun up.
>>>
>>> I had to give up catching DEE's - you don't get enough time to  
reliably
>>> start a new task.  The only option seems to be to start your  
clean up

>>> code
>>> after 25 seconds for example.
>>>
>>> The other "request aborted..." errors are due to your app  
restarting and
>>> taking too long.  The request that kills the server instance is  
followed

>>> by
>>> other requests that will time out after 10 seconds if you app  
has not

>>> finished reloading.
>>>
>>> So two things to work on: 1) clean up task before DEE thrown  2)  
speed up

>>> app loading time
>>>
>>> John
>>>
>>> On 6 Jun 2010, at 21:19, Felipe Quintella Correia wrote:
>>>
 Hello,

 I hope someone can help me. Even though this is not a critical
 problem, it's really annoying me. Every time i catch a
 DeadlineExceededException and I try to patch things up and end my
 thread properly I get a

 (Error code 104). I already tried searching everywhere, tried  
ending
 the thread immediately, throwing another exception, yadda  
yadda... But

 I always end up with this error after my 

Re: [appengine-java] Can't end my thread properly after a DeadlineExceededException

2010-06-09 Thread Felipe Quintella Correia
Hi John,

I managed to implement this and now I can do a proper clean up after
25seconds. But now I'm getting cpu_ms red warnings for every task I run. I
think that's exactly because it runs a method to calculate the time spent in
every iteration... Have you been able to optimize this somehow? Or maybe it
isn't even because of that, but if you have some advice, I'm happy to take
it.

Thank you again.

*#06-09 08:25PM 26.600 /canalparser?main=updateShows&tasknumber=1 200 8262ms
> 2175cpu_ms 1320api_cpu_ms 0kb AppEngine-Google; (+
> http://code.google.com/appengine)*
> *  See details*
>
> *  0.1.0.2 - - [09/Jun/2010:20:25:34 -0700] "GET
> /canalparser?main=updateShows&tasknumber=1 HTTP/1.1" 200 0 "
> http://tvguidebr.appspot.com/canalparser?main=scheduleShowsUpdate";
> "AppEngine-Google; (+http://code.google.com/appengine)"*
>
> *  I 06-09 08:25PM 26.608 braziltvguide.ParseCanaisServlet doGet: Starting
> thread*
> *  I 06-09 08:25PM 26.778 [tvguidebr/1.342561233485567613].:
> Updating Shows for AXN (1 of 112)*
> *  I 06-09 08:25PM 26.778 braziltvguide.ParseCanaisServlet updateShows:
> Updating Shows for AXN (1 of 112)*
> *  I 06-09 08:25PM 34.855 braziltvguide.ParseCanaisServlet doGet: Ending
> thread - Timer: 8247ms*
>
> *#06-09 08:24PM 59.092 /canalparser?main=updateShows&tasknumber=0 200
> 17491ms 2666cpu_ms 1364api_cpu_ms 0kb AppEngine-Google; (+
> http://code.google.com/appengine)*
> *  See details*
>
> *  0.1.0.2 - - [09/Jun/2010:20:25:16 -0700] "GET
> /canalparser?main=updateShows&tasknumber=0 HTTP/1.1" 200 0 "
> http://tvguidebr.appspot.com/canalparser?main=scheduleShowsUpdate";
> "AppEngine-Google; (+http://code.google.com/appengine)"*
>
> *   I 06-09 08:24PM 59.391 braziltvguide.ParseCanaisServlet doGet:
> Starting thread*
> *   I 06-09 08:24PM 59.572 [tvguidebr/1.342561233485567613].:
> Updating Shows for A&E Mundo (0 of 112)*
> *   I 06-09 08:24PM 59.572 braziltvguide.ParseCanaisServlet updateShows:
> Updating Shows for A&E Mundo (0 of 112)*
> *   I 06-09 08:25PM 16.572 braziltvguide.ParseCanaisServlet doGet: Ending
> thread - Timer: 17181ms*
>
>
> *#06-09 08:24PM 58.807 /canalparser?main=scheduleShowsUpdate 200 569ms
> 1369cpu_ms 1039api_cpu_ms 0kb Mozilla/5.0 (Macintosh; U; Intel Mac OS X
> 10.6; en-US; rv:1.9.2.3) Gecko/20100401 Firefox/3.6.3,gzip(gfe)*
> *  See details*
>
> *  201.29.172.42 - - [09/Jun/2010:20:24:59 -0700] "GET
> /canalparser?main=scheduleShowsUpdate HTTP/1.1" 200 0 - "Mozilla/5.0
> (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.3) Gecko/20100401
> Firefox/3.6.3,gzip(gfe)"*
>
> *   I 06-09 08:24PM 58.821 braziltvguide.ParseCanaisServlet doGet:
> Starting thread*
> *   I 06-09 08:24PM 59.115 braziltvguide.ParseCanaisServlet
> scheduleShowsUpdate: Scheduling ShowsUpdate for channel 1 of 3*
> *   I 06-09 08:24PM 59.344 braziltvguide.ParseCanaisServlet
> scheduleShowsUpdate: Scheduling ShowsUpdate for channel 2 of 3*
> *   I 06-09 08:24PM 59.370 braziltvguide.ParseCanaisServlet
> scheduleShowsUpdate: Scheduling ShowsUpdate for channel 3 of 3*
> *   I 06-09 08:24PM 59.370 braziltvguide.ParseCanaisServlet doGet: Ending
> thread - Timer: 549ms*
>




Felipe Quintella



2010/6/7 John Patterson :
> Yes just use System.currentTimeMillis() to check in every iteration of
your
> tasks main loop.
>
> On 7 Jun 2010, at 09:57, Felipe Quintella Correia wrote:
>
>> I'll try this approach and start my clean up around 25seconds.
>>
>> Do you know any reliable timer I can count on? Or do I have to make
>> one of my own?
>>
>> Thank you very much.
>>
>> Felipe Quintella
>>
>>
>>
>> 2010/6/6 John Patterson :
>>>
>>> It looks like after catching the DEE a HardDEError is probably thrown
>>> which
>>> causes the server instance to quit and the next request will cause a new
>>> instance to be spun up.
>>>
>>> I had to give up catching DEE's - you don't get enough time to reliably
>>> start a new task.  The only option seems to be to start your clean up
>>> code
>>> after 25 seconds for example.
>>>
>>> The other "request aborted..." errors are due to your app restarting and
>>> taking too long.  The request that kills the server instance is followed
>>> by
>>> other requests that will time out after 10 seconds if you app has not
>>> finished reloading.
>>>
>>> So two things to work on: 1) clean up task before DEE thrown  2) speed
up
>>> app loading time
>>>
>>> John
>>>
>>> On 6 Jun 2010, at 21:19, Felipe Quintella Correia wrote:
>>>
 Hello,

 I hope someone can help me. Even though this is not a critical
 problem, it's really annoying me. Every time i catch a
 DeadlineExceededException and I try to patch things up and end my
 thread properly I get a

 (Error code 104). I already tried searching everywhere, tried ending
 the thread immediately, throwing another exception, yadda yadda... But
 I always end up with this error after my logs. The clean up is
 properly done, meaning I get what I should (new tasks in queue to
 conti

[appengine-java] Re: TransientFailureException

2010-06-09 Thread Didier Durand
Hi,
I exactly have the same problem as describes by skk

What I can add: it seems to happen in burst. I had it 7 times out of 9
for the day around 12:40 pm today
regards
didier

On Jun 9, 11:20 pm, skk  wrote:
> MeToo - I get this too -
> com.google.appengine.api.labs.taskqueue.TransientFailureException:
> Unknown
>         at
> com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:
> 60)
>         at
>
> What's worse is that this occurs on a recurrent task that schedules
> itself - After failures like this, I end up with 2, 3, sometimes 5
> tasks all doing the same thing - the task queue management system
> keeps scheduling the failed task..
>
> Luckily, the app is structured so that repeated concurrent runs does
> no harm apart from using up CPU. What can I do - apart from monitoring
> the queue on a daily basis and purging the extraneous tasks ?
>
> On Jun 3, 3:22 am, Viðar Svansson  wrote:
>
> > I am adding tasks to the defautl queue and frequently get this
> > exception frequently.
> > What is happening? Can I do anything about it?
>
> > Viðar
>
> > com.google.appengine.api.labs.taskqueue.TransientFailureException: Unknown
> >         at 
> > com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:58)
> >         at 
> > com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:111)
> >         at 
> > com.google.appengine.api.labs.taskqueue.QueueApiHelper.makeSyncCall(QueueApiHelper.java:32)
> >         at 
> > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:278)
> >         at 
> > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:250)
> >         at 
> > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:235)
>
> > On Mon, Apr 12, 2010 at 4:50 PM, Tristan  
> > wrote:
> > > Hey,
>
> > > I got this exception twice yesterday. Is there anything in my control
> > > that may be causing it? Or should I just wrap it up and retry if this
> > > happens? (the task has successfully queued and executed hundreds of
> > > times)
>
> > > Uncaught exception from servlet
> > > com.google.appengine.api.labs.taskqueue.TransientFailureException:
> > > Unknown
> > >        at
> > > com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:
> > > 58)
> > >        at
> > > com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:
> > > 111)
> > >        at
> > > com.google.appengine.api.labs.taskqueue.QueueApiHelper.makeSyncCall(QueueApiHelper.java:
> > > 32)
> > >        at
> > > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:
> > > 278)
> > >        at
> > > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:
> > > 250)
> > >        at
> > > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:
> > > 235)
>
> > > Tristan
>
> > > --
> > > 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] Re: Appengine blocked in Turkey??!! Dns solution but another problem.

2010-06-09 Thread KeremTiryaki
I have same problem :(
I will try proxy servers to deploy

On Jun 4, 7:43 pm, "Ikai L (Google)"  wrote:
> Google is investigating reports of general connectivity issues from Turkey:
>
> http://thenextweb.com/google/2010/06/04/some-google-services-banned-i...
>
>
>
> On Fri, Jun 4, 2010 at 4:50 AM, cumhur cevik  wrote:
> > Tryed Googel Dns and changed host file in C:\Windows\System32\drivers
> > \etc and put google valid ip. Now this links works in web browser.
>
> >https://appengine.google.com/api/updatecheck?runtime=java&release=1.3...['1.0
> > ']
>
> > But when trying to upload to Appengine server this error created.
>
> > "No name matching appengine.google.com found"
>
> > Have you any idea to fix it?
>
> > INFO: Unable to access
>
> >https://appengine.google.com/api/updatecheck?runtime=java&release=1.3...['1.0
> > ']
> > javax.net.ssl.SSLHandshakeException:
> > java.security.cert.CertificateException: No name matching
> > appengine.google.com found
> >        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:
> > 174)
> >        at
> > com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:
> > 1623)
> >        at com.sun.net.ssl.internal.ssl.Handshaker.fatalSE(Handshaker.java:
> > 198)
> >        at com.sun.net.ssl.internal.ssl.Handshaker.fatalSE(Handshaker.java:
> > 192)
> >        at
>
> > com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:
> > 1074)
> >        at
>
> > com.sun.net.ssl.internal.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:
> > 128)
> >        at
> > com.sun.net.ssl.internal.ssl.Handshaker.processLoop(Handshaker.java:
> > 529)
> >        at
> > com.sun.net.ssl.internal.ssl.Handshaker.process_record(Handshaker.java:
> > 465)
> >        at
> > com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:
> > 884)
> >        at
>
> > com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:
> > 1120)
> >        at
>
> > com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:
> > 1147)
> >        at
>
> > com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:
> > 1131)
> >        at
> > sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:
> > 434)
> >        at
>
> > sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Abstrac...
> > 166)
> >        at
>
> > sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection
> > 1049)
> >        at
>
> > sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConn...
> > 234)
> >        at java.net.URL.openStream(URL.java:1010)
> >        at
>
> > com.google.appengine.tools.info.RemoteVersionFactory.getVersion(RemoteVersionFactory.java:
> > 76)
> >        at
>
> > com.google.appengine.tools.info.UpdateCheck.checkForUpdates(UpdateCheck.java:
> > 98)
> >        at
> > com.google.appengine.tools.info.UpdateCheck.doNagScreen(UpdateCheck.java:
> > 168)
> >        at
>
> > com.google.appengine.tools.info.UpdateCheck.maybePrintNagScreen(UpdateCheck.java:
> > 136)
> >        at com.google.appengine.tools.development.DevAppServerMain
> > $StartAction.apply(DevAppServerMain.java:158)
> >        at com.google.appengine.tools.util.Parser
> > $ParseResult.applyArgs(Parser.java:48)
> >        at
>
> > com.google.appengine.tools.development.DevAppServerMain.(DevAppServerMain.java:
> > 120)
> >        at
>
> > com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:
> > 96)
> > Caused by: java.security.cert.CertificateException: No name matching
> > appengine.google.com found
> >        at sun.security.util.HostnameChecker.matchDNS(HostnameChecker.java:
> > 210)
> >        at sun.security.util.HostnameChecker.match(HostnameChecker.java:77)
> >        at
>
> > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkIdentity(X509TrustManagerImpl.java:
> > 264)
> >        at
>
> > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:
> > 250)
> >        at
>
> > com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:
> > 1053)
> >        ... 20 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.
>
> --
> Ikai Lan
> Developer Programs Engineer, Google App Engine
> Blog:http://googleappengine.blogspot.com
> Twitter:http://twitter.com/app_engine
> Reddit:http://www.reddit.com/r/appengine

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

[appengine-java] runtime implications of JDO @PersistenceCapable( detachable="true")

2010-06-09 Thread Stevko
Does anyone have experience with the runtime execution/performance
implications of using the JDO annotation  detachable="true" in my
persistent object schema?
--stevko

-- 
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: Using the Gdata Java Client Application Library on GWT and GAE. Authenticating with OAuth.

2010-06-09 Thread drthink
Thanks everyone for your suggestions.  As the text probably read it
was somewhat of a newbie question.  However I have now narrowed down
my error to not including the jars in the \war\WEB-INF\lib\.  So I
have now included the gData Data Apis I need as well as the GData-Core
Jar.

Doh.

Gene

On Jun 9, 12:25 am, ADRA  wrote:
> > The problem is I can't get it to work.  My code is running on the
> > server section of the GWT application, and it fails on the first line
> > where the GoogleOAuthParameters is initialized with a
> > "NoClassDefFoundError".
>
> One of the first 'bugs' I found with App Engine / Eclipse was that it
> wasn't properly deploying eclipse project linked sources. When I first
> started, my projects looked like:
>
> My API Project
>  - src
>    ^
>    | (Project Linked Dependency)
>    |
> My Server Project
>  - src
> 
>
> When the server deployed, it wasn't being deployed with any of the
> classes found in the API. The way I got around it was to 'trick' App
> Engine server to create a linked source with the sources found in the
> dependent project.
>
> So afterwards it looked like:
>
> 
> My API Project
>   - src
>   ^
>   | (Project Linked Dependency)
>   |
> My Server Project
>  - src
>  - MyApi_src (Linked from My API Project / src)
> 
>
> Once done (and keeping both sources in a hacked sync using ant
> builders) the problem with class not found's went away. I don't know
> your project structure, so I'm just guessing you've run into the same
> type of situation... If anyone from Google's listening, it would be
> great if your deployment processor could properly detect eclipse
> project linked dependencies.

-- 
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: TransientFailureException

2010-06-09 Thread skk
MeToo - I get this too -
com.google.appengine.api.labs.taskqueue.TransientFailureException:
Unknown
at
com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:
60)
at

What's worse is that this occurs on a recurrent task that schedules
itself - After failures like this, I end up with 2, 3, sometimes 5
tasks all doing the same thing - the task queue management system
keeps scheduling the failed task..

Luckily, the app is structured so that repeated concurrent runs does
no harm apart from using up CPU. What can I do - apart from monitoring
the queue on a daily basis and purging the extraneous tasks ?

On Jun 3, 3:22 am, Viðar Svansson  wrote:
> I am adding tasks to the defautl queue and frequently get this
> exception frequently.
> What is happening? Can I do anything about it?
>
> Viðar
>
> com.google.appengine.api.labs.taskqueue.TransientFailureException: Unknown
>         at 
> com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:58)
>         at 
> com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:111)
>         at 
> com.google.appengine.api.labs.taskqueue.QueueApiHelper.makeSyncCall(QueueApiHelper.java:32)
>         at 
> com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:278)
>         at 
> com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:250)
>         at 
> com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:235)
>
> On Mon, Apr 12, 2010 at 4:50 PM, Tristan  wrote:
> > Hey,
>
> > I got this exception twice yesterday. Is there anything in my control
> > that may be causing it? Or should I just wrap it up and retry if this
> > happens? (the task has successfully queued and executed hundreds of
> > times)
>
> > Uncaught exception from servlet
> > com.google.appengine.api.labs.taskqueue.TransientFailureException:
> > Unknown
> >        at
> > com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:
> > 58)
> >        at
> > com.google.appengine.api.labs.taskqueue.QueueApiHelper.translateError(QueueApiHelper.java:
> > 111)
> >        at
> > com.google.appengine.api.labs.taskqueue.QueueApiHelper.makeSyncCall(QueueApiHelper.java:
> > 32)
> >        at
> > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:
> > 278)
> >        at
> > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:
> > 250)
> >        at
> > com.google.appengine.api.labs.taskqueue.QueueImpl.add(QueueImpl.java:
> > 235)
>
> > Tristan
>
> > --
> > 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] Re: Using the Gdata Java Client Application Library on GWT and GAE. Authenticating with OAuth.

2010-06-09 Thread Grijesh Maurya
Hi drthink ,

The class 'com/google/gdata/client/
authn/oauth/GoogleOAuthParameters ' causing the exception is contained
in gdata-core-1.0.jar jar file.
Make sure the jar is on your classpath.

Thanks


On Jun 9, 3:01 am, drthink  wrote:
> I am building a GWT-GAE-Java application that imports Google Contacts
> using the GData Java Client library.  I am following this example
> here:  http://code.google.com/apis/gdata/docs/auth/oauth.html
>
> I am attempting the first stage of this demo where I create a URL the
> user gets redirected to to authenticate my application to extract
> contact data.
>
> The problem is I can't get it to work.  My code is running on the
> server section of the GWT application, and it fails on the first line
> where the GoogleOAuthParameters is initialized with a
> "NoClassDefFoundError".
>
> I have tried changing this every which way and I am pulling my
> proverbial hair out.
>
> I recognize that there is a GWT-Client library for managing this
> process from the client side of GWT, but I don't want to use that as
> it doesn't use oAuth.
>
> Any ideas?
>
> Cheers
> Gene
>
>  CODE
> GoogleOAuthParameters oauthParameters = new GoogleOAuthParameters();
> oauthParameters.setOAuthConsumerKey(CONSUMER_KEY);
> oauthParameters.setOAuthConsumerSecret(CONSUMER_SECRET);
> oauthParameters.setScope("https://docs.google.com/feeds/";);
> oauthParameters.setOAuthCallback("http://www.example.com/
> UpgradeToken.jsp");
>
> GoogleOAuthHelper oauthHelper = new GoogleOAuthHelper(new
> OAuthHmacSha1Signer());
> oauthHelper.getUnauthorizedRequestToken(oauthParameters);
>
> String approvalPageUrl =
> oauthHelper.createUserAuthorizationUrl(oauthParameters);
> System.out.println(approvalPageUrl);
>
> *ERROR
> Jun 8, 2010 2:56:52 PM
> com.google.appengine.tools.development.ApiProxyLocalImpl log
> SEVERE: [1276034212868000] javax.servlet.ServletContext log: Exception
> while dispatching incoming RPC call
> com.google.gwt.user.server.rpc.UnexpectedException: Service method
> 'public abstract com.sohoappspot.scheduler.shared.UserInfo
> com.sohoappspot.scheduler.client.rpc.GreetingService.getUserInformation()
> throws java.lang.IllegalArgumentException' threw an unexpected
> exception: java.lang.NoClassDefFoundError: com/google/gdata/client/
> authn/oauth/GoogleOAuthParameters
>         at
> com.google.gwt.user.server.rpc.RPC.encodeResponseForFailure(RPC.java:
> 378)
>         at
> com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse(RPC.java:
> 581)
>         at
> com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(RemoteServiceServlet.java:
> 188)
>         at
> com.google.gwt.user.server.rpc.RemoteServiceServlet.processPost(RemoteServiceServlet.java:
> 224)
>         at
> com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java:
> 62)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:713)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
>         at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
> 511)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1166)
>         at
> com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:
> 51)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1157)
>         at
> com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
> 43)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1157)
>         at
> com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:
> 122)
>         at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1157)
>         at
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
> 388)
>         at
> org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:
> 216)
>         at
> org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
> 182)
>         at
> org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
> 765)
>         at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:
> 418)
>         at
> com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:
> 70)
>         at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 152)
>         at com.google.appengine.tools.development.JettyContainerService
> $ApiProxyHandler.handle(JettyContainerService.java:349)
>         at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 152)
>         at org.mortbay.jetty.Server.handle(Server.java:326)
>         at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
> 542)
>         at org.mortbay.jetty.HttpConnection
> $RequestHandler.content(HttpConnection.java:938)
>         at org.mortbay

[appengine-java] How to workaround inequality and sort order limitations with JDO query?

2010-06-09 Thread Billy
Hi, I'm trying to do a relatively simple query using appengine(1.3.3)
and JDO.  Basically I want to obtain the "top 10 ranked entities for
the last year".  Assume I have an entity FOO and properties startDate
and rating ...I would normally do this using a query like below:

select from FOO where startDate >= someDate order by rating desc range
0,10;

I understand however that inequality filters must be specified first
in any sort ordering and so this does not work.  So the only way I
know to accomplish this is to query for all FOOs where startDate >=
someDate and then sort them in-memory by rating.  This could work, but
I anticipate a large amount of data in FOO and so I don't want to load
10K records into memory to sort them when I really only the top 10 of
them.

Any other ideas on how to workaround this limitation?  Thanks for your
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] Using jar file with google app engine

2010-06-09 Thread Mahendra Liya
Hello,
Would like to have comments regarding the use of Jar files with google
app engine.
Is there any way to programmatically instantiate multiple instances of
a Jar file on Google App Engine?

Thanking you all in anticipation.
Mahendra Liya.

-- 
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: Using the Gdata Java Client Application Library on GWT and GAE. Authenticating with OAuth.

2010-06-09 Thread ADRA
> The problem is I can't get it to work.  My code is running on the
> server section of the GWT application, and it fails on the first line
> where the GoogleOAuthParameters is initialized with a
> "NoClassDefFoundError".

One of the first 'bugs' I found with App Engine / Eclipse was that it
wasn't properly deploying eclipse project linked sources. When I first
started, my projects looked like:

My API Project
 - src
   ^
   | (Project Linked Dependency)
   |
My Server Project
 - src


When the server deployed, it wasn't being deployed with any of the
classes found in the API. The way I got around it was to 'trick' App
Engine server to create a linked source with the sources found in the
dependent project.


So afterwards it looked like:


My API Project
  - src
  ^
  | (Project Linked Dependency)
  |
My Server Project
 - src
 - MyApi_src (Linked from My API Project / src)


Once done (and keeping both sources in a hacked sync using ant
builders) the problem with class not found's went away. I don't know
your project structure, so I'm just guessing you've run into the same
type of situation... If anyone from Google's listening, it would be
great if your deployment processor could properly detect eclipse
project linked dependencies.

-- 
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] JDO query parameter does not work with UTF-8 string.

2010-06-09 Thread likejy
Hi all,

I'm using JDO.
When I save UTF-8 string on production server, It works fine. and I
can read it without any problems.

While JDO equal(==) and startsWith query for UTF-8 works fine on
development server,
but it does not work on production server.

The following is my test code.


Query query = pm.newQuery(Data.class);
query.setRange(0, 1);
query.setFilter("title == titleParam);
query.declareParameters("String titleParam");
List jdoList = (List)query.execute("한글"); // UTF-8 string

logger.debug("jdoList.size : " + jdoList.size()); // zero.


Is this app-engine bug ? How should I do to solve this problem ?
Thank.

-- 
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] I cannot find my open applications.

2010-06-09 Thread s-soko...@tut.by
Hello,

I cannot find my open applications.

1. I add a new account.
2. I create 2 applications on https://appengine.google.com/start.
3. I see my account on https://www.google.com/accounts/ManageAccount
4. I open the link  App Engine  - My Applications  on the my account
page.
5. The page propose my to create another application, I push button
create and see message "You have * applications remaining.".

- Where are these applications?
- I don't have domain.  Can I use thess application in some default
domain?
- How can I open App console without domain?

Sergei.

-- 
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] Creating GeoPT from a postcode (UK)

2010-06-09 Thread Rob.e.Vans
I would like to create GeoPt from a UK postcode. Is there a java api
to do this?

Alternatively where do people usually get the longitude/latitude from
without hardcoding them?

-- 
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] Queries regarding Google Web Application Project

2010-06-09 Thread arun
Hi all,
I am new to Google App Engine. Pls Help me out...

1. How to create servlet for a google web application project in
eclipse ide. When i tried to create it there is no option to create
it. I have installed the google app engine plugin for eclipse.

2. I tried to print in system console for debugging purposes in my
project, but when using google app engine i am not able to view
anything.

3. I have 2 entity classes which are mapped by OneToMany Relationship,
I use JPA for my project after i uploaded in the app engine and when i
run my project its showing me the following error: Pls help me out for
further reference if needed i ll send my entity classes code.. thank
you

#

org.datanucleus.metadata.MetaDataManager initialiseFileMetaDataForUse:
Found Meta-Data for class com.trains.entities.Ticket but this class is
not enhanced!! Please enhance the class before running DataNucleus.
org.datanucleus.exceptions.NucleusUserException: Found Meta-Data for
class com.trains.entities.Ticket but this class is not enhanced!!
Please enhance the class before running DataNucleus.
at
org.datanucleus.metadata.MetaDataManager.initialiseClassMetaData(MetaDataManager.java:
2225)
at
org.datanucleus.metadata.MetaDataManager.initialiseFileMetaData(MetaDataManager.java:
2176)
at
org.datanucleus.metadata.MetaDataManager.initialiseFileMetaDataForUse(MetaDataManager.java:
881)
at
org.datanucleus.metadata.MetaDataManager.loadPersistenceUnit(MetaDataManager.java:
794)
at
org.datanucleus.jpa.EntityManagerFactoryImpl.initialisePMF(EntityManagerFactoryImpl.java:
488)
at
org.datanucleus.jpa.EntityManagerFactoryImpl.(EntityManagerFactoryImpl.java:
355)
at
org.datanucleus.store.appengine.jpa.DatastoreEntityManagerFactory.(DatastoreEntityManagerFactory.java:
63)
at
org.datanucleus.store.appengine.jpa.DatastorePersistenceProvider.createEntityManagerFactory(DatastorePersistenceProvider.java:
35)
at javax.persistence.Persistence.createFactory(Persistence.java:172)
at
javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:
112)
at
javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:
66)
at com.trains.service.TrainService.(TrainService.java:7)
at com.trains.entities.Train.addTrain(Train.java:90)
at com.trains.addT.doGet(addT.java:33)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:693)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
511)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1166)
at
com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter(ParseBlobUploadFilter.java:
97)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1157)
at
com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter(SaveSessionFilter.java:
35)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1157)
at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
43)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1157)
at
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
388)
at
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:
216)
at
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
182)
at
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
765)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:
418)
at
com.google.apphosting.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:
238)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
542)
at org.mortbay.jetty.HttpConnection
$RequestHandler.headerComplete(HttpConnection.java:923)
at
com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable(RpcRequestParser.java:
76)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at
com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:
135)
at
com.google.apphosting.runtime.JavaRuntime.handleRequest(JavaRuntime.java:
250)
at com.google.apphosting.base.RuntimePb$EvaluationRuntime
$6.handleBlockingRequest(RuntimePb.java:5838)
at com.google.apphosting.base.RuntimePb$EvaluationRuntime
$6.handleBlockingRequest(RuntimePb.java:5836)
at
com.google.net.rpc.impl.BlockingApplicationHandler.handleRequest(BlockingApplicationHandler.java:
24)
at com.google.net.rpc.impl.RpcUtil.runRpcInApplicat

[appengine-java] Restricted class in Google Apps Engine - java.awt.*

2010-06-09 Thread TsEMaNN
Hey developers,

I am currently building an application to transform coordinates
between different coordinate reference systems. The OGC standard I am
currently implementing uses libraries which make use of
java.awt.RenderingHints$Key which is a restricted class in the Google
App Engine. The following exception gets thrown:

Caused by: java.lang.NoClassDefFoundError: java.awt.RenderingHints$Key
is a restricted class. Please see the Google  App Engine developer's
guide for more details.

I would highly appreciate any hints regarding this error.

Best regards,
TsEMaNN

-- 
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] Struts 2 and Google App Engine

2010-06-09 Thread Gaurav Munjal
I clearly followed all the steps given on diff forums about Google App
Engine and Struts 2 still I am getting this error when I am trying to
run the application

java.lang.NoClassDefFoundError: ognl/OgnlRuntime

at com.login.OgnlListener.contextInitialized(OgnlListener.java:18)
at
org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:
548)
at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
at
org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:
1250)
at
org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:
517)
at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:
467)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
50)
at
org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:
130)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
50)
at
org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:
130)
at org.mortbay.jetty.Server.doStart(Server.java:224)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
50)
at
com.google.appengine.tools.development.JettyContainerService.startContainer(JettyContainerService.java:
185)
at
com.google.appengine.tools.development.AbstractContainerService.startup(AbstractContainerService.java:
146)
at
com.google.appengine.tools.development.DevAppServerImpl.start(DevAppServerImpl.java:
219)
at com.google.appengine.tools.development.DevAppServerMain
$StartAction.apply(DevAppServerMain.java:162)
at com.google.appengine.tools.util.Parser
$ParseResult.applyArgs(Parser.java:48)
at
com.google.appengine.tools.development.DevAppServerMain.(DevAppServerMain.java:
113)
at
com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:
89)
Caused by: java.lang.ClassNotFoundException: ognl.OgnlRuntime
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at
com.google.appengine.tools.development.IsolatedAppClassLoader.loadClass(IsolatedAppClassLoader.java:
151)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 19 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] Re: Version not ready error (but it's ready)

2010-06-09 Thread Tristan Slominski
Thank you very much, after upgrading to 1.3.4 it works :)

On Tue, Jun 8, 2010 at 18:13, Don Schwarz  wrote:

> What version of the SDK are you using?  I believe that this deadline was
> increased significantly in 1.3.4.
>
>
> On Tue, Jun 8, 2010 at 10:39 PM, Tristan wrote:
>
>> Well??? This problem happens EVERY time I deploy these days. As a
>> result Google App Engine has become USELESS as a hosting solution.
>> Any plans to fix this? Anything I can do on my side so that my uploads
>> work?
>>
>> On Jun 7, 4:59 pm, Tristan  wrote:
>> > I keep on getting this during deployment:
>> >
>> > Deploying newversion.
>> > Will check again in 1 seconds
>> > Will check again in 2 seconds
>> > Will check again in 4 seconds
>> > Will check again in 8 seconds
>> > Will check again in 16 seconds
>> > Will check again in 32 seconds
>> > Will check again in 64 seconds
>> > Will check again in 128 seconds
>> > Rolling back the update.
>> > java.lang.RuntimeException:Versionnot ready.
>> >
>> > This happens almost every time I deploy. The thing is, the application
>> > code deploys just fine, but this error prevents any updates to indexes
>> > or queues.
>> >
>> > In summary, the newversiongets deployed to the app engine just fine.
>> > I can set it as defaultversionand it works. What breaks is that any
>> > queues or indexes are not updated because they never get uploaded due
>> > to the above error.
>> >
>> > Please 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.
>>
>>
>  --
> 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.



Re: [appengine-java] Re: Fwd: JPA entity listner callbacks are not invoked when using Query API

2010-06-09 Thread Sudhir Ramanandi
Thanks Simon, I will have a look at Objectify.. However I am more inclined
toward using JPA..

Thanks
SN

On Wed, Jun 9, 2010 at 7:21 PM, Simon  wrote:

> If you're not trying to write a cross-platform app, I'd really
> recommend giving Objectify or one of the alternatives (Twig, SimpleDS)
> a try.
>
> My conversion from JPA to Objectify took me very little time,
> primarily due to the excellent documentation.  Spin-up time on GAE
> reduced significantly as well!
>
> On Jun 9, 10:17 am, Sudhir Ramanandi  wrote:
> > Really.. using JPA has been a tragedy for me...  I doubt if a real
> project
> > can be built on App engine's current JPA support..
> >
> >
> >
> >
> >
> > On Wed, Jun 9, 2010 at 2:03 PM, Simon  wrote:
> > > I've had the same problem and to be honest my solution was to move
> > > away from using JPA onto Objectify - at least there I know what is
> > > happening, rather than relying on a partial implementation of the JPA
> > > spec.  It's much better suited to the underlying datastore anyway,
> > > since JPA just isn't a good fit for BigTable.
> >
> > > On Jun 8, 10:10 am, Sudhir Ramanandi  wrote:
> > > > Ohh, sorry.. in the example, I gave a wrong class name
> > > > "UnownedRelationLoader"
> > > > Its FooEntityListner and still it does not work
> >
> > > > public class FooEntityListner {
> > > > public void postLoad(BaseEntity entity) {
> > > > ---
> >
> > > > }
> > > > -- Forwarded message --
> > > > From: Sudhir Ramanandi 
> > > > Date: Tue, Jun 8, 2010 at 2:37 PM
> > > > Subject: JPA entity listner callbacks are not invoked when using
> Query
> > > API
> > > > To: google-appengine-java@googlegroups.com
> >
> > > > When an entity is loaded using query, postLoad() call back is not
> > > invoked.
> > > > postLoad() works only with entityManager.find(clazz, id)
> >
> > > > As per the JPA specification:
> > > > "The PostLoad method is invoked before a query result is returned or
> > > > accessed or before an association is traversed."
> >
> > > > Example:
> >
> > > > @EntityListeners(value={FooEntityListner.class})
> > > > @Entity
> > > > public class Foo extends BaseEntity {
> >
> > > > }
> >
> > > > public class UnownedRelationLoader {
> > > > public void postLoad(BaseEntity entity) {
> > > > ---
> > > > }
> >
> > > > Query q = getEntityManager().createQuery("select from " +
> > > > Foo.class.getName());
> >
> > > > callback will not be called in above case.
> >
> > > > Reported the issue herehttp://
> > > code.google.com/p/googleappengine/issues/detail?id=3326
> > > > Please vote for it.
> >
> > > > --
> > > > Sudhir Ramanandihttp://www.ramanandi.org
> >
> > > > --
> > > > Sudhir Ramanandihttp://www.ramanandi.org-Hide quoted text -
> >
> > > > - Show quoted text -
> >
> > > --
> > > 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.
> >
> > --
> > Sudhir Ramanandihttp://www.ramanandi.org- Hide quoted text -
> >
> > - Show quoted text -
>
> --
> 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.
>
>


-- 
Sudhir Ramanandi
http://www.ramanandi.org

-- 
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: Sessions - Working in request scope, not persisting between requests

2010-06-09 Thread klonq
** RESOLVED **

I turned the log level down to debug and found that AppEngine was
throwing Exceptions in the destroy methods of one of its filters.
Which is why the objects weren't being saved to session.

I resolved the exceptions and everything works fine.

Hope this helps someone down the line.





On Jun 8, 10:40 pm, klonq  wrote:
> I have a problem with sessions. This is not a new problem it has been
> something that has been bugging me since I started developing for GAE,
> I am using SDK 1.3.3.1
>
> Things I have done:
> 1. Enabled sessions in app-engine.xml with true sessions-enabled>.
> 2. Implemented Serializable in the objects I would like to persist.
> 3. RTFM but there's only one paragraph and it doesn't give much away.
>
> For example I am using flash messages to give feedback to the user:
>
> if (email.send()) {
>     flash = new FlashMessage(FlashMessage.SUCCESS, "Your message has
> been sent");
>     session.setAttribute(FlashMessage.SESSION_KEY, flash);
>     response.sendRedirect(URL.HOME);} else {
>
>     flash = new FlashMessage(FlashMessage.ERROR,
> FlashMessage.INVALID_FORM_DATA);
>     session.setAttribute(FlashMessage.SESSION_KEY, flash);
>
> getServletContext().getRequestDispatcher( 
> CONTACT_FORM).forward(request,response);
>
> }
>
> When the request is forwarded to a JSP via
> getRequestDispatcher.forward() the flash message displays like its
> supposed to. When the request is redirected via
> response.sendRedirect() nothing happens. The message is displayed via
> the same JSP template in both scenarios as follows:
>
> <%   if (session.getAttribute(FlashMessage.SESSION_KEY) != null) {
>            FlashMessage flash =
> (FlashMessage)session.getAttribute( FlashMessage.SESSION_KEY);
> %>
> <%= flash.display() %>
> <% } %>
>
> The class FlashMessage is included below:
>
> import java.io.Serializable;
>
> /**
>  * HTML element used to give feedback to client based on server side
> operations.
>  * The flash message will be displayed as a DIV of class type.
>  */
> public class FlashMessage implements Serializable {
>         private static final long serialVersionUID = 8109520737272565760L;
>
>         /** Session key, where the flash message is stored */
>         public static final String SESSION_KEY = "flashMessage";
>
>         /
> *** *
> Class Types */
>         /** Negative feedback message type */
>         public static final String ERROR = "error";
>         /** Positive feedback message type */
>         public static final String SUCCESS = "success";
>
>         /
> *** *
> Messages */
>         /** Invalid form data */
>         public static final String INVALID_FORM_DATA = "Your request failed
> to validate, please check the fields below.";
>
>         private String message;
>         private String type;
>
>         /**
>          * @param type Message type
>          * @param message Message
>          */
>         public FlashMessage (String type, String message) {
>                 this.type = type;
>                 this.message = message;
>         }
>
>         /**
>          * @return HTML string representing the DIV element of the flash
> message.
>          */
>         public String display(){
>                 return "" + 
> this.message +
> "";
>         }
>
>
>
> }

-- 
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: Fwd: JPA entity listner callbacks are not invoked when using Query API

2010-06-09 Thread Simon
If you're not trying to write a cross-platform app, I'd really
recommend giving Objectify or one of the alternatives (Twig, SimpleDS)
a try.

My conversion from JPA to Objectify took me very little time,
primarily due to the excellent documentation.  Spin-up time on GAE
reduced significantly as well!

On Jun 9, 10:17 am, Sudhir Ramanandi  wrote:
> Really.. using JPA has been a tragedy for me...  I doubt if a real project
> can be built on App engine's current JPA support..
>
>
>
>
>
> On Wed, Jun 9, 2010 at 2:03 PM, Simon  wrote:
> > I've had the same problem and to be honest my solution was to move
> > away from using JPA onto Objectify - at least there I know what is
> > happening, rather than relying on a partial implementation of the JPA
> > spec.  It's much better suited to the underlying datastore anyway,
> > since JPA just isn't a good fit for BigTable.
>
> > On Jun 8, 10:10 am, Sudhir Ramanandi  wrote:
> > > Ohh, sorry.. in the example, I gave a wrong class name
> > > "UnownedRelationLoader"
> > > Its FooEntityListner and still it does not work
>
> > > public class FooEntityListner {
> > > public void postLoad(BaseEntity entity) {
> > > ---
>
> > > }
> > > -- Forwarded message --
> > > From: Sudhir Ramanandi 
> > > Date: Tue, Jun 8, 2010 at 2:37 PM
> > > Subject: JPA entity listner callbacks are not invoked when using Query
> > API
> > > To: google-appengine-java@googlegroups.com
>
> > > When an entity is loaded using query, postLoad() call back is not
> > invoked.
> > > postLoad() works only with entityManager.find(clazz, id)
>
> > > As per the JPA specification:
> > > "The PostLoad method is invoked before a query result is returned or
> > > accessed or before an association is traversed."
>
> > > Example:
>
> > > @EntityListeners(value={FooEntityListner.class})
> > > @Entity
> > > public class Foo extends BaseEntity {
>
> > > }
>
> > > public class UnownedRelationLoader {
> > > public void postLoad(BaseEntity entity) {
> > > ---
> > > }
>
> > > Query q = getEntityManager().createQuery("select from " +
> > > Foo.class.getName());
>
> > > callback will not be called in above case.
>
> > > Reported the issue herehttp://
> > code.google.com/p/googleappengine/issues/detail?id=3326
> > > Please vote for it.
>
> > > --
> > > Sudhir Ramanandihttp://www.ramanandi.org
>
> > > --
> > > Sudhir Ramanandihttp://www.ramanandi.org-Hide quoted text -
>
> > > - Show quoted text -
>
> > --
> > 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.
>
> --
> Sudhir Ramanandihttp://www.ramanandi.org- Hide quoted text -
>
> - Show quoted text -

-- 
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: Performance issue for GAE auto-restart

2010-06-09 Thread Jake
Hey Tin,

Several people were using GAE's built in timing mechanism to ping the
server to accomplish the same thing.  Google came out and officially
discouraged this as it tends to throw off any attempts they are
currently making to fix the problem.  I can't tell people what to do,
but I opted to stop using this hack in the hopes that they will solve
the problem.

Besides, you'll notice that this hack doesn't really work over the
long run.  It will essentially restart your server every minute and
won't really prevent the loading request from falling on your users
instead of on your ping.

Jake

On Jun 8, 1:54 pm, Tin  wrote:
> Hi all:
>
> We have found a temporary solution for this issue:
> Try with an AJAX timer kicking the server (doing nothing), maybe one
> request per minute (or less) and GAE will keep our site / users in the
> same node.
> In our testing it could avoid the GAE web instance reloaded, but if
> the request interval is long, it would cause another Datastore
> performance issue:http://goo.gl/98zkthat will be fixed in near
> future.
>
> More info please refer to here:http://goo.gl/mzQR

-- 
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] Disable URLFetchService cache

2010-06-09 Thread mar_novice
Is there a way to disable urlfetchService cache? When I made a
urlfetch, sometimes, what I get is the cached result.

-- 
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: Fwd: JPA entity listner callbacks are not invoked when using Query API

2010-06-09 Thread Sudhir Ramanandi
Really.. using JPA has been a tragedy for me...  I doubt if a real project
can be built on App engine's current JPA support..

On Wed, Jun 9, 2010 at 2:03 PM, Simon  wrote:

> I've had the same problem and to be honest my solution was to move
> away from using JPA onto Objectify - at least there I know what is
> happening, rather than relying on a partial implementation of the JPA
> spec.  It's much better suited to the underlying datastore anyway,
> since JPA just isn't a good fit for BigTable.
>
> On Jun 8, 10:10 am, Sudhir Ramanandi  wrote:
> > Ohh, sorry.. in the example, I gave a wrong class name
> > "UnownedRelationLoader"
> > Its FooEntityListner and still it does not work
> >
> > public class FooEntityListner {
> > public void postLoad(BaseEntity entity) {
> > ---
> >
> >
> >
> > }
> > -- Forwarded message --
> > From: Sudhir Ramanandi 
> > Date: Tue, Jun 8, 2010 at 2:37 PM
> > Subject: JPA entity listner callbacks are not invoked when using Query
> API
> > To: google-appengine-java@googlegroups.com
> >
> > When an entity is loaded using query, postLoad() call back is not
> invoked.
> > postLoad() works only with entityManager.find(clazz, id)
> >
> > As per the JPA specification:
> > "The PostLoad method is invoked before a query result is returned or
> > accessed or before an association is traversed."
> >
> > Example:
> >
> > @EntityListeners(value={FooEntityListner.class})
> > @Entity
> > public class Foo extends BaseEntity {
> >
> > }
> >
> > public class UnownedRelationLoader {
> > public void postLoad(BaseEntity entity) {
> > ---
> > }
> >
> > Query q = getEntityManager().createQuery("select from " +
> > Foo.class.getName());
> >
> > callback will not be called in above case.
> >
> > Reported the issue herehttp://
> code.google.com/p/googleappengine/issues/detail?id=3326
> > Please vote for it.
> >
> > --
> > Sudhir Ramanandihttp://www.ramanandi.org
> >
> > --
> > Sudhir Ramanandihttp://www.ramanandi.org- Hide quoted text -
> >
> > - Show quoted text -
>
> --
> 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.
>
>


-- 
Sudhir Ramanandi
http://www.ramanandi.org

-- 
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: Fwd: JPA entity listner callbacks are not invoked when using Query API

2010-06-09 Thread Simon
I meant to add, that I asked the same question a few weeks ago with no
resolution -
http://groups.google.com/group/google-appengine-java/browse_thread/thread/5e3b24316423385f/e348c376c2f8e7a8?lnk=gst&q=jpa+callback#e348c376c2f8e7a8

On Jun 9, 9:33 am, Simon  wrote:
> I've had the same problem and to be honest my solution was to move
> away from using JPA onto Objectify - at least there I know what is
> happening, rather than relying on a partial implementation of the JPA
> spec.  It's much better suited to the underlying datastore anyway,
> since JPA just isn't a good fit for BigTable.
>
> On Jun 8, 10:10 am, Sudhir Ramanandi  wrote:
>
>
>
> > Ohh, sorry.. in the example, I gave a wrong class name
> > "UnownedRelationLoader"
> > Its FooEntityListner and still it does not work
>
> > public class FooEntityListner {
> > public void postLoad(BaseEntity entity) {
> > ---
>
> > }
> > -- Forwarded message --
> > From: Sudhir Ramanandi 
> > Date: Tue, Jun 8, 2010 at 2:37 PM
> > Subject: JPA entity listner callbacks are not invoked when using Query API
> > To: google-appengine-java@googlegroups.com
>
> > When an entity is loaded using query, postLoad() call back is not invoked.
> > postLoad() works only with entityManager.find(clazz, id)
>
> > As per the JPA specification:
> > "The PostLoad method is invoked before a query result is returned or
> > accessed or before an association is traversed."
>
> > Example:
>
> > @EntityListeners(value={FooEntityListner.class})
> > @Entity
> > public class Foo extends BaseEntity {
>
> > }
>
> > public class UnownedRelationLoader {
> > public void postLoad(BaseEntity entity) {
> > ---
> > }
>
> > Query q = getEntityManager().createQuery("select from " +
> > Foo.class.getName());
>
> > callback will not be called in above case.
>
> > Reported the issue 
> > herehttp://code.google.com/p/googleappengine/issues/detail?id=3326
> > Please vote for it.
>
> > --
> > Sudhir Ramanandihttp://www.ramanandi.org
>
> > --
> > Sudhir Ramanandihttp://www.ramanandi.org-Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -

-- 
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: Fwd: JPA entity listner callbacks are not invoked when using Query API

2010-06-09 Thread Simon
I've had the same problem and to be honest my solution was to move
away from using JPA onto Objectify - at least there I know what is
happening, rather than relying on a partial implementation of the JPA
spec.  It's much better suited to the underlying datastore anyway,
since JPA just isn't a good fit for BigTable.

On Jun 8, 10:10 am, Sudhir Ramanandi  wrote:
> Ohh, sorry.. in the example, I gave a wrong class name
> "UnownedRelationLoader"
> Its FooEntityListner and still it does not work
>
> public class FooEntityListner {
> public void postLoad(BaseEntity entity) {
> ---
>
>
>
> }
> -- Forwarded message --
> From: Sudhir Ramanandi 
> Date: Tue, Jun 8, 2010 at 2:37 PM
> Subject: JPA entity listner callbacks are not invoked when using Query API
> To: google-appengine-java@googlegroups.com
>
> When an entity is loaded using query, postLoad() call back is not invoked.
> postLoad() works only with entityManager.find(clazz, id)
>
> As per the JPA specification:
> "The PostLoad method is invoked before a query result is returned or
> accessed or before an association is traversed."
>
> Example:
>
> @EntityListeners(value={FooEntityListner.class})
> @Entity
> public class Foo extends BaseEntity {
>
> }
>
> public class UnownedRelationLoader {
> public void postLoad(BaseEntity entity) {
> ---
> }
>
> Query q = getEntityManager().createQuery("select from " +
> Foo.class.getName());
>
> callback will not be called in above case.
>
> Reported the issue 
> herehttp://code.google.com/p/googleappengine/issues/detail?id=3326
> Please vote for it.
>
> --
> Sudhir Ramanandihttp://www.ramanandi.org
>
> --
> Sudhir Ramanandihttp://www.ramanandi.org- Hide quoted text -
>
> - Show quoted text -

-- 
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: Date based sorting and result pagination

2010-06-09 Thread Nacho Coloma
You should specify if you are using JDO, JPA or other. SimpleDS has a
PagedQuery implementation that can be ported to your own environment.
Look for getFetchOptions() in this link:

http://code.google.com/p/simpleds/source/browse/trunk/src/main/java/org/simpleds/PagedQuery.java

This will only resolve the paging, and it's not optimal but convenient
(can jump to a specific page etc). For an optimal solution, use
cursors.

On Jun 9, 7:36 am, RAVINDER MAAN  wrote:
> Hello all
>     how can i get my query result sorted based on creationdate and
> also i want to do pagination for the same.what is the best way to do
> that.can anybody refer me any example code?
> 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] Re: Date based sorting and result pagination

2010-06-09 Thread klonq
http://code.google.com/appengine/docs/java/datastore/queriesandindexes.html

On Jun 9, 7:36 am, RAVINDER MAAN  wrote:
> Hello all
>     how can i get my query result sorted based on creationdate and
> also i want to do pagination for the same.what is the best way to do
> that.can anybody refer me any example code?
> 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] How active is GAE team in fixing bugs?

2010-06-09 Thread Marc Guillemot

Hi,

I wonder how active GAE team is to fix bugs. I see only a very very 
limited activity in the bugs I've reported and in the numerous ones I've 
starred.


Cheers,
Marc.
--
Blog: http://mguillem.wordpress.com

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