[appengine-java] Re: 1.5.1 SDK Prerelease

2011-06-15 Thread nischalshetty
You guys fixed the Struts 2 issue! Thank you so much :)

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



[appengine-java] Re: Failing tasks getting duplicated

2011-04-16 Thread nischalshetty
Pretty weird. Let's hope someone from the GAE team peeps into this thread. I 
have thousands of tasks being generated every minute and there are errors 
when they are executed. I'm hoping they don't get "duplicated". There's no 
way for me to know so if what you say is true then it's trouble for a lot of 
us.

-N

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



[appengine-java] Re: Failing tasks getting duplicated

2011-04-15 Thread nischalshetty
When a task fails, the "same" task would be retried again. Ideally if you 
have just one task in your system and that fails a 100 times at the end of 
the day you should still have only one task in the queue.

Are you sure you do not have any logic in the url that the task calls where 
you create a new task?


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



[appengine-java] Re: How can I make the session to be held open as long as the user got its browser opened?

2011-04-10 Thread nischalshetty
You would need to specify a timeout and if there is no activity for
that time frame sessions would need to expire. To be safe about
expiring sessions and at the same time wanting to keep them alive,
what I can suggest is do this :

Put a simple ajax call on the page. Make it call your app every 20
minutes. That way the sessions would not expire. Just a suggestion,
haven't done anything like that so don't know how good a solution it
is. But to get started quick, I would definitely do this.

-Nischal

On Apr 11, 11:38 am, Daniel  wrote:
> I refer to the one that defined in web.xml
>
>         
>                 30
>         
>
> I want to keep it open as long as the browser is opened at my page...
>
> On Apr 10, 2:10 pm, Didier Durand  wrote:
>
>
>
>
>
>
>
> > Hi,
>
> > You should clarify what you mean by an open session: do you mean the
> > http one defined by the cookie, the security one after login, etc ?
>
> > regards
>
> > didier
>
> > On Apr 10, 9:35 am, Max  wrote:
>
> > > have you tried to use memcache or simply store session into datastore?

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



[appengine-java] Re: Tips/Pitfalls for total newbies?

2011-04-05 Thread nischalshetty
I've been on GAE from the start of 2010. This thread still seems
delicious. Thank you all for posting the wonderful comments.

-N

On Apr 4, 6:03 pm, Drew Spencer  wrote:
> Sounds great Ikai, I'm sure it's going to be a great resource for people in
> my position.
>
> Sorry if my last post sounded like I was saying "Don't just make it a blind
> tutorial". I was just explaining why I made the thread and a few random
> thoughts... rambling basically. Anyway, glad to have created more work for
> you ;)

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



[appengine-java] Re: Lightweight & Best performing MVC framework - Recommendation

2010-12-29 Thread nischalshetty
That was Struts 2, made a mistake in the spelling


-N

On Dec 30, 10:08 am, nischalshetty  wrote:
> Strust 2 , just the default one, without putting in anything unwanted
> into it. I use it for m apphttp://justunfollow.comand seems to work
> well.
>
> -N
>
> On Dec 30, 12:02 am, "Ikai Lan (Google)" 
> wrote:
>
>
>
>
>
>
>
> > Um ... those are like the opposite of lightweight.
>
> > Here are some I like:
>
> > Play Framework: probably the most underrated Java framework I've ever 
> > seehttp://www.playframework.org/
>
> > Slim3: built for App Engine. Cons: kind of needs deep Eclipse 
> > integrationhttp://sites.google.com/site/slim3appengine/
>
> > There are more. I'll post in a bit. What are other frameworks everyone else
> > here likes?
>
> > --
> > Ikai Lan
> > Developer Programs Engineer, Google App Engine
> > Blogger:http://googleappengine.blogspot.com
> > Reddit:http://www.reddit.com/r/appengine
> > Twitter:http://twitter.com/app_engine
>
> > On Wed, Dec 29, 2010 at 10:49 AM, Nasif Noorudeen  wrote:
> > > spring & jsf
>
> > > On 12/29/10, Sree  wrote:
> > > > Hello,
>
> > > > I am new to Java and App Engine, and coming from ASP.NET C# and
> > > > Windows Azure world. I am looking for a lightweight & best performing
> > > > java based MVC framework.  I would like to migrate my ASP.NET MVC
> > > > project to App Engine (Java).
>
> > > > It would be great if you can share your experience.  I am open to
> > > > Python as well, but learning Java is faster than Python, since I am
> > > > good at C#.
>
> > > > Thanks in Advance.
>
> > > > Regards
> > > > Sree
>
> > > > --
> > > > 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 > >  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: Lightweight & Best performing MVC framework - Recommendation

2010-12-29 Thread nischalshetty
Strust 2 , just the default one, without putting in anything unwanted
into it. I use it for m app http://justunfollow.com and seems to work
well.

-N

On Dec 30, 12:02 am, "Ikai Lan (Google)" 
wrote:
> Um ... those are like the opposite of lightweight.
>
> Here are some I like:
>
> Play Framework: probably the most underrated Java framework I've ever 
> seehttp://www.playframework.org/
>
> Slim3: built for App Engine. Cons: kind of needs deep Eclipse 
> integrationhttp://sites.google.com/site/slim3appengine/
>
> There are more. I'll post in a bit. What are other frameworks everyone else
> here likes?
>
> --
> Ikai Lan
> Developer Programs Engineer, Google App Engine
> Blogger:http://googleappengine.blogspot.com
> Reddit:http://www.reddit.com/r/appengine
> Twitter:http://twitter.com/app_engine
>
>
>
>
>
>
>
> On Wed, Dec 29, 2010 at 10:49 AM, Nasif Noorudeen  wrote:
> > spring & jsf
>
> > On 12/29/10, Sree  wrote:
> > > Hello,
>
> > > I am new to Java and App Engine, and coming from ASP.NET C# and
> > > Windows Azure world. I am looking for a lightweight & best performing
> > > java based MVC framework.  I would like to migrate my ASP.NET MVC
> > > project to App Engine (Java).
>
> > > It would be great if you can share your experience.  I am open to
> > > Python as well, but learning Java is faster than Python, since I am
> > > good at C#.
>
> > > Thanks in Advance.
>
> > > Regards
> > > Sree
>
> > > --
> > > 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 > 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: persistent and scalable global atomic counter: not possible with GAE?

2010-12-28 Thread nischalshetty
Have a look at the Datastore "Key" thingy. The keys generated are
unique across the system IMO. Not sure though but that's what I
remember reading somewhere.

-N

On Dec 29, 7:43 am, MG  wrote:
> Hello!
>
> I need to create a global atomic counter (64-bit) in my AppEngine/J
> app. Like
>
> long count = MyCounter.increment()
>
> that will 100% guarantee that count will never ever be the same for
> two different requests, and that I will be able to increment it
> several million times/day initially, and much more if/when traffic
> increases. I do not really care if it skips a number or two
> occasionally: I can live with it returning a value larger than the
> actual number of calls, but I do need absolute uniqueness and
> reasonably linear growth (i.e. is two consecutive calls from a client
> should result in ascending counter values).
>
> Is this possible to do with Google AppEngine? Sharded counters can
> ensure consistent counting, but not unique counts; memcache counters
> can ensure unique increments, but they are perishable and thus
> difficult (impossible?) to properly synchronize with persistent
> storage. Using one entity to read-update in a transaction will not
> scale...
>
> Thanks,
> MG

-- 
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] Appengine blocked in Turkey?

2010-12-13 Thread nischalshetty
I got quite a few emails from users in Turkey saying they're unable to
access my app http://justunfollow.com

I had read a few months back about a DNS problem in Turkey, can
someone shed some light on this?

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



[appengine-java] Re: Best way to get all contacts from Google Contacts API on App Engine

2010-11-01 Thread nischalshetty
Aren't the contacts paginated? You could get the first page then make
subsequent calls for the next pages.

-N

On Oct 29, 8:55 pm, Shaun Clark  wrote:
> In my application I integrate with Google Apps, in this case
> specifically contacts. When you first sign up I want to get all of
> your contacts, but that could be thousands so with App Engine's 30
> second limit I decided to break the problem into pieces and use the
> last modified date to try to download contacts 25 at a time, store the
> last modified date and walk forward from there. The only issue is that
> I have a case where someone imported hundreds of contacts and Google
> marks the update of all the entries to the exact same millisecond for
> all of them.
>
> So there are too many to get through before Google shuts me down and I
> can't ask Google to return a smaller subset. The docs are 
> here:http://code.google.com/apis/contacts/docs/3.0/developers_guide_java.h...
>
> I consider this an App Engine question because if it weren't for the
> 30 seconds limit it would work fine, as it does when I test it locally
> with no cap on the number of entries returned. Thanks in advance!
>
> Shaun

-- 
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: Memory based application, static field, data lost

2010-10-26 Thread nischalshetty
GAE runs multiple instances which means your code would be run on
multiple JVMs as well which means the static field will be multiple as
well. A lot of "as wells" here but I hope you get the point.

Use statics for constants that do not change. For everything else
persist either in memcache or datastore.

-N

On Oct 26, 4:17 pm, yoyo  wrote:
> Thanks for your answear.
>
> So, GOE discard instances in cases of low usage. I didn't know.
>
> My app is an image board, like 4chan.org.
>
> The blowstore api in only available for billing account.
> I can't use the blowstore because my app isn't commercial. I write it
> only for fun and i don't want to pay for it.
>
> I'll use the memcache service. It's not important if some of pictures
> are lost. There is no guarantee, but I hope keep most of pictures into
> it.
> Else... well I'll see.
>
> I've some refactoring to do. Thanks again for your answear.

-- 
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: Problems with plugin for eclipse 3.6

2010-10-03 Thread nischalshetty
Which OS are you using? Windows 7?


On Oct 2, 3:14 pm, srtanoelia  wrote:
> Hi there,
>
> I found this problem while installing gwt kit on eclipse 3.6:
>
> An error occurred while collecting items to be installed
> session context was:(profile=epp.package.jee,
> phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=,
> action=).
> Unable to read repository 
> athttp://dl.google.com/eclipse/plugin/3.6/plugins/com.google.appengine.
> Read timed out
> Unable to read repository 
> athttp://dl.google.com/eclipse/plugin/3.6/plugins/com.google.gwt.eclips
> Read timed out
>
> I am using this update site:http://dl.google.com/eclipse/plugin/3.6
>
> Any help?
> Thanks in advance.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-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 this group alive? If so, I have a question

2010-09-28 Thread nischalshetty
Can you provide a link to the question you might have posted on this
group? If I know of anything I'll try to pitch in ;)

-Nischal

On Sep 28, 7:11 pm, turncom  wrote:
> I would like to make a presentation on Thursday, and I have a
> question.
>
> But I cannot find a user group that seems to be alive.
>
> If you gotta pulse, post something! Lemme know. I'm hot to get
> something going.if I can find a support group.

-- 
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: PayPal Payflow Pro Connection Error

2010-09-25 Thread nischalshetty
Here's everything you need to get started http://is.gd/fsuBr

Works for Credit Card payments as well, although the UI isn't very
"pro-non-paypally" ;)

-N

On Sep 25, 3:17 am, Shaun  wrote:
> I am using Java, are you talking PayPalX? Doesn't that only support
> paypal accounts, i.e. not credit cards? If your code does work with
> credit cards can you post a basic example of your pay method? Thanks
> for the help!
>
> On Sep 23, 10:13 pm, nischalshetty  wrote:
>
>
>
> > Are you on Python or Java?
>
> > I have my app on Java and PayPal provides an official java API for
> > Google Appengine. It works great for me!
>
> > -N
>
> > On Sep 23, 6:42 pm, Shaun  wrote:
>
> > > I think that this is due to Google's limitation for allowing
> > > connections to port 443. But when I try to connect to PayPal for a
> > > payment I get the error:
>
> > > "Transaction Context Errors: Message 1::
> > > [FATAL]RESULT=-1&RESPMSG=Failed to connect to host Input Server 
> > > Uri=https://pilot-payflowpro.paypal.com:443";
>
> > > Is there anyway around this or will this feature be available when
> > > Business Edition goes live? Any help is much appreciate it!
>
> > > Thanks,
>
> > > Shaun

-- 
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: PayPal Payflow Pro Connection Error

2010-09-23 Thread nischalshetty
Are you on Python or Java?

I have my app on Java and PayPal provides an official java API for
Google Appengine. It works great for me!

-N

On Sep 23, 6:42 pm, Shaun  wrote:
> I think that this is due to Google's limitation for allowing
> connections to port 443. But when I try to connect to PayPal for a
> payment I get the error:
>
> "Transaction Context Errors: Message 1::
> [FATAL]RESULT=-1&RESPMSG=Failed to connect to host Input Server 
> Uri=https://pilot-payflowpro.paypal.com:443";
>
> Is there anyway around this or will this feature be available when
> Business Edition goes live? Any help is much appreciate it!
>
> Thanks,
>
> Shaun

-- 
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: Cache questions

2010-09-20 Thread nischalshetty
As far as cache expiry is considered, its a guarantee that the cache
won't expire before the set expiry date (it might still expire in case
of failures etc).

Basically, there's no real guarantee that the cache will expire after
the time that you have set. It's just that it won't expire before the
set time.

-Nischal
http://justunfollow.com

On Sep 21, 1:24 am, Navaneeth Krishnan 
wrote:
> I have a couple of questions wrt Memcache.
>
> 1. Where do I find the javadoc for jcache ? The document seems
> woefully out-of-date
>
> The 
> examples:http://code.google.com/appengine/docs/java/memcache/usingjcache.html
>
> refer to a package net.sf.jsr107.Cache. However, I find that the
> actual package is net.sf.jsr107cache.Cache.
>
> Where do I find the javadoc for net.sf.jsr107cache.Cache ?
>
> 2. In my application, I create a cache with the following property:
>
>                props.put(GCacheFactory.EXPIRATION_DELTA,3600);
>
> Yet, I find that my cache does not expire after an hour. As a matter
> of fact, it does not seem to expire at all !  Objects put in the cache
> stay forever. Is there something I am missing ?
>
> Regards,
> Navaneeth

-- 
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: Problem with struts 2 and GAE

2010-08-24 Thread nischalshetty
Have you added ognl jar to ur classpath?

-Nischal

On Aug 24, 2:24 pm, Andrés Cantos Garrido  wrote:
> Hello, I´m trying to integrate Struts 2 framework in my web app. I´m
> following this tutorial:
>
> http://whyjava.wordpress.com/2009/08/30/creating-struts2-application-...
>
> Although I create an OgnlListener and modify the web.xml with its
> reference, when I deploy the app I have the following error:
>
> java.lang.NoClassDefFoundError: ognl/OgnlRuntime
>         at com.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(Abs 
> tractContainerService.java:
> 147)
>         at
> com.google.appengine.tools.development.DevAppServerImpl.start(DevAppServerI 
> mpl.java:
> 219)
>         at com.google.appengine.tools.development.DevAppServerMain
> $StartAction.apply(DevAppServerMain.java:164)
>         at com.google.appengine.tools.util.Parser
> $ParseResult.applyArgs(Parser.java:48)
>         at
> com.google.appengine.tools.development.DevAppServerMain.(DevAppServer 
> Main.java:
> 113)
>         at
> com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMa 
> in.java:
> 89)
> Caused by: java.lang.ClassNotFoundException: ognl.OgnlRuntime
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>         at
> com.google.appengine.tools.development.IsolatedAppClassLoader.loadClass(Iso 
> latedAppClassLoader.java:
> 151)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
>         ... 19 more
>
> I am a begginer in Struts 2 and GAE and I don´t know how to fix it.
>
> 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: Please help, I'm not able to obtain the oAuth redirect URL from twitter

2010-07-23 Thread nischalshetty
@Keith

One of the two:

1. Either Google's URLfetch is causing problems due to which no http
and https calls are happening OR
2. Twitter has blocked google app engine

Keep a watch on this thread, my hope is as soon as one of the google
devs sees this thread they'll jump into the issue and try to sort
things out. I have started a thread on the twitter dev group too,
please leave your comment there as well so that it catches the twitter
team's attention - 
http://groups.google.com/group/twitter-development-talk/browse_thread/thread/0aca4bedd27a6a2b

-Nischal

On Jul 23, 4:41 pm, Keith  wrote:
> I'm also seeing problems between app engine and twitter. There are a
> also
> a number of complaints from other people as well. I'm also using
> twitter4j
> and it has been working fine for some time and works fine when I use
> it locally.
> Anyone know what's going on?
>
> On Jul 23, 6:25 am, nischalshetty  wrote:
>
>
>
> > @Benjamin
>
> > I am using twitter4j. Its not an issue on my end since the apps been
> > running from 6 months now. And I just ran a check on many other
> > twitter apps hosted on the app engine, none seem to be working.
>
> > Can you share the url of your app?
>
> > -Nischal
>
> > On Jul 23, 10:03 am, Benjamin  wrote:
>
> > > Sorry to hear of your trouble Nischal
>
> > > I'm hitting twitter without any issue from my prod app engine - if it
> > > helps, i've had a lot of success using twitter4j libraries - maybe you
> > > can check them out.
>
> > > The only strange thing about getting an auth token from twitter oauth
> > > from app engine is how you have to direct the user to the
> > > authorization url and hold the token in your session on the server
> > > side while they authorize the app - then continue with the process of
> > > getting an oauth token on the server.
>
> > > On Jul 22, 10:33 pm, nischalshetty  wrote:
>
> > > > Was searching twitter, others seem to be facing the same problem.
> > > > Please treat this on priority, my entire sitehttp://www.justunfollow.com
> > > > is unusable right now due to the error.
>
> > > > A lot of users are stuck due to the error.
>
> > > > -Nischal
>
> > > > On Jul 23, 7:24 am, nischalshetty  wrote:
>
> > > > > To obtain the redirect URL it's an https call to twitter. I'm just not
> > > > > able to obtain it in production.
>
> > > > > However, it works in my development environment on my PC. Please help
> > > > > ASAP, my site gets a lot of users and this is causing problems for all
> > > > > of them :(
>
> > > > > Here's the stack trace :
>
> > > > > twitter4j.TwitterException: Could not fetch 
> > > > > URL:https://twitter.com/oauth/request_token
> > > > >         at 
> > > > > twitter4j.internal.http.HttpClient.request(HttpClient.java:340)
> > > > >         at
> > > > > twitter4j.internal.http.HttpClientWrapper.request(HttpClientWrapper.java:
> > > > > 68)
> > > > >         at
> > > > > twitter4j.internal.http.HttpClientWrapper.post(HttpClientWrapper.java:
> > > > > 99)
> > > > >         at
> > > > > twitter4j.http.OAuthAuthorization.getOAuthRequestToken(OAuthAuthorization.j
> > > > >  ava:
> > > > > 121)
> > > > >         at twitter4j.Twitter.getOAuthRequestToken(Twitter.java:1406)
> > > > >         at
> > > > > justunfollow.manager.impl.JustUnfollowManagerImpl.redirectURL(JustUnfollowM
> > > > >  anagerImpl.java:
> > > > > 60)
> > > > >         at justunfollow.action.Login.authenticate(Login.java:56)
> > > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > > >         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> > > > >         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown 
> > > > > Source)
> > > > >         at java.lang.reflect.Method.invoke(Unknown Source)
> > > > >         at
> > > > > com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M
> > > > >  ethod_
> > > > > $1.run(Method_.java:165)
> > > > >         at java.security.AccessController.doPrivileged(Native Method)
> > > > >         at
> > > > > com.google.apphosting.runtime.security.shared.intercept.jav

[appengine-java] Re: Please help, I'm not able to obtain the oAuth redirect URL from twitter

2010-07-22 Thread nischalshetty
@Benjamin

I am using twitter4j. Its not an issue on my end since the apps been
running from 6 months now. And I just ran a check on many other
twitter apps hosted on the app engine, none seem to be working.

Can you share the url of your app?

-Nischal

On Jul 23, 10:03 am, Benjamin  wrote:
> Sorry to hear of your trouble Nischal
>
> I'm hitting twitter without any issue from my prod app engine - if it
> helps, i've had a lot of success using twitter4j libraries - maybe you
> can check them out.
>
> The only strange thing about getting an auth token from twitter oauth
> from app engine is how you have to direct the user to the
> authorization url and hold the token in your session on the server
> side while they authorize the app - then continue with the process of
> getting an oauth token on the server.
>
> On Jul 22, 10:33 pm, nischalshetty  wrote:
>
>
>
> > Was searching twitter, others seem to be facing the same problem.
> > Please treat this on priority, my entire sitehttp://www.justunfollow.com
> > is unusable right now due to the error.
>
> > A lot of users are stuck due to the error.
>
> > -Nischal
>
> > On Jul 23, 7:24 am, nischalshetty  wrote:
>
> > > To obtain the redirect URL it's an https call to twitter. I'm just not
> > > able to obtain it in production.
>
> > > However, it works in my development environment on my PC. Please help
> > > ASAP, my site gets a lot of users and this is causing problems for all
> > > of them :(
>
> > > Here's the stack trace :
>
> > > twitter4j.TwitterException: Could not fetch 
> > > URL:https://twitter.com/oauth/request_token
> > >         at twitter4j.internal.http.HttpClient.request(HttpClient.java:340)
> > >         at
> > > twitter4j.internal.http.HttpClientWrapper.request(HttpClientWrapper.java:
> > > 68)
> > >         at
> > > twitter4j.internal.http.HttpClientWrapper.post(HttpClientWrapper.java:
> > > 99)
> > >         at
> > > twitter4j.http.OAuthAuthorization.getOAuthRequestToken(OAuthAuthorization.j
> > >  ava:
> > > 121)
> > >         at twitter4j.Twitter.getOAuthRequestToken(Twitter.java:1406)
> > >         at
> > > justunfollow.manager.impl.JustUnfollowManagerImpl.redirectURL(JustUnfollowM
> > >  anagerImpl.java:
> > > 60)
> > >         at justunfollow.action.Login.authenticate(Login.java:56)
> > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > >         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> > >         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> > >         at java.lang.reflect.Method.invoke(Unknown Source)
> > >         at
> > > com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M
> > >  ethod_
> > > $1.run(Method_.java:165)
> > >         at java.security.AccessController.doPrivileged(Native Method)
> > >         at
> > > com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M
> > >  ethod_.privilegedInvoke(Method_.java:
> > > 163)
> > >         at
> > > com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M
> > >  ethod_.invoke_(Method_.java:
> > > 124)
> > >         at
> > > com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M
> > >  ethod_.invoke(Method_.java:
> > > 43)
> > >         at
> > > com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionI
> > >  nvocation.java:
> > > 404)
> > >         at
> > > com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultAct
> > >  ionInvocation.java:
> > > 267)
> > >         at
> > > justunfollow.interceptor.ExceptionInterceptor.intercept(ExceptionIntercepto
> > >  r.java:
> > > 23)
> > >         at com.opensymphony.xwork2.DefaultActionInvocation
> > > $2.doProfiling(DefaultActionInvocation.java:224)
> > >         at com.opensymphony.xwork2.DefaultActionInvocation
> > > $2.doProfiling(DefaultActionInvocation.java:223)
> > >         at
> > > com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStac
> > >  k.java:
> > > 455)
> > >         at
> > > com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocat
> > >  ion.java:
> > > 221)
> > >         at
> > > com.opensymphony.xwork2.inte

[appengine-java] Re: Please help, I'm not able to obtain the oAuth redirect URL from twitter

2010-07-22 Thread nischalshetty
Was searching twitter, others seem to be facing the same problem.
Please treat this on priority, my entire site http://www.justunfollow.com
is unusable right now due to the error.

A lot of users are stuck due to the error.

-Nischal

On Jul 23, 7:24 am, nischalshetty  wrote:
> To obtain the redirect URL it's an https call to twitter. I'm just not
> able to obtain it in production.
>
> However, it works in my development environment on my PC. Please help
> ASAP, my site gets a lot of users and this is causing problems for all
> of them :(
>
> Here's the stack trace :
>
> twitter4j.TwitterException: Could not fetch 
> URL:https://twitter.com/oauth/request_token
>         at twitter4j.internal.http.HttpClient.request(HttpClient.java:340)
>         at
> twitter4j.internal.http.HttpClientWrapper.request(HttpClientWrapper.java:
> 68)
>         at
> twitter4j.internal.http.HttpClientWrapper.post(HttpClientWrapper.java:
> 99)
>         at
> twitter4j.http.OAuthAuthorization.getOAuthRequestToken(OAuthAuthorization.j 
> ava:
> 121)
>         at twitter4j.Twitter.getOAuthRequestToken(Twitter.java:1406)
>         at
> justunfollow.manager.impl.JustUnfollowManagerImpl.redirectURL(JustUnfollowM 
> anagerImpl.java:
> 60)
>         at justunfollow.action.Login.authenticate(Login.java:56)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>         at java.lang.reflect.Method.invoke(Unknown Source)
>         at
> com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M 
> ethod_
> $1.run(Method_.java:165)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at
> com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M 
> ethod_.privilegedInvoke(Method_.java:
> 163)
>         at
> com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M 
> ethod_.invoke_(Method_.java:
> 124)
>         at
> com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.M 
> ethod_.invoke(Method_.java:
> 43)
>         at
> com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionI 
> nvocation.java:
> 404)
>         at
> com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultAct 
> ionInvocation.java:
> 267)
>         at
> justunfollow.interceptor.ExceptionInterceptor.intercept(ExceptionIntercepto 
> r.java:
> 23)
>         at com.opensymphony.xwork2.DefaultActionInvocation
> $2.doProfiling(DefaultActionInvocation.java:224)
>         at com.opensymphony.xwork2.DefaultActionInvocation
> $2.doProfiling(DefaultActionInvocation.java:223)
>         at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStac 
> k.java:
> 455)
>         at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocat 
> ion.java:
> 221)
>         at
> com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept( 
> DefaultWorkflowInterceptor.java:
> 221)
>         at
> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(Metho 
> dFilterInterceptor.java:
> 86)
>         at com.opensymphony.xwork2.DefaultActionInvocation
> $2.doProfiling(DefaultActionInvocation.java:224)
>         at com.opensymphony.xwork2.DefaultActionInvocation
> $2.doProfiling(DefaultActionInvocation.java:223)
>         at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStac 
> k.java:
> 455)
>         at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocat 
> ion.java:
> 221)
>         at
> com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(Validat 
> ionInterceptor.java:
> 150)
>         at
> org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.d 
> oIntercept(AnnotationValidationInterceptor.java:
> 48)
>         at
> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(Metho 
> dFilterInterceptor.java:
> 86)
>         at com.opensymphony.xwork2.DefaultActionInvocation
> $2.doProfiling(DefaultActionInvocation.java:224)
>         at com.opensymphony.xwork2.DefaultActionInvocation
> $2.doProfiling(DefaultActionInvocation.java:223)
>         at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStac 
> k.java:
> 455)
>         at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocat 
> ion.java:
> 221)
>         at
> com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(Co 
> nversion

[appengine-java] Please help, I'm not able to obtain the oAuth redirect URL from twitter

2010-07-22 Thread nischalshetty
To obtain the redirect URL it's an https call to twitter. I'm just not
able to obtain it in production.

However, it works in my development environment on my PC. Please help
ASAP, my site gets a lot of users and this is causing problems for all
of them :(

Here's the stack trace :

twitter4j.TwitterException: Could not fetch URL: 
https://twitter.com/oauth/request_token
at twitter4j.internal.http.HttpClient.request(HttpClient.java:340)
at
twitter4j.internal.http.HttpClientWrapper.request(HttpClientWrapper.java:
68)
at
twitter4j.internal.http.HttpClientWrapper.post(HttpClientWrapper.java:
99)
at
twitter4j.http.OAuthAuthorization.getOAuthRequestToken(OAuthAuthorization.java:
121)
at twitter4j.Twitter.getOAuthRequestToken(Twitter.java:1406)
at
justunfollow.manager.impl.JustUnfollowManagerImpl.redirectURL(JustUnfollowManagerImpl.java:
60)
at justunfollow.action.Login.authenticate(Login.java:56)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at
com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_
$1.run(Method_.java:165)
at java.security.AccessController.doPrivileged(Native Method)
at
com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_.privilegedInvoke(Method_.java:
163)
at
com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_.invoke_(Method_.java:
124)
at
com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_.invoke(Method_.java:
43)
at
com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:
404)
at
com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:
267)
at
justunfollow.interceptor.ExceptionInterceptor.intercept(ExceptionInterceptor.java:
23)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:224)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:223)
at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:
455)
at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:
221)
at
com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:
221)
at
com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:
86)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:224)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:223)
at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:
455)
at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:
221)
at
com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:
150)
at
org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:
48)
at
com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:
86)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:224)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:223)
at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:
455)
at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:
221)
at
com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:
123)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:224)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:223)
at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:
455)
at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:
221)
at
com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:
184)
at
com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:
86)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:224)
at com.opensymphony.xwork2.DefaultActionInvocation
$2.doProfiling(DefaultActionInvocation.java:223)
at
com.opensymphony.xwork2.util.profiling.UtilT

[appengine-java] Re: Please help me with mapping

2010-06-14 Thread nischalshetty
@Tristan thank you. Seems good :)

-Nischal

On Jun 14, 5:50 pm, Tristan  wrote:
> depending on your needs, you *could* keep the 10 most recent updates
> with the user object (or whatever fits within 1MB). Think how the
> first 3 or 4 facebook wall post comments appear right away and then
> you have to click "see more". This way you could have your most recent
> status updates available fast, and then still have all the separate
> ones for archive access.
>
> On Jun 13, 1:59 am, nischalshetty  wrote:
>
>
>
> > yeah, I want to do something similar, guess having it mapped to the
> > User object will make it inefficient. Will take your advice :)
>
> > -N
>
> > On Jun 13, 11:52 am, Prashant  wrote:
>
> > > I am not sure, it depends on what you want to implement.
>
> > > Anyway, storing 10k updates in a single entity will definitely exceed 1mb
> > > limit. Moreover, you wouldn't be needing all the updates at a time, it 
> > > will
> > > be very inefficient implementation if you fetch all updates when you just
> > > need a few (say 10 or 20).
>
> > > Putting updates in a separate class will help you to implement efficient
> > > pagination. It will be easy to add and delete an updates.
>
> > > On 13 June 2010 11:54, nischalshetty  wrote:
>
> > > > Thank you Prashant. I guess that's the second option of disowned
> > > > entities that you are talking about. Is that the best way to do this?
>
> > > > -N
>
> > > > On Jun 13, 11:20 am, Prashant  wrote:
> > > > > you can keep a separate status class, which will store only one update
> > > > per
> > > > > class. Every time user updates her status, create a new update class 
> > > > > and
> > > > > persist it
>
> > > > > Update {
> > > > > private long userid;
> > > > > private string status;
>
> > > > > }
>
> > > > > when you need to display update just fetch all update entities where
> > > > userid
> > > > > == User's id.
>
> > > > > On 13 June 2010 11:44, nischalshetty  
> > > > > wrote:
>
> > > > > > Hi All,
>
> > > > > > I need to clear a few doubts. Let's take an example so that you know
> > > > > > what my doubt is :
>
> > > > > > I have a User object and each user performs an operation - say a
> > > > > > status update.
>
> > > > > > User {
>
> > > > > > private Long id;
>
> > > > > > private List updates;
>
> > > > > > }
>
> > > > > > Now this seems all good but if I'm not wrong Appengine has no
> > > > > > provision for lazy loading. Now my problem is, when a users
> > > > > > StatusUpdate reaches say 100k or more, the List in the above case
> > > > > > would have so many objects in it which I obviously do not need.
>
> > > > > > What solution is better? Make StatusUpdate as an unowned class and
> > > > > > keeping a reference to User? Any thoughts, I hope I am clear with my
> > > > > > requirement.
>
> > > > > > -Nischal
>
> > > > > > --
> > > > > > You received this message because you are subscribed to the Google
> > > > Groups
> > > > > > "Google App Engine for Java" group.
> > > > > > To post to this group, send email to
> > > > > > google-appengine-j...@googlegroups.com.
> > > > > > To unsubscribe from this group, send email to
> > > > > > google-appengine-java+unsubscr...@googlegroups.com > > > > >  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 > > >  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: About System.out.println statement after deploying

2010-06-14 Thread nischalshetty
IMO, it wouldn't have any changes but if you put in a LOT of them then
for obvious reasons they would affect performance.

It isn't a good practice to have syso's in your code for testing. Use
Logger to do that. It's helpful and you can view outputs in the
production environment as well!

-Nischal

On Jun 14, 10:03 pm, drift elysium  wrote:
> hi all,
>
> It's common to use System.out.println statements while testing in the
> development server.
>
> I am curious to know if the statement System.out.println will have any
> pathological effect on the production server (if we forget to comment/remove
> those lines).
>
> Also , is it possible to view our code online after deploying?

-- 
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: Please help me with mapping

2010-06-12 Thread nischalshetty
yeah, I want to do something similar, guess having it mapped to the
User object will make it inefficient. Will take your advice :)

-N

On Jun 13, 11:52 am, Prashant  wrote:
> I am not sure, it depends on what you want to implement.
>
> Anyway, storing 10k updates in a single entity will definitely exceed 1mb
> limit. Moreover, you wouldn't be needing all the updates at a time, it will
> be very inefficient implementation if you fetch all updates when you just
> need a few (say 10 or 20).
>
> Putting updates in a separate class will help you to implement efficient
> pagination. It will be easy to add and delete an updates.
>
> On 13 June 2010 11:54, nischalshetty  wrote:
>
>
>
> > Thank you Prashant. I guess that's the second option of disowned
> > entities that you are talking about. Is that the best way to do this?
>
> > -N
>
> > On Jun 13, 11:20 am, Prashant  wrote:
> > > you can keep a separate status class, which will store only one update
> > per
> > > class. Every time user updates her status, create a new update class and
> > > persist it
>
> > > Update {
> > > private long userid;
> > > private string status;
>
> > > }
>
> > > when you need to display update just fetch all update entities where
> > userid
> > > == User's id.
>
> > > On 13 June 2010 11:44, nischalshetty  wrote:
>
> > > > Hi All,
>
> > > > I need to clear a few doubts. Let's take an example so that you know
> > > > what my doubt is :
>
> > > > I have a User object and each user performs an operation - say a
> > > > status update.
>
> > > > User {
>
> > > > private Long id;
>
> > > > private List updates;
>
> > > > }
>
> > > > Now this seems all good but if I'm not wrong Appengine has no
> > > > provision for lazy loading. Now my problem is, when a users
> > > > StatusUpdate reaches say 100k or more, the List in the above case
> > > > would have so many objects in it which I obviously do not need.
>
> > > > What solution is better? Make StatusUpdate as an unowned class and
> > > > keeping a reference to User? Any thoughts, I hope I am clear with my
> > > > requirement.
>
> > > > -Nischal
>
> > > > --
> > > > You received this message because you are subscribed to the Google
> > Groups
> > > > "Google App Engine for Java" group.
> > > > To post to this group, send email to
> > > > google-appengine-j...@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > google-appengine-java+unsubscr...@googlegroups.com > > >  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 > 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: Please help me with mapping

2010-06-12 Thread nischalshetty
Thank you Prashant. I guess that's the second option of disowned
entities that you are talking about. Is that the best way to do this?

-N

On Jun 13, 11:20 am, Prashant  wrote:
> you can keep a separate status class, which will store only one update per
> class. Every time user updates her status, create a new update class and
> persist it
>
> Update {
> private long userid;
> private string status;
>
> }
>
> when you need to display update just fetch all update entities where userid
> == User's id.
>
> On 13 June 2010 11:44, nischalshetty  wrote:
>
>
>
> > Hi All,
>
> > I need to clear a few doubts. Let's take an example so that you know
> > what my doubt is :
>
> > I have a User object and each user performs an operation - say a
> > status update.
>
> > User {
>
> > private Long id;
>
> > private List updates;
>
> > }
>
> > Now this seems all good but if I'm not wrong Appengine has no
> > provision for lazy loading. Now my problem is, when a users
> > StatusUpdate reaches say 100k or more, the List in the above case
> > would have so many objects in it which I obviously do not need.
>
> > What solution is better? Make StatusUpdate as an unowned class and
> > keeping a reference to User? Any thoughts, I hope I am clear with my
> > requirement.
>
> > -Nischal
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google App Engine for Java" group.
> > To post to this group, send email to
> > google-appengine-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: Session object or memcache?

2010-06-12 Thread nischalshetty
Session isn't lost but session use is discouraged. You have memcache
which is pretty fast in retrieval. Of course, every once a while even
the memcache can be invalidated due to various reasons. While relying
on memcache you need to be sure that in case the value returned is
null query the datastore.

My app gets high traffic every hour. I do keep the user object in
session and haven't come across any problems yet.

-N

On Jun 13, 6:33 am, Thomas  wrote:
> Session is cached in memcache and persisted to datastore. So when
> loading request occurs it won't be lost if it is not expired. You can
> view session (_ah_SESSION) data with datastore viewer.
>
> On 6月11日, 下午11時09分, Rahul  wrote:
>
>
>
> > No doubt if your application is low traffic you will definitely need
> > memcache as session will be lost every minute when the jvm restarts
> > and you need to reload everything and also session is highly
> > discouraged due to various reasons.
>
> > 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] Please help me with mapping

2010-06-12 Thread nischalshetty
Hi All,

I need to clear a few doubts. Let's take an example so that you know
what my doubt is :

I have a User object and each user performs an operation - say a
status update.

User {

private Long id;

private List updates;

}


Now this seems all good but if I'm not wrong Appengine has no
provision for lazy loading. Now my problem is, when a users
StatusUpdate reaches say 100k or more, the List in the above case
would have so many objects in it which I obviously do not need.

What solution is better? Make StatusUpdate as an unowned class and
keeping a reference to User? Any thoughts, I hope I am clear with my
requirement.

-Nischal

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-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: Records Count

2010-06-11 Thread nischalshetty
For count, you need to implement sharded counters -
http://code.google.com/appengine/articles/sharding_counters.html

The code required to do the same is provided. Just understand what
sharded counters are and make use of the provided code.

-Nischal

On Jun 11, 10:37 pm, Nacho Coloma  wrote:
> GAE already includes a left-like operator (property LIKE 'foo%'). I
> don't know how to use it with JDO though, but it should be in the
> Reference Guide.
>
> For a full LIKE operator (LIKE '%foo%') there is a recent entry in the
> AppEngine 
> blog:http://googleappengine.blogspot.com/2010/04/making-your-app-searchabl...
>
> Hope  this helps.
>
> On Jun 11, 7:12 pm, RAVINDER MAAN  wrote:
>
>
>
> > thanks john
> >    any thought for like operator of sql.how can we implement like operator
> > of sql in GAE
>
> > On Fri, Jun 11, 2010 at 8:49 PM, John Patterson 
> > wrote:
>
> > > The best you could probably do is load into memory a structure that keeps
> > > the employee type for every employee.  When the user types some letters 
> > > of a
> > > name to search for you can perform a keys-only query and lookup the 
> > > employee
> > > type in this structure (rather than load the entity)
>
> > > You would need 2 bits per employee (for 4 types) so even a million
> > > employees would only require 250KB of memory (an array of 30K longs) which
> > > shouldn't take too long to read from memcache when an instance starts.
>
> > > You would then need to iterate over every result and count which type the
> > > employee is.  To optimise this you might cache the counts in memcache of 1
> > > and 2 letter searches.  So then you would only need to count on the fly
> > > three letter searches i.e. all employees with names starting with "smi"
>
> > > On 11 Jun 2010, at 20:53, RAVINDER MAAN wrote:
>
> > > number of employee entities is going to be high .So i guess that
> > > possibility of getting more then 1000 employees for any search is quite
> > > high.
>
> > > On Fri, Jun 11, 2010 at 6:56 PM, John Patterson 
> > > wrote:
>
> > >> A lot depends on how many Employee entities you have.
>
> > >> You could do a sub search for each of the 4 employee types and use COUNT
> > >> to get the results.  This will only work up to 1000 employees per 
> > >> employee
> > >> type.
>
> > >> Twig can execute queries in parallel so this would take no more time than
> > >> running your original query.
>
> > >> On 11 Jun 2010, at 19:39, RAVINDER MAAN wrote:
>
> > >> Thanks for your reply Ravi
> > >>    let me explain the entire scenario.I have an employee entity .User can
> > >> search employees by giving part of name .There are four type of 
> > >> employees .I
> > >> have to show number of employees matching user search criteria for every
> > >> type of employee under different tabs.Actual results are to be displayed
> > >> only if user open that tab.
> > >> In SQL term we could write following query
>
> > >> Select count(*) from employee where name like '%%' and type
> > >> ='A' ;
>
> > >> My first problem is that i dint find any equivalent of like operator.Is
> > >> there any way to do it?
> > >> Secondly we can not keep record count for each search combination.what
> > >> will you suggest for this case?
> > >> Thanks once again.
>
> > >> On Fri, Jun 11, 2010 at 4:23 PM, Ravi  wrote:
>
> > >>> Google app engine designed to work for any numbers of records with in
> > >>> minimum time, so SQL features like counting the records whenever
> > >>> needed is not supported.
> > >>> So you need to take care of such counter by urself at the time of
> > >>> adding or deleting the records in a table/entity.
>
> > >>> If you just want total number of records and dont care if counting
> > >>> happened in last 24 hours then look into low level api for datastore
> > >>> statistics, GAE refreshes total count every 24 hours and you can read
> > >>> the total count from there.
>
> > >>> And if you want count of records with some where clause, then you need
> > >>> to maintain it.
>
> > >>> like if u want like this
> > >>> select count(0) from tb where tb.propA='someValue'
>
> > >>> then you may need to create a new entity say counterForTb, and have
> > >>> few fields entityName and count and where clause columns
> > >>> and whenevr you add a new record in tb then increase the count of that
> > >>> record in counter table and on delete decrease it.
>
> > >>> Something for google guys
> > >>> Just realized that all columns are indexed unless we specify to not to
> > >>> index, and there must be some index meta data/statistics saved
> > >>> somewhere in google data stores about index(like total records
> > >>> matching to this index). And if that stats can be accessible through
> > >>> some APIs then we may be able to get total count just by reading data
> > >>> from indexes stats.
> > >>> Is this something feasible?
>
> > >>> On Jun 11, 11:39 am, RAVINDER MAAN  wrote:
> > >>> > How can we get records count for a query in JDO.
> > >>> > In sql we have select count(*) f

[appengine-java] Intermittent 500 Server Error

2010-05-21 Thread nischalshetty
Hi,

I keep getting 500 server erro at regular intervals. IMO it's the
Google App engine that is facing issues. This is really frustrating
now because my apps usage has increased a lot and I keep getting
complaints about it from users. I am not able to reproduce, there are
no indications about this error in the logs either. There wouldn't be
any log messages because the request never makes it to my app!

Why is the app engine getting more and more unreliable by the day? I'm
a paying customer, can't we have some uptime guarantee!?

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