[appengine-java] Re: Channel API still not live...

2010-10-26 Thread Heiko Roth
No activation yet.
I'm waiting, too.

Right now, we pull status every 5 minutes, but that's not the best
way.
Other APIs like Pushlet don't work on 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...@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: uploaded file how to view in browser

2010-10-26 Thread pman
have u tried - setContentType  method?



On Oct 26, 12:05 pm, prabu prabuc...@gmail.com wrote:
 Hi..
        I was uploaded file(pdf) in Blob it's working fine.and how to
 view uploaded file in browser (Download is working).but image files
 are view in browser I'm using struts framework.

 please help me..

 ThanksRegards
 Prabu

-- 
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: Channel API still not live...

2010-10-26 Thread stole
Thanks everybody for the info. I just needed to see what are the
chances for getting the API activated soon (this week). From Your
answers I'd say very slim.

On Oct 26, 8:16 am, Heiko Roth r...@egotec.com wrote:
 No activation yet.
 I'm waiting, too.

 Right now, we pull status every 5 minutes, but that's not the best
 way.
 Other APIs like Pushlet don't work on 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...@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: SDK/Eclipse pains on Ubuntu

2010-10-26 Thread John
Thanks for the contribution Ed - if you could elaborate (a little) on
what you mean by/what happens for you when you copy the jars into the
project I'd appreciate that.  I've got options selected to run GAE
from my 'WAR' directory, but I'm not aware of any JARs being copied to
my WEB-INF/lib - indeed when they do occasionally get copied, that
stops the datanucleus enrichment from working.  I've also tried with
the 'export' flag set on the build path configuration, with no change
overall.

Some updates/corrections from me:

* The current problem definitely seems to be runtime/classpath/
classloader related - I'm getting ClassNotFound (CNF) exceptions on
JDO implementation classes (i.e. not the implementations, but the
concrete classes needed at runtime).  I'd expect these to be coming
from the GAE class library set - I can find them in jdo-xxx-eb-xx.jar
(sorry for the hazy jar name, I'm in the day job, not in my dev
environment at the time of writing). Annotation/enrichment works fine.
* I'm using an Eclipse Dynamic Web Project, not a Google Web App
Project as originally stated.  As noted before, between SDK upgrades
this works fine so I know that's not a problem.
* I have altered the library order as per other threads (GAE needs to
be before Web App).
* I have seen the thread about long paths in the classpath (known
issue with 1.3.8) - I have copied my plugin/SDK to a much shorter path
location and regconfigured my project and still reproduced the same
runtime CNF problems so that's not the issue.

Given cumulative problems I've experienced with Google's dev
environment/support, I'm now considering ditching the Google approach
and going to a purer, more open cloud hosting model (poss AWS).
Problems for me include:
* facebook apis redundant, but not flagged as such
* no full map/reduce api (got map, but no reduce)
* SDK/plugin instability (this issue)
* interplay problems with GAE and other tools (Vaadin for myself,
looks like Flex also has issues)
* no entry-level adwords/adsense solution for GWT (ajax) front-ends.

Hardly a strong manifesto.

-- 
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: OpenID Accounts with same emails and App Engine User class

2010-10-26 Thread l.denardo
Hello,
to compare Users the only safe field is the unique User ID that is
exposed via getUserId() method.

http://code.google.com/appengine/docs/java/users/overview.html#Accessing_Account_Information

Also getFederatedIdentity()  could be a good bet, but documentation
recommends using the identifier.
I only use the email field after the user has been logged in, and
restricting to Google as a provider. This should be safe enough.
I think the only way to group accounts is to use IDs and set up an
external verification like SMS or email confirmation.

Regards
Lorenzo


On Oct 24, 10:04 pm, trustamli mc2...@gmail.com wrote:
 Hi,

 For some reason my application handles OpenID accounts with same
 emails as one user. It means when I try to
 access datastore entities with User field of new user it also gets
 entities of all other users with the same email.

 Is User object same as email? Pythod documentation says: User
 instances are unique and comparable. If two instances are equal, then
 they represent the same user. (but I use Java).

 I think I'm doing something wrong here:

  Query query = pm.newQuery(Subscriber.class, user == userParam);
  query.declareImports(import com.google.appengine.api.users.User);
  query.declareParameters(User userParam);

 �...@suppresswarnings(unchecked)
  ListSubscriber results = (ListSubscriber) query.execute(user);
  if (results.size()!=0)
     Logger.log(User logged in, results.iterator().next().getId());

 ?

 With this problem using OpenID is very unsafe. Anybody can create an
 OpenID account with any email (for example with myOpenID), without
 email verification, and then log in to my application and get data
 related to all Users with this email.

 I believe I'm doing something wrong, so I'll really hope someone will
 open my eyes.

 Thanks,
 Best Regards.

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



[appengine-java] Re: java.net.InetAddress present in new 1.3.8 SDK but not on live servers

2010-10-26 Thread asianCoolz
may i know in gae, how to you set parameter for   new
LookupService(String databaseFile)  ? do you use blockstore ? what is
the path do you upload the  maxmind dat file?

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



[appengine-java] Re: java.net.InetAddress present in new 1.3.8 SDK but not on live servers

2010-10-26 Thread asianCoolz
may i know in gae, how to you set parameter for   new
LookupService(String databaseFile)  ? do you use blockstore ? what is
the path do you upload the  maxmind dat file?

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



[appengine-java] Re: java.net.InetAddress present in new 1.3.8 SDK but not on live servers

2010-10-26 Thread asianCoolz
may i know in gae, how to you set parameter for   new
LookupService(String databaseFile)  ? do you use blockstore ? what is
the path do you upload the  maxmind dat file?

-- 
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] JSF 2.0 MyFaces problem with Ajax and Command Button

2010-10-26 Thread powell...@gmail.com
I cannot get Ajax to allow navigation to another page when a
h:commandButton is clicked. I use the classic command given in texts
as shown below but Ajax will always display the current page. In the
example below, I want to transition to the page2.xhtml page when I
click but I only get the current page redisplayed. I tried giving ajax
attributes of execute=@form and even render=@form without success.
Is this a known bug.

h:form prependId=false
...
h:commandButton id=button1 action=page2 
   f:ajax /
/h:commandButton
/h:form

Dave

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

2010-10-26 Thread yoyo
Hello everyone.


I've a issue when using my apps.
All my logics application data are in memory.


For exemple, I've a servlet like this :


public class MyServlet {


/** Logic application object, create when the class is loaded by the
sandbox. */
private static Logics myLogic = new Logics();


/** Handle post request */
protected void doPost( [...]) {
myLogic.doStuff([...]);
}
}




The doPost method don't take 30 seconds to be execute.




My issue is this : Few minutes after my servlet is loaded and works,
I've got a new instance of Logics.
I thing AppEngine reload my class.


I haven't read about this kind of comportment. Maybe I haven't read the
docs enough.


Must I use appengine api, like memcache ?


Thanks for reading this newbie appengine developer message.


Have a nice day.

-- 
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] Sharing a PersistenceManagerFactory instance between web application instances

2010-10-26 Thread Ian Marshall
As we all know, the construction of a PersistenceManagerFactory (PMF)
instance that is needed for exchanging data with the datastore is
slow.

To speed up the showing of my home page (which does not need data from
the datastore), my application creates a queued task at launch-time,
which constructs its singleton PMF instance asynchronously. This way,
the creation of my PMF does not add to spin-up (and other?) delays to
app start-up.

Can a PMF instance be shared between application instances?

If so, I could hasten app initialisation by getting an already-
existing PMF instance from the memory cache and only construct one if
it is no longer in the memory cache.

-- 
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] Get number of children from multiple objects

2010-10-26 Thread b...@dutchtape.com
I'm using the datastore of the Google App Engine (DataNucleus). I have
two classes, one Chat and one Rating. A chat can be rated more then
ones so I created an one-many relationship by adding a list to the Chat
class.

Now I want to know the number of unrated chats, so I did the following:


int numberOfChatsInStock = 0;
for(Chat chat : chats){
if(chat.getRatings().size() == 0){
numberOfChatsInStock++;
}
}

This simply iterate through all chats and checks if the number of
ratings is 0.

This solution works well when there are 10 chats, but when I have 500+
chats then the speed is terrible (15 sec +).

I thought maybe the size() method is faster. So I tried
Query.setFilter(ratings.size() == 0) but this gives me the following
error:
Unsupported method size while parsing expression:
InvokeExpression{[PrimaryExpression{ratings}].size(none)}

Is there any way to increase the speed?

-- 
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 Ian Marshall
The GAE datastore is a form of persistent data storage, in that data
stored there will survive the discarding of instances of your
application (GAE will discard instances in cases of low usage).

Data stored in the memory cache can survive the discarding of
instances of your application, but there is no guarantee; data in the
memory cache may be discarded by GAE at any time.

My (Apache Wicket) web sessions are stored by GAE in both the memory
cache (for speed of access) and the datastore (for guarantee of
access) automatically. If you do not have much data, you could store
your data in a web session - but of course this data will have session
scope only - not application instance or all-application-instances
scope.

Since I want to store persistent data, I use the datastore. One could
be clever by using queued tasks to do this somehow, but I cannot be
bothered with the resultant complexity.


On Oct 26, 11:22 am, yoyo yoyomo...@gmail.com wrote:
 Hello everyone.

 I've a issue when using my apps.
 All my logics application data are in memory.

 For exemple, I've a servlet like this :

 public class MyServlet {

 /** Logic application object, create when the class is loaded by the
 sandbox. */
 private static Logics myLogic = new Logics();

 /** Handle post request */
 protected void doPost( [...]) {
 myLogic.doStuff([...]);

 }
 }

 The doPost method don't take 30 seconds to be execute.

 My issue is this : Few minutes after my servlet is loaded and works,
 I've got a new instance of Logics.
 I thing AppEngine reload my class.

 I haven't read about this kind of comportment. Maybe I haven't read the
 docs enough.

 Must I use appengine api, like memcache ?

 Thanks for reading this newbie appengine developer message.

 Have a nice day.

-- 
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] Low-level API: EntityTranslator and DataTypeTranslator

2010-10-26 Thread dominity
Hi, guys.

Is there any information of how could I use these classes in my code?

Best regards, Alexander.

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



Re: [appengine-java] Low-level API: EntityTranslator and DataTypeTranslator

2010-10-26 Thread John Patterson
These are unpublished classes so you should use them at your own  
risk.  They may change in a future release in which case you will get  
NoSuchMethodError exceptions thrown.


You can see how Twig uses them in AyncDatastoreHelper to implement  
async datastore commands.  Twigs implementation protects against  
changes to these classes by capturing errors and retrying the normal  
synchronous commands instead.  So if there are any problems due to  
server side upgrades Twig drops back to normal speed operations that  
are run serially rather than in parallel.


John

On 26 Oct 2010, at 18:02, dominity wrote:


Hi, guys.

Is there any information of how could I use these classes in my code?

Best regards, Alexander.

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


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



[appengine-java] Re: Memory based application, static field, data lost

2010-10-26 Thread yoyo
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: SDK/Eclipse pains on Ubuntu

2010-10-26 Thread John
In the above post not the implementations should read not the
interfaces.  Aw snap! as Chrome says.

-- 
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] Java while statement bug on GAE server?

2010-10-26 Thread doc123
Now I am using GDataI for Java and I tried following code to get Google
document list




DocumentListFeed tempFeed;

tempFeed = myService.getFeed(feedUrl, DocumentListFeed.class);



After I confirmed this code work without problem, I change code as
following to be able to feed more than one page entry, but this code
create Null pointer Exception.



DocumentListFeed tempFeed;

tempFeed = myService.getFeed(feedUrl, DocumentListFeed.class);

resultFeed.getEntries().addAll(tempFeed.getEntries());




while((tempFeed.getNextLink() != null) 
(tempFeed.getEntries().size()0));

{

tempFeed = myService.getFeed(new
URL(tempFeed.getNextLink().getHref()),DocumentListFeed.class);

resultFeed.getEntries().addAll(tempFeed.getEntries());

}



I confirmed that “tempFeed.getNextLink()” is null. But this is a
condition to repeat while. I could not understand why this code fail
and I found suspicious info which related to Java while statement bug
in a following URL. Is this real bug?


http://java.decompiler.free.fr/?q=node/263 after I get info, I changed
my code as following and confirmed this code works without error.



DocumentListFeed tempFeed = this.resultDocListFeed;

DocumentListFeed resultFeed = new DocumentListFeed();

boolean okToFeed = true;



do

{

if(tempFeed != null  tempFeed.getEntries() != null)

{

if(tempFeed.getNextLink() != null  tempFeed.getEntries().size()0)

{

tempFeed = this.docServiceClient.getFeed(new
URL(tempFeed.getNextLink().getHref()),DocumentListFeed.class);

resultFeed.getEntries().addAll(tempFeed.getEntries());

}

else

{

okToFeed = false;

}

}

else

{

okToFeed = false;

}

}while(okToFeed == true);

-- 
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: memcache package not in classpath

2010-10-26 Thread Max
Thanks a lot for sharing 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] Task Queue on other App Servers

2010-10-26 Thread andrew
Anyone out there got an implementation of the TaskQueue working on
other app servers (jetty, tomcat)?

We would like this as an option to ensure portability of our
application between app engine and other options.

Either the same Google TaskQueue code configured to run on another
server, or a compatible implementation.

If not, anyone else looking for the same - who is interested in
sharing the effort of getting that running?

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



[appengine-java] Re: Java while statement bug on GAE server?

2010-10-26 Thread l.denardo
Don't know APIs very well, but anyway it looks like in the while
version you check one link in the condition, then request newLink
again in the method body. At the end of the list you check for the
last element not to be null, then ask for one more (which is out of
list bounds).
You should be missing one page each two anyway...

I guess the do-while version catches this with the tempFeed != null
 tempFeed.getEntries() != null check.

Regards
Lorenzo

On Oct 26, 2:16 pm, doc123 doc.u...@gmail.com wrote:
 Now I am using GDataI for Java and I tried following code to get Google
 document list

 DocumentListFeed tempFeed;

 tempFeed = myService.getFeed(feedUrl, DocumentListFeed.class);

 After I confirmed this code work without problem, I change code as
 following to be able to feed more than one page entry, but this code
 create Null pointer Exception.

 DocumentListFeed tempFeed;

 tempFeed = myService.getFeed(feedUrl, DocumentListFeed.class);

 resultFeed.getEntries().addAll(tempFeed.getEntries());

 while((tempFeed.getNextLink() != null) 
 (tempFeed.getEntries().size()0));

 {

 tempFeed = myService.getFeed(new
 URL(tempFeed.getNextLink().getHref()),DocumentListFeed.class);

 resultFeed.getEntries().addAll(tempFeed.getEntries());

 }

 I confirmed that “tempFeed.getNextLink()” is null. But this is a
 condition to repeat while. I could not understand why this code fail
 and I found suspicious info which related to Java while statement bug
 in a following URL. Is this real bug?

 http://java.decompiler.free.fr/?q=node/263after I get info, I changed
 my code as following and confirmed this code works without error.

 DocumentListFeed tempFeed = this.resultDocListFeed;

 DocumentListFeed resultFeed = new DocumentListFeed();

 boolean okToFeed = true;

 do

 {

 if(tempFeed != null  tempFeed.getEntries() != null)

 {

 if(tempFeed.getNextLink() != null  tempFeed.getEntries().size()0)

 {

 tempFeed = this.docServiceClient.getFeed(new
 URL(tempFeed.getNextLink().getHref()),DocumentListFeed.class);

 resultFeed.getEntries().addAll(tempFeed.getEntries());

 }

 else

 {

 okToFeed = false;

 }
 }

 else

 {

 okToFeed = false;

 }
 }while(okToFeed == true);

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



[appengine-java] Re: Java while statement bug on GAE server?

2010-10-26 Thread doc123
Sorry to use specific sample code. So I tried more basic following code.



try

{

int i =0;

boolean tempFlag = false;




while(tempFlag == true);

{

i++;

out.println(tempFlag + i + := + tempFlag);

tempFlag = false;

}

}

catch(Exception e)

{

out.println(Error + e.toString());

}





what I got is tempFlag1:=false but out.print is within a
while(tempFlag == true) bock.


I think this is bug.

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



[appengine-java] Re: Java while statement bug on GAE server?

2010-10-26 Thread l.denardo
Really looks like a bug. Test condition should fail without printing
anything, in fact.
Sorry for my misleading answer, and thanks for sharing this.

Lorenzo

On Oct 26, 5:22 pm, doc123 doc.u...@gmail.com wrote:
 Sorry to use specific sample code. So I tried more basic following code.

 try

 {

 int i =0;

 boolean tempFlag = false;

 while(tempFlag == true);

 {

 i++;

 out.println(tempFlag + i + := + tempFlag);

 tempFlag = false;

 }
 }

 catch(Exception e)

 {

 out.println(Error + e.toString());

 }

 what I got is tempFlag1:=false but out.print is within a
 while(tempFlag == true) bock.

 I think this is bug.

-- 
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: Java while statement bug on GAE server?

2010-10-26 Thread Don Schwarz
Yes, it's a bug in your code:

 while(tempFlag == true);

Note the semicolon.  Try removing it.

On Tue, Oct 26, 2010 at 10:22 AM, doc123 doc.u...@gmail.com wrote:
 Sorry to use specific sample code.  So I tried more basic following code.

 try
 {

 int i =0;

 boolean tempFlag = false;

 while(tempFlag == true);

 {

 i++;

 out.println(tempFlag + i + := + tempFlag);

 tempFlag = false;

 }

 }
 catch(Exception e)
 {

 out.println(Error + e.toString());

 }

 what I got is  tempFlag1:=false  but out.print is within a while(tempFlag
 == true) bock.
 I think this is bug.



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


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



[appengine-java] Re: Java while statement bug on GAE server?

2010-10-26 Thread l.denardo
I need a good pair of glasses :-)

On Oct 26, 5:42 pm, Don Schwarz schwa...@google.com wrote:
 Yes, it's a bug in your code:

  while(tempFlag == true);

 Note the semicolon.  Try removing it.

 On Tue, Oct 26, 2010 at 10:22 AM, doc123 doc.u...@gmail.com wrote:
  Sorry to use specific sample code.  So I tried more basic following code.

  try
  {

  int i =0;

  boolean tempFlag = false;

  while(tempFlag == true);

  {

  i++;

  out.println(tempFlag + i + := + tempFlag);

  tempFlag = false;

  }

  }
  catch(Exception e)
  {

  out.println(Error + e.toString());

  }

  what I got is  tempFlag1:=false  but out.print is within a while(tempFlag
  == true) bock.
  I think this is bug.

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

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



[appengine-java] Re: 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 yoyomo...@gmail.com 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] index stuck in Building status

2010-10-26 Thread gabriel munteanu
Hi, i have appid ringojsblog, and there are 2 indexes with status
Building for over half an hour.
i have ~ 20 entities, that is all.

Thank you 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] Eclipse plugin insists on copying DataNucleus jars to war/WEB-INF/lib

2010-10-26 Thread Maxim Veksler
Hello,

My project needs only 2 jars from GAE/J:
appengine-api-1.0-sdk-1.3.8.jar
appengine-api-labs-1.3.8.jar

The rest of the jars supplied by the plugin are API's that are not used by
our application and thus not required as part of the deployment:
appengine-jsr107cache-1.3.8.jar
datanucleus-appengine-1.0.7.final.jar
datanucleus-core-1.1.5.jar
datanucleus-jpa-1.1.5.jar
geronimo-jpa_3.0_spec-1.1.1.jar
geronimo-jta_1.1_spec-1.1.1.jar
jdo2-api-2.3-eb.jar
jsr107cache-1.1.jar


I've tried to delete these jars and deployed the app to GAE/J -- It works
great and the application is running happily ever after.

The thing is GAE Eclipse plugin insists on recopying the jars to the project
war/WEB-INF/lib folder (* it's unclear the when it decides to do so).
I even tried to edit the values of filesCopiedToWebInfLib from the settings
file .settings/com.google.appengine.eclipse.core.prefs which also did not
help (further more -- The plugin just updated this entry back to it's
original state... why put a configuration option if you ignore it?)

I want these jars removed for 2 reasons:
- 1. It makes the project lighter, removes clutter and is generally better
to pull small project over wire.
- 2. I remember reading in the mailing list that fewer jars help improve the
application cold start times. I'm not talking about projects like spring
that have large startup penalty but simply having jar flles in the
classpath. Don't know if this is true and I haven't done any benchmarks to
verify this. OTOH to be on the safe side -- Why test if I can simply not
upload the unwanted jars and be done with it?

So, in conclusion - What is the proper method (if any) to instruct GAE
Eclipse Plugin to skip checking and copying of jar's that are basic GAE sdk
jars into my WEB-LIB/lib folder?


Thanks for reading,
Maxim.

-- 
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] Cheapest way to run an SQL EXISTS query with Datastore API?

2010-10-26 Thread Dan Dubois
What is the absolute cheapest way (CPU cost) theoretically to run an
SQL EXISTS query with the Datastore API?

I imagine FetchOptions would be
FetchOptions.Builder.withChunkSize(1).limit(1).prefetchSize(1) and
probably option 1 below.

Query query = new Query(KIND);
//add filters and sorts here, if querying by key use
query.setKeysOnly()
DatastoreService datastoreService =
DatastoreServiceFactory.getDatastoreService();
PreparedQuery pq = datastoreService.prepare(query);

//Option 1
long count =
pq.countEntities(FetchOptions.Builder.withChunkSize(1).limit(1).prefetchSize(1));

if (count == 0) {
//does not exist
}
else {
//exists
}

// or maybe
//Option 2
if (pq.asIterator().hasNext()) {
//exists
}
else {
//does not exist
}

Is there anything cheaper?

Best wishes,
Dan

-- 
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: index stuck in Building status

2010-10-26 Thread gabriel munteanu
after more digging, i guess it was due to changing versions in the
admin interface while indexes were building up.
after a new deploy on the same version, it was all ok in 1 minute.

On Tue, Oct 26, 2010 at 7:18 PM, gabriel munteanu jajali...@gmail.com wrote:
 Hi, i have appid ringojsblog, and there are 2 indexes with status
 Building for over half an hour.
 i have ~ 20 entities, that is all.

 Thank you in advance




-- 
jgabios
http://bash.editia.info

-- 
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] upload_data to dev server failing --- Cookie name Path is a reserved token

2010-10-26 Thread Brian Hill
I have successfully used appcfg.py upload_data to get lots of data onto
my app at appspot.google.com.


Now, I'd like to have the same, complete dataset on my development
server. However, each attempt of appcfg.py to hit the development
server is failing. A clue is that it is generating a server log:

[WARN] java.lang.IllegalArgumentException: Cookie name Path is a
reserved token



Here is the full command:



appcfg.py --config_file=configuration.kind2.yaml
--application=myappid --url=http://localhost:/_ah/remote_api
--no_cookies --filename=datafilename --kind=data kind
--log_file=tmp/bulkloader.log --db_filename=tmp/bulkloader.sql3
upload_data


I'm on the latest and greatest of just about everything and am stumped
now. Versions are below. Ideas are welcome.


Again, the same script --- except for authentication differences ---
has worked over and over again on appspot. ~Brian


Dev server launched by Google App Engine Java SDK 1.3.8 Plugin
Plug-in is running under Eclipse 3.6 Helios SR1.
Yesterday (10/24/2010) I accepted a Java update from Apple, to 13.3.0.
OS is Mac OS X 10.6.4.

-- 
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] key.id - works for me, but is it the right way to go?

2010-10-26 Thread Richard Berger
Building a test application just to learn about GAE/J and things are
working fine (so far), but I am wondering if I am veering off in a
wrong direction.  Here is a simplified statement of the situation...

1. I have an entity class for an entity A
public class A implements Serializable {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Key key;

2. In a JSP page, I display a list of As, with a link to show the full
details of an A.  This link is generated by the JSTL:
a href=/show?aKey=c:out value=${a.key.id} /c:out value=$
{a.key.id} //a/td

3. In the show servlet, I have:
  Long requestKey = Long.parseLong(req.getParameter(aKey));
  Key aKey= KeyFactory.createKey(A, requestKey);
  A a = em.find(A.class, aKey);

As mentioned, it all works fine.  I have used this for both entities
with no parents (as above) and entities owned by a parent.  It just
seems odd to me that I am using something like ${a.key.id} rather than
${a.key}, but ${a.key} gives me the key.toString() value rather than
the KeyFactory.keyToString(key) value.  Also, since I am using JSTL, I
don't know how to use KeyFactory (without using a JSP scriptlet, which
I try (for no particular reason) to avoid.

Is the above ok/safe/fine - or am I abusing GAE and generating major
negative GAE karma which will come back to bite me in the future?  :)

Thanks!
RB

-- 
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: Channel API still not live...

2010-10-26 Thread Ikai Lan (Google)
Very slim. We want to ship it as soon as possible.

In the meantime, there are plenty of services that offer this type of
functionality:

http://beaconpush.com
http://pubnub.com

... and so forth

Don't let this feature block you if your application needs it. Build it
using another tool and port it over when we are ready to release the Channel
API for everyone.

--
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 Tue, Oct 26, 2010 at 12:41 AM, stole goran.stoj...@gmail.com wrote:

 Thanks everybody for the info. I just needed to see what are the
 chances for getting the API activated soon (this week). From Your
 answers I'd say very slim.

 On Oct 26, 8:16 am, Heiko Roth r...@egotec.com wrote:
  No activation yet.
  I'm waiting, too.
 
  Right now, we pull status every 5 minutes, but that's not the best
  way.
  Other APIs like Pushlet don't work on 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...@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com
 .
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.



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



[appengine-java] Re: 1.3.8 Console Logging Issue

2010-10-26 Thread Dan Dubois
I am getting the same problem but still on GWT 2.0.3. It must be an
app engine java dev server problem.

On Oct 25, 6:04 am, vvorski vic...@vorski.com wrote:
 Same here with python on a Mac. Have heard reports of same with Java
 on windows. Seems to be a global1.3.8problem?

 V/.

 On Oct 24, 9:04 pm, jt john.j.tho...@gmail.com wrote:







  Hello,

  I upgraded my project from 1.3.4 to1.3.8. After the upgrade, the
  console fails to log. If I switch back to 1.3.4, the console logs
  properly.

  I am on a 64-bit Windows Vista environment, running Eclipse 3.4.2 w/
  (MyEclipse and Instantiations GWT tools)

  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.



Re: [appengine-java] recommendation on using maxmind geoip

2010-10-26 Thread Ikai Lan (Google)
MaxMind IP was what I used for this example:

http://ikaisays.com/2010/08/11/using-the-app-engine-mapper-for-bulk-data-import/

--
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 Mon, Oct 25, 2010 at 9:02 PM, asianCoolz second.co...@gmail.com wrote:

 may i know what is the preferable way of using maxmind geoip? upload
 the 'binary file' or bulk upload the csv files into bigtable?  the
 prior technique will slow down application startup time?

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



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



Re: [appengine-java] Sharing a PersistenceManagerFactory instance between web application instances

2010-10-26 Thread Ikai Lan (Google)
No, you can't share a PMF instance between app instances. Constructing this
is slow because it has to do classpath scanning. Note that if you use the
low-level API, application startup time is greatly reduced:

http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/datastore/package-summary.html

--
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 Tue, Oct 26, 2010 at 3:32 AM, Ian Marshall ianmarshall...@gmail.comwrote:

 As we all know, the construction of a PersistenceManagerFactory (PMF)
 instance that is needed for exchanging data with the datastore is
 slow.

 To speed up the showing of my home page (which does not need data from
 the datastore), my application creates a queued task at launch-time,
 which constructs its singleton PMF instance asynchronously. This way,
 the creation of my PMF does not add to spin-up (and other?) delays to
 app start-up.

 Can a PMF instance be shared between application instances?

 If so, I could hasten app initialisation by getting an already-
 existing PMF instance from the memory cache and only construct one if
 it is no longer in the memory cache.

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



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



Re: [appengine-java] Cheapest way to run an SQL EXISTS query with Datastore API?

2010-10-26 Thread Ikai Lan (Google)
The cheapest way is to use the value you are checking for as a datastore
key, then to do a get by key. A query always results in an index operation
followed by a fetch by key, so you are reducing the need for an index
lookup.

--
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 Tue, Oct 26, 2010 at 10:02 AM, Dan Dubois uvico...@gmail.com wrote:

 What is the absolute cheapest way (CPU cost) theoretically to run an
 SQL EXISTS query with the Datastore API?

 I imagine FetchOptions would be
 FetchOptions.Builder.withChunkSize(1).limit(1).prefetchSize(1) and
 probably option 1 below.

Query query = new Query(KIND);
//add filters and sorts here, if querying by key use
 query.setKeysOnly()
DatastoreService datastoreService =
 DatastoreServiceFactory.getDatastoreService();
PreparedQuery pq = datastoreService.prepare(query);

//Option 1
long count =

 pq.countEntities(FetchOptions.Builder.withChunkSize(1).limit(1).prefetchSize(1));

if (count == 0) {
//does not exist
}
else {
//exists
}

// or maybe
//Option 2
if (pq.asIterator().hasNext()) {
//exists
}
else {
//does not exist
}

 Is there anything cheaper?

 Best wishes,
 Dan

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



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



[appengine-java] Re: SDK/Eclipse pains on Ubuntu

2010-10-26 Thread Ed Murphy
If you right-click your appengine project and choose properties from
the contextual menu (or just select the project and select properties
item in the Project menu on the menubar), you get the project
properties. Select the Google in the navbar on the left, then select
App Engine from the tree undeneath it. This shows the App Engine
control panel. It has radio buttons for choosing the version of the SDK
that you want to use. Next to the radio button Use default SDK there
is a configure SDKs link. Select that link, then choose an older SDK
as you default checking it.. Select OK to keep this selection and go
back to the App Engine control panel. Now make sure the Use default
SDK radio button is selected. Then select the OK button to close the
control panel. This _may_ cause the old jars to get copied. If it does,
you will see a progress window popup and then go away. Now re-open the
App Engine control panel. This time, choose the radio button Use
specific SDK and choose the most recent SDK in the pull down that is
just to the right. Select the OK button to close the control panel.
This time you _should_ see the progress window as the IDE copies the
latest SDK jars into your project.


Again, you are basically trying to get the plugin to detect that the
SDK version has changed. If it properly detects this, it will
automatically copy the jars into your project (and you will know this
is happening because it puts up the progress window).



Ed

-- 
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] Class not found in Eclipse

2010-10-26 Thread tleroy
Hello everybody,

I use the appengine eclipse plugin,  I have created a 'Web Application
Project' and a 'Simple Java Project' linked to it. When I launch the
Web Application Project, classes from the Simple project are not
found. Where I have to configure the classpath? I tried in the
'.lauch' file but it doesn't work.

Could you help me?

Merci.

-- 
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: Please anyone from google on this

2010-10-26 Thread Katharina Probst
Hi Gal,

I've looked into this and it appears that your page is indeed getting
indexed properly -- so from Googlebot's perspective, all is good (although
we are looking at modifying Fetch as Googlebot to give you the proper answer
in the future).

Hope this helps!
kathrin



On Fri, Oct 22, 2010 at 11:19 PM, Katharina Probst kpro...@google.comwrote:

 Hi Gal,

 sorry for the delayed response! At first glance, it looks like you're doing
 it right -- I will have to dig a little.

 kathrin


 On Fri, Oct 22, 2010 at 7:24 PM, Gal Dolber gal.dol...@gmail.com wrote:

 Please? Any information on this is appreciated


 On Wed, Oct 20, 2010 at 1:56 PM, Gal Dolber gal.dol...@gmail.com wrote:


 http://www.google.com/support/forum/p/Web+Search/thread?tid=47496ffe5ea01d39hl=en

 I notice that it works ok on gwt's showcase.
 Thanks

 --
 Guit: Elegant, beautiful, modular and *production ready* gwt
 applications.

 http://code.google.com/p/guit/







 --
 Guit: Elegant, beautiful, modular and *production ready* gwt applications.

 http://code.google.com/p/guit/




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




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



[appengine-java] JPA null pointerException at org.datanucleus.store.appengine.EntityUtils.getPkAsKey()

2010-10-26 Thread ferda8
Hi all,


I am new to Google App Engine. I am developing application with GAE and
i am using JPA to access datastore. When I create entity and try to
save into datastore, I get this exception:


java.lang.NullPointerException at
org.datanucleus.store.appengine.EntityUtils.getPkAsKey(EntityUtils.java:152)
at
org.datanucleus.store.appengine.DatastoreFieldManager.getKeyForObject(DatastoreFieldManager.java:625)
at
org.datanucleus.store.appengine.DatastoreFieldManager.getParentKeyFromParentField(DatastoreFieldManager.java:634)
at
org.datanucleus.store.appengine.DatastoreFieldManager.establishEntityGroup(DatastoreFieldManager.java:591)
at
org.datanucleus.store.appengine.DatastorePersistenceHandler.insertPreProcess(DatastorePersistenceHandler.java:343)
at
org.datanucleus.store.appengine.DatastorePersistenceHandler.insertObjects(DatastorePersistenceHandler.java:251)
at
org.datanucleus.store.appengine.DatastorePersistenceHandler.insertObject(DatastorePersistenceHandler.java:240)
at
org.datanucleus.state.JDOStateManagerImpl.internalMakePersistent(JDOStateManagerImpl.java:3185)
at
org.datanucleus.state.JDOStateManagerImpl.flush(JDOStateManagerImpl.java:4513)
at
org.datanucleus.ObjectManagerImpl.flushInternal(ObjectManagerImpl.java:2814)
at org.datanucleus.ObjectManagerImpl.flush(ObjectManagerImpl.java:2754)
at
org.datanucleus.ObjectManagerImpl.preCommit(ObjectManagerImpl.java:2893)
at
org.datanucleus.TransactionImpl.internalPreCommit(TransactionImpl.java:369)
at org.datanucleus.TransactionImpl.commit(TransactionImpl.java:256) at
org.datanucleus.jpa.EntityTransactionImpl.commit(EntityTransactionImpl.java:104)
at
org.datanucleus.store.appengine.jpa.DatastoreEntityTransactionImpl.commit(DatastoreEntityTransactionImpl.java:55)
at
org.springframework.orm.jpa.JpaTransactionManager.doCommit(JpaTransactionManager.java:467)
at
org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:754)
at
org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:723)
at
org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:394)
at
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:117)
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy26.createNewUser(Unknown Source) at
cz.cvut.bakalarka.writerbook.controllers.RegistrationController.registrate(RegistrationController.java:55)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597) at
com.google.appengine.tools.development.agent.runtime.Runtime.invoke(Runtime.java:100)
at
org.springframework.web.bind.annotation.support.HandlerMethodInvoker.doInvokeMethod(HandlerMethodInvoker.java:710)
at
org.springframework.web.bind.annotation.support.HandlerMethodInvoker.invokeHandlerMethod(HandlerMethodInvoker.java:167)
at
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.invokeHandlerMethod(AnnotationMethodHandlerAdapter.java:414)
at
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.handle(AnnotationMethodHandlerAdapter.java:402)
at
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:771)
at
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:716)
at
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:647)
at
org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:563)
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
org.springframework.orm.jpa.support.OpenEntityManagerInViewFilter.doFilterInternal(OpenEntityManagerInViewFilter.java:113)
at
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
at
org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:344)
at
org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:110)
at
org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:84)
at

Re: [appengine-java] Re: Please anyone from google on this

2010-10-26 Thread Gal Dolber
Thank you!
Regards

On Tue, Oct 26, 2010 at 5:51 PM, Katharina Probst kpro...@google.comwrote:

 Hi Gal,

 I've looked into this and it appears that your page is indeed getting
 indexed properly -- so from Googlebot's perspective, all is good (although
 we are looking at modifying Fetch as Googlebot to give you the proper answer
 in the future).

 Hope this helps!
 kathrin



 On Fri, Oct 22, 2010 at 11:19 PM, Katharina Probst kpro...@google.comwrote:

 Hi Gal,

 sorry for the delayed response! At first glance, it looks like you're
 doing it right -- I will have to dig a little.

 kathrin


 On Fri, Oct 22, 2010 at 7:24 PM, Gal Dolber gal.dol...@gmail.com wrote:

 Please? Any information on this is appreciated


 On Wed, Oct 20, 2010 at 1:56 PM, Gal Dolber gal.dol...@gmail.comwrote:


 http://www.google.com/support/forum/p/Web+Search/thread?tid=47496ffe5ea01d39hl=en

 I notice that it works ok on gwt's showcase.
 Thanks

 --
 Guit: Elegant, beautiful, modular and *production ready* gwt
 applications.

 http://code.google.com/p/guit/







 --
 Guit: Elegant, beautiful, modular and *production ready* gwt
 applications.

 http://code.google.com/p/guit/




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



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




-- 
Guit: Elegant, beautiful, modular and *production ready* gwt applications.

http://code.google.com/p/guit/

-- 
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] Handle internal 500 error gracefully

2010-10-26 Thread Peter Liu
In doc for java:

Note: At present, you cannot configure custom error handlers for some
error conditions. Specifically, you cannot customize the 404 response
page when no servlet mapping is defined for a URL, the 403 quota error
page, or the 500 server error page that appears after an App Engine
internal error.

I vaguely remember a few patches ago, there's a way to specify error
page for the 500 internal error? Is it true? If so how to setup the
pages?

I am starting to see this 500 error more consistently in certain
sequence of event (but the log never shows the 500, I suppose this
happens before hitting the JVM).

Sequence of event:
1. HTTP post that triggers an immediate Task Queue task
2. The Task Queue job is immediately called but timing out (it calls
some external URL and can block)
3. The HTTP call in step 1 returns successfully and the client
javascript reload the page, thus triggering another request. This
request triggers the 500 error.

I am guessing request #3 give 500 because the server is busy on #2 and
app engine couldn't spin up another instance?

I am setting the queue delay to 10 seconds and see if this will
alleviate the problem.

-- 
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: recommendation on using maxmind geoip

2010-10-26 Thread asianCoolz
@Ikai , thank you for responding. I noticed your blog before posting
here. one question, which will faster performance, put the binary in
blockstore and read with new File(..) or use import csv into datastore
like what you did ?

-- 
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: recommendation on using maxmind geoip

2010-10-26 Thread asianCoolz
@Ikai , thank you for responding. I noticed your blog before posting
here. one question, which will faster performance, put the binary in
blockstore and read with new File(..) or use import csv into datastore
like what you did ?

-- 
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] java.io.RandomAccessFile BlockStore

2010-10-26 Thread asianCoolz
may i know how to use java.io.RandomAccessFile to read big file from
BlockStore ?

-- 
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: uploaded file how to view in browser

2010-10-26 Thread prabu
Hi..
   Thanks lot for ur reply

response.setContentType(application/pdf);

response.setHeader(Content-disposition,inline; filename=test.pdf);

OutputStream out = response.getOutputStream();

out.write(fileBlob.getBytes());


In this way i was tried...

-- 
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: uploaded file how to view in browser

2010-10-26 Thread A. Stevko
use Content Type application/octet-stream for download
and Content Type  application/pdf to view

On Tue, Oct 26, 2010 at 9:09 PM, prabu prabuc...@gmail.com wrote:

 Hi..
   Thanks lot for ur reply

 response.setContentType(application/pdf);

 response.setHeader(Content-disposition,inline; filename=test.pdf);

 OutputStream out = response.getOutputStream();

 out.write(fileBlob.getBytes());


 In this way i was tried...

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



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



[appengine-java] Re: recommendation on using maxmind geoip

2010-10-26 Thread asianCoolz
hello @Ikai, is it required to use mapreduce . why not get the byte
stream from blockstore and create  new file(..) ? there is no limit on
new file(..) and byte[] array in gae right?

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



[google-appengine] Fwd: Image Upload

2010-10-26 Thread Massimiliano
Dear All,
could someone help me with this?

Regards

Massimiliano

-- Forwarded message --
From: Massimiliano massimiliano.pietr...@gmail.com
Date: 2010/10/22
Subject: Image Upload
To: google-appengine@googlegroups.com


Dear All,
I'm building a gallery and I'm allowing users to upload their images, but I
want all the images with a specific width in the blobstore. I'm trying to
using the Image Api, but I can't understand how.

This is my code, could someone help me?

class UploadHandler(blobstore_handlers.BlobstoreUploadHandler):
 def post(self):
upload_files = self.get_uploads('File')
blob_info = upload_files[0]
 self.request.get('Nick')
frasi = FRASI()
frasi.frase = self.request.get('Nick')
 frasi.link = blob_info.key()
frasi.put()
self.redirect(/)

Thanks

Max

-- 

My email: massimiliano.pietr...@gmail.com
My Google Wave: massimiliano.pietr...@googlewave.com



-- 

My email: massimiliano.pietr...@gmail.com
My Google Wave: massimiliano.pietr...@googlewave.com

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



[google-appengine] Re: Instances, cold start and pending_ms

2010-10-26 Thread Matija
I am not sure that they are not using tasks or crons for auto-scaling
threshold. Simply because because average latency is simply arithmetic
mean of every instance latency. I have simple user-facing request that
starts chain of 15 tasks. I have cold start for this user-facing
request and second cold start for fifth task. With two instances now
servicing only tasks, average latency is changed because of every task
instance latency and although my task usually have let's say 200 ms
latency, because of this pending_ms time average latency is 662.2 ms.
But who can predict what will happen with 50 clients (this is web
application, not web page) how can I be sure that in this situation
there will not be too big pending time, maybe even
DeadlineExceededException only because of this pending_ms time
included in average latency.

On Oct 26, 3:27 am, Julian Namaro namarojul...@gmail.com wrote:
 The first number is used for average latency, not cpu_ms, and the auto-
 scaling threshold is computed only from user-facing request, not tasks
 or crons.

 Your numbers seems quite good, nothing to worry about I think. Are you
 experiencing a specific problem ?

 On Oct 23, 12:22 am, Matija matija.jerko...@gmail.com wrote:



  3. If my request has these performance data: 188ms 5269cpu_ms
  5133api_cpu_ms.

  Does 188 ms counts for average latency (for new instances) or 5269 ms
  (cpu time) ?

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



[google-appengine] Re: Frequent deadline exceeded errors.

2010-10-26 Thread Carlos Ble
Is there a way to optimize Gae-Django-Helper load time?

Thanks

On 26 oct, 00:37, Geoffrey Spear geoffsp...@gmail.com wrote:
 On Oct 25, 12:37 pm, Carlos Ble ble.jur...@gmail.com wrote:

  This answer does not help Ikai. We are facing this problem even in
  urls that just load and render a simple form.

 ...After your Django install loads 90% of the modules in pypi.

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



[google-appengine] Re: Blobstore upload handler is Base64 encoding strings?

2010-10-26 Thread Kenneth
This is a pretty shocking bug (or lack of documentation?) from
Google.  There doesn't appear to be a consistent way to decode the
post results that come from the BlobstoreUploadHandler.  There was a
bug in the issues list for this but I can't find it.  I should put in
another one really but there doesn't seem to be any point.

What I do is when the user hits the submit button I send the form
results via an ajax request and once that returns I submit the form to
do the file upload.

Pretty sad you have to do that and it means you're requiring
javascript for something that really shouldn't need it.

On Oct 25, 10:49 am, Agustin Horischnik agu...@gmail.com wrote:
 Hey, no luck with this? Did you solve this at all?

 On Aug 31, 12:40 pm, Agustin Horischnik agu...@gmail.com wrote:







  I think I'm having the same issue...

  I have a multi-part form posting to ablobstoreuploadhandler.
  There's four form fields:

  2 input type=file
  1 input type=text
  1 textarea

  Those map to...

  2blobstore.BlobReferenceProperty
  1 StringProperty
  1 TextProperty

  ... respectively, on my model class.

  And the problem is... when I submit an input string such as á é í ó ú
  and ñ, I get: IuEg6SDtIPMg+iBhbmQg8SI=, both on the StringProperty
  and TextProperty.
  At least, this is what I see on the Data viewer or when I output on
  the app.

  Any workarounds you can think of? Anybody else is having this problem?

  On Aug 3, 3:54 pm, ekampf eka...@gmail.com wrote:

   yep..
   It doesnt happend on the local dev server... its definately something
   undocumented happening on AppEngine

   On Aug 3, 10:54 am, alon alon.car...@gmail.com wrote:

it outputs as abase64string? im guessing the post is multi-part post
right?

On Aug 3, 10:39 am, ekampf eka...@gmail.com wrote:

 This happens when text fields are sent via POST and go through the
Blobstoreuploadhandler.
 When English text is used I get the text.
 When Hebrew is used I get abase64string...

 I'm not looking at the datastore dashboard. I'm looking at the actual
 POST data (via logging)

 On Aug 3, 10:18 am, alon alon.car...@gmail.com wrote:

  Does that happen everytime on theblobstoreonly api? or regular text 
  -

   datastore?

  One more thing, there is a huge difference on how the text is being
  displayed on the datastore dashboard. are you sure its being saved 
  as
 base64? the pageencodingfor the production datastore browser is
  massed up and cant display hebrew correctly in oppose to the local 
  dev
  version which has utf8encodingdisplay.

  On Jul 23, 2:09 pm, ekampf eka...@gmail.com wrote:

   I have a form with a file input and a text input field.
   When users type Hebrew text I get aBase64encoded string on the
   server. When typing English I get a nonBase64string.
   On the development server I get a regular Unicode string (what I'd
   expect)

   Cant find any mentions of this in the docs.
   What the behavior I should expect on production? Is this a bug?

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



Re: [google-appengine] mapreduce and cron job

2010-10-26 Thread djidjadji
You must use the control module from the mapreduce module
One line in the doc tells you to chain MR tasks use a done callback
and start a new one with the control submodule.
Use this method to start a task from inside a cron handler
Have a look at mapreduce/control.py and the test code for control.py

from mapreduce import control as mr_control

class MRCronHandler(webapp.RequestHandler):
  def get(self):
mr_control.start_map(
  Name of the task,
  mymr.sometask,
  mapreduce.input_readers.DatastoreInputReader,
  {entity_kind: models.SomeModel,
  },
  mapreduce_parameters={done_callback: /mr-end-task},
)
self.response.headers['Content-Type'] = 'text/plain'
self.response.out.write('MR Cron Started')


2010/10/24 slash ewan...@gmail.com:
 Hi, everybody

     I learned a lot from this group and Nick's blog. Thanks.

     I want to combine mapreduce and cron job in order to run mapping
 automatically. I did lots of search in this group and from other
 resource but I got nothing.

    I'm able to run cron job and mapreduce separately. But I really
 don't know how to combine them. Maybe I missed something really basic.

    Could anyone tell me how to run mapreduce with cron job? I didn't
 find the corresponding url to trigger mapreduce. Thank you.

    PS: I know that it's possible to do this and I subscribe issue 41
 in appengine-mapreduce project.

    Here is the link: 
 http://code.google.com/p/appengine-mapreduce/issues/detail?id=41.

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



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



[google-appengine] Re: Image Upload

2010-10-26 Thread Stephen


On Oct 22, 10:11 pm, Massimiliano massimiliano.pietr...@gmail.com
wrote:
 Dear All,
 I'm building a gallery and I'm allowing users to upload their images, but I
 want all the images with a specific width in the blobstore. I'm trying to
 using the Image Api, but I can't understand how.

 This is my code, could someone help me?

 class UploadHandler(blobstore_handlers.BlobstoreUploadHandler):
  def post(self):
 upload_files = self.get_uploads('File')
 blob_info = upload_files[0]
  self.request.get('Nick')
 frasi = FRASI()
 frasi.frase = self.request.get('Nick')
  frasi.link = blob_info.key()
 frasi.put()
 self


The old way to do it:

  
http://code.google.com/appengine/docs/python/images/overview.html#Transforming_Images_from_the_Blobstore


The new way to do it:

  
http://code.google.com/appengine/docs/python/images/functions.html#Image_get_serving_url

  example: 
http://blog.tinisles.com/2010/08/app-engines-high-performance-image-serving/

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



Re: [google-appengine] Re: Image Upload

2010-10-26 Thread Massimiliano
Great! Thanks!
This is really easy to be used!

2010/10/26 Stephen sdea...@gmail.com



 On Oct 22, 10:11 pm, Massimiliano massimiliano.pietr...@gmail.com
 wrote:
  Dear All,
  I'm building a gallery and I'm allowing users to upload their images, but
 I
  want all the images with a specific width in the blobstore. I'm trying to
  using the Image Api, but I can't understand how.
 
  This is my code, could someone help me?
 
  class UploadHandler(blobstore_handlers.BlobstoreUploadHandler):
   def post(self):
  upload_files = self.get_uploads('File')
  blob_info = upload_files[0]
   self.request.get('Nick')
  frasi = FRASI()
  frasi.frase = self.request.get('Nick')
   frasi.link = blob_info.key()
  frasi.put()
  self


 The old way to do it:


 http://code.google.com/appengine/docs/python/images/overview.html#Transforming_Images_from_the_Blobstore


 The new way to do it:


 http://code.google.com/appengine/docs/python/images/functions.html#Image_get_serving_url

  example:
 http://blog.tinisles.com/2010/08/app-engines-high-performance-image-serving/

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




-- 

My email: massimiliano.pietr...@gmail.com
My Google Wave: massimiliano.pietr...@googlewave.com

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



[google-appengine] Re: mapreduce and cron job

2010-10-26 Thread slash
Thanks a lot, djidjadji. I'll have a try.

On Oct 26, 6:29 pm, djidjadji djidja...@gmail.com wrote:
 You must use the control module from the mapreduce module
 One line in the doc tells you to chain MR tasks use a done callback
 and start a new one with the control submodule.
 Use this method to start a task from inside a cron handler
 Have a look at mapreduce/control.py and the test code for control.py

 from mapreduce import control as mr_control

 class MRCronHandler(webapp.RequestHandler):
   def get(self):
     mr_control.start_map(
       Name of the task,
       mymr.sometask,
       mapreduce.input_readers.DatastoreInputReader,
       {entity_kind: models.SomeModel,
       },
       mapreduce_parameters={done_callback: /mr-end-task},
     )
     self.response.headers['Content-Type'] = 'text/plain'
     self.response.out.write('MR Cron Started')

 2010/10/24 slash ewan...@gmail.com:

  Hi, everybody

      I learned a lot from this group and Nick's blog. Thanks.

      I want to combine mapreduce and cron job in order to run mapping
  automatically. I did lots of search in this group and from other
  resource but I got nothing.

     I'm able to run cron job and mapreduce separately. But I really
  don't know how to combine them. Maybe I missed something really basic.

     Could anyone tell me how to run mapreduce with cron job? I didn't
  find the corresponding url to trigger mapreduce. Thank you.

     PS: I know that it's possible to do this and I subscribe issue 41
  in appengine-mapreduce project.

     Here is the 
  link:http://code.google.com/p/appengine-mapreduce/issues/detail?id=41.

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

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



Re: [google-appengine] Re: java.security.AccessControlException while Accessing a Read-Only HSQLDB Datababse with Hibernate

2010-10-26 Thread Fork Labs
Hello Nacho,

What do you mean by using a datastore?

Regards

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



[google-appengine] Re: Prod Env utils - Interactive Console, Memcache manager, XMPP bot, IncomingMail Stub

2010-10-26 Thread aschmid
thanks for the hint.

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



[google-appengine] Error code 203 - What is meaning of this error

2010-10-26 Thread Matija
I have a rather complex code for traveling salesman problem that is
trowing this error. I have located lines that produce this error and
it is pretty strange.

int[] sequence = new int[dimension];

private void reverse(int i, int j, final int ai[]) {
int i1 = j - i;
if (i1  0)
i1 += dimension;
i1 = i1 / 2 + 1;
int l, k;
for (l = 0; l  i1; l++) {
k = sequence[i];
sequence[i] = sequence[j];
ai[sequence[i]] = i;
//sequence[j] = k;
//ai[sequence[j]] = j;
if (++i = dimension)
i -= dimension;
if (--j  0)
j += dimension;
}
}

If I leave commented this two lines task request finishes with this
performance parameters (ms=842 cpu_ms=97 api_cpu_ms=0).

If I uncomment this two lines I get:

ms=40087 cpu_ms=0 api_cpu_ms=0 exit_code=203 throttle_code=1

A serious problem was encountered with the process that handled this
request, causing it to exit. This is likely to cause a new process to
be used for the next request to your application. If you see this
message frequently, you should contact the App Engine team. (Error
code 203)

Why ?!

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



Re: [google-appengine] Re: Uploading Indexes - Server Error

2010-10-26 Thread Rohit
+1 in the same situation as you.

On Mon, Oct 25, 2010 at 7:49 PM, Eli Jones eli.jo...@gmail.com wrote:

 Oh, the error message it shows when I run appcfg.py update is:

 Your app was updated, but there was an error updating your indexes. Please
 retry later with appcfg.py update_indexes.


 On Mon, Oct 25, 2010 at 10:48 PM, Eli Jones eli.jo...@gmail.com wrote:

 I am able to update my app code with appcfg.py update.. but it always
 throws an error when it gets to the upload indexes part.

 If I try to only update_indexes, I keep getting the error as well:

 Server: appengine.google.com.
 Uploading index definitions.
 Error 500: --- begin server output ---

 Server Error (500)
 A server error has occurred.
 --- end server output ---


 I presume this is a transient issue and will be cleared up soon.. but I
 have nothing else to do while I wait.. so I am posting a message here in
 case some bored soul is watching the list.


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




-- 
Rohit

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



[google-appengine] Index problems. 500 errors when trying to view datatstore indexes. can't update from appcfg.py

2010-10-26 Thread Rohit Jenveja
This morning I vacuumed a bunch of indicies and added some as well. I
was monitoring the datastore indexes page throughout the day and it
was barely moving. I have about 40 gigs worth of data in the datastore
(mostly blobs). It now 500s anytime I try to view the status. I also
tried to appcfg update but it tells me it couldn't update the indexes.
When I do appcfg update_indexes, it returns a 500 as well. Any idea
what's happening?

Thanks,
Rohit

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



[google-appengine] When using an automatically Long id as a key, is it possible the Long value is a zero?

2010-10-26 Thread Tapir
I want to check whethor or not a reference id is invalid by comparing
it with a zero.
Works?

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



[google-appengine] Can't create application

2010-10-26 Thread brian
I just signed up for app engine and validated the account with SMS.
When I try to create my first application nothing happens. I enter a
app id and it says it's available. Then when I click Create
Application it takes me back to the start page with no applications
showing. When I try to add the application again it now says the app
id is not available. I've tried several times with new app ids that
are always available and it doesn't do anything.

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



Re: [google-appengine] Re: Uploading Indexes - Server Error

2010-10-26 Thread supercobra
I got the same this weekend. Was gone after few hours...

--
superco...@gmail.com



On Mon, Oct 25, 2010 at 10:08 PM, Stephen Johnson
onepagewo...@gmail.com wrote:
 I'm getting the same error, but with Java. Also, clicking on Indexes in
 Dashboard goes to error page.
 Stephen

 The error during deploy is:

 Unable to update app: Error posting to URL:
 https://appengine.google.com/api/datastore/index/add?app_id=APPIDversion=VERSION;
 500 Internal Server Error

 Server Error (500)
 A server error has occurred.


 On Mon, Oct 25, 2010 at 7:49 PM, Eli Jones eli.jo...@gmail.com wrote:

 Oh, the error message it shows when I run appcfg.py update is:
 Your app was updated, but there was an error updating your indexes.
 Please retry later with appcfg.py update_indexes.

 On Mon, Oct 25, 2010 at 10:48 PM, Eli Jones eli.jo...@gmail.com wrote:

 I am able to update my app code with appcfg.py update.. but it always
 throws an error when it gets to the upload indexes part.
 If I try to only update_indexes, I keep getting the error as well:
 Server: appengine.google.com.
 Uploading index definitions.
 Error 500: --- begin server output ---
 Server Error (500)
 A server error has occurred.
 --- end server output ---

 I presume this is a transient issue and will be cleared up soon.. but I
 have nothing else to do while I wait.. so I am posting a message here in
 case some bored soul is watching the list.

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

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


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



[google-appengine] Channel API?

2010-10-26 Thread Blixt
What happened to this? A few months ago it seemed to be just around
the corner, but now I haven't seen any mention on it for ages. I have
been told by a person at Google that I should be able to get access to
the preview somehow, but I never figured out how...

I'm curious about this since I have several projects half-way there
but that got put on ice since I was waiting for the Channel API.

Does anyone know the status of the Channel API, or how to get access
to the preview?

/Blixt

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



[google-appengine] Re: Channel API?

2010-10-26 Thread Blixt
Okay, my initial search returned results from July, but some paging
found this rather recent post:
http://groups.google.com/group/google-appengine/browse_thread/thread/e6efd42c17621d87/cf8e3cbf4d4956b6?lnk=gstq=channel

So I guess that answers one part of my question. My other question:
How do I find out whether I'm on the test list? I filled in the
spreadsheet for it pretty early, but haven't really found any
additional information about it.

/Blixt

On Oct 26, 7:33 pm, Blixt andreasbl...@gmail.com wrote:
 What happened to this? A few months ago it seemed to be just around
 the corner, but now I haven't seen any mention on it for ages. I have
 been told by a person at Google that I should be able to get access to
 the preview somehow, but I never figured out how...

 I'm curious about this since I have several projects half-way there
 but that got put on ice since I was waiting for the Channel API.

 Does anyone know the status of the Channel API, or how to get access
 to the preview?

 /Blixt

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



[google-appengine] Cron scheduling at runtime

2010-10-26 Thread Vibhuti Gupta
Hi

I need to do runtime scheduling for certain tasks in my application. In GAE
we need to modify cron.xml and upload it to the server.
I am using java and am not able to find a way to accomplish this at runtime.
Anyone has any ideas regarding this!!

Regards

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



[google-appengine] Re: Can't create application

2010-10-26 Thread Geoffrey Spear
Access the dashboard from http://appengine.google.com/a/firespotter.com

On Oct 25, 9:36 pm, brian a...@firespotter.com wrote:
 I just signed up for app engine and validated the account with SMS.
 When I try to create my first application nothing happens. I enter a
 app id and it says it's available. Then when I click Create
 Application it takes me back to the start page with no applications
 showing. When I try to add the application again it now says the app
 id is not available. I've tried several times with new app ids that
 are always available and it doesn't do anything.

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



[google-appengine] Re: Can't create application

2010-10-26 Thread brian
Just figured that out. Thanks. It was because I created a Google
Account with my apps account. It probably shouldn't let me create
things from appengine.google.com with my apps account then.

On Oct 26, 11:18 am, Geoffrey Spear geoffsp...@gmail.com wrote:
 Access the dashboard fromhttp://appengine.google.com/a/firespotter.com

 On Oct 25, 9:36 pm, brian a...@firespotter.com wrote:



  I just signed up for app engine and validated the account with SMS.
  When I try to create my first application nothing happens. I enter a
  app id and it says it's available. Then when I click Create
  Application it takes me back to the start page with no applications
  showing. When I try to add the application again it now says the app
  id is not available. I've tried several times with new app ids that
  are always available and it doesn't do anything.

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



Re: [google-appengine] When using an automatically Long id as a key, is it possible the Long value is a zero?

2010-10-26 Thread 风笑雪
The only way is to fetch it.

ReferenceProperty doesn't care about whether the referenced entity is
exist, it just stores a Key object.

--
keakon



On Tue, Oct 26, 2010 at 11:40 PM, Tapir tapir@gmail.com wrote:
 I want to check whethor or not a reference id is invalid by comparing
 it with a zero.
 Works?

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



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



Re: [google-appengine] Re: Channel API?

2010-10-26 Thread Ikai Lan (Google)
You'll receive a notification email if you were added as a tester. We're
trying to get this out as quickly as possible, but I don't have an ETA for
when it will be released. Just be on the lookout for prerelease SDKs.

--
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 Tue, Oct 26, 2010 at 10:39 AM, Blixt andreasbl...@gmail.com wrote:

 Okay, my initial search returned results from July, but some paging
 found this rather recent post:

 http://groups.google.com/group/google-appengine/browse_thread/thread/e6efd42c17621d87/cf8e3cbf4d4956b6?lnk=gstq=channel

 So I guess that answers one part of my question. My other question:
 How do I find out whether I'm on the test list? I filled in the
 spreadsheet for it pretty early, but haven't really found any
 additional information about it.

 /Blixt

 On Oct 26, 7:33 pm, Blixt andreasbl...@gmail.com wrote:
  What happened to this? A few months ago it seemed to be just around
  the corner, but now I haven't seen any mention on it for ages. I have
  been told by a person at Google that I should be able to get access to
  the preview somehow, but I never figured out how...
 
  I'm curious about this since I have several projects half-way there
  but that got put on ice since I was waiting for the Channel API.
 
  Does anyone know the status of the Channel API, or how to get access
  to the preview?
 
  /Blixt

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



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



[google-appengine] Re: java.security.AccessControlException while Accessing a Read-Only HSQLDB Datababse with Hibernate

2010-10-26 Thread nacho
http://code.google.com/intl/es-AR/appengine/docs/java/datastore/

On 26 oct, 11:42, Fork Labs forkl...@gmail.com wrote:
 Hello Nacho,

 What do you mean by using a datastore?

 Regards

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



[google-appengine] Index Stuck?

2010-10-26 Thread ryan baldwin
Hey Googlers,

I have an Index that's been building in the cloud for a few hours now.
Can somebody check to see if it's stuck? App name daily-deal-demo.

Thanks!

Love,

- ryan.

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



[google-appengine] datastore advice?

2010-10-26 Thread Charles
Hi all,

I'm wondering, since the datastore is hierarchical, does the number of
children an entity has affect the performance on querying on the
parents themselves? For example, if I have a set of parents, say...

Jane
Margaret
Graham
Arthur

...and I have a set of children associated with those parents...

Jane
-Sam
-Robert
Margaret
-Lisa
Graham
Arthur
-Rowen
-Jerry

...will the number of children for each parent affect the performance
of querying the parents themselves? For instance, if I wanted to select
all of the parents (SELECT * FROM parents), that would be easy with the
data above. But, since the datastore is hierarchical, does the
performance get hampered if say the parents have many thousands or even
millions of children? Say, like...

Jane
-Sam
-Robert
...1 million more
Margaret
...

If so, I'm just wondering if it would make more sense to make the
children root entities too, so as not to affect the performance of
querying on the parents. Anyways, hope I've explained my question well
enough.

Thanks in advance!


Charles

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



Re: [google-appengine] Re: java.security.AccessControlException while Accessing a Read-Only HSQLDB Datababse with Hibernate

2010-10-26 Thread Fork Labs
Hello Nacho,

The values I want to access with Hibernate are pre-calculated outside
of the server. Think of them as configuration, or as i18n values.

Regards

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



[google-appengine] Re: Continued Random 500 Error

2010-10-26 Thread Jamie H
Tim,

I run python + webapp.  My cold starts are ~2 sec.  I should mention
that I have also seen this error when firing up the built in
eReporter 

For some reason I saw 3 in a row this morning.  All cold starts.  My
cron handler is quite simple, like I said it's pythong + webapp, a few
imports.  I find it hard to believe it has anything to do with my app,
it seems like some type of quirk with app engine right now... Most
people don't see this error because for some reason it is reported as
a warning, and not an error.  You must adjust the severity level of
your logs to see it.

Any chance Google has a comment on this?  Like I said, I have created
warmup cron jobs 1 minute before my real crons and it has done the
trick so far.  So it's not major, but kinda embarassing when a
customer sees this error...

On Oct 25, 2:03 am, Tim Hoffman zutes...@gmail.com wrote:
 A quite sites will see this sort of problem, you may find you  startup
 time for a cron or any other handler
 is quite expensive.  If google infrastructure is running a bit slow,
 then the startup time could blow out
 hence the 500 error.

 You haven't said if your running python or java.  But either way I
 would include some logging so that you can see how long your app takes
 on average to startup a cold instance.

 Rgds

 Tim

 On Oct 25, 11:36 am, Jamie H ja...@mhztech.com wrote:

  App Engine Staff,

  I continue to receive this error on all my apps.  I receive this error
  on cold starts.  I say this because in the past Google has responded
  this is due to  1 sec averages, causing Google to not scale your
  app.  This is not the case for me.  I receive it on 0 load.  I see
  these on 3 different apps, at random times.  It is most annoying when
  I receive this error on my CRON entries.  Obviously, this causes cron
  to be unreliable.  To get around this I have had to add warmup cron
  entries 1 minute before my real cron entries.  I feel it is ridiculous
  for me to have to do so.  Please, can somebody respond on this issue?
  I see many others in the group reporting similar findings.

  To summarize, I understand this error can be a result of Google not
  scaling your app + too many requests and requests timing out in 10
  second queue.  This is not the case for my app.  I receive it when my
  app has NO load.

  Request was aborted after waiting too long to attempt to service your
  request. This may happen sporadically when the App Engine serving
  cluster is under unexpectedly high or uneven load. If you see this
  message frequently, please contact the App Engine team.



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



[google-appengine] High count of 500

2010-10-26 Thread Rafael Sierra
Hi, I'm getting a really high number of errors which I don't get, this
is the error:

  File /base/data/home/apps/myapp/version/django/core/urlresolvers.py,
line 188, in _populate
lookups.appendlist(pattern.name, (bits, p_pattern))
AttributeError: 'RegexURLResolver' object has no attribute 'name'

It is inside Django, ok? Now we look into urlresolvers.py:

if isinstance(pattern, RegexURLResolver):
# blah blah
else:
bits = normalize(p_pattern)
lookups.appendlist(pattern.callback, (bits, p_pattern))
lookups.appendlist(pattern.name, (bits, p_pattern))

(As it may take away the formatting, here is the code:
http://dpaste.com/hold/264574/ )

The last line is the line 188, where it's reached ONLY IF pattern is
not a RegexURLResolver instance, so, how could `pattern` not be a
RegexURLResolver and then become one?

I'm getting this error in almost 2 of 3 requests...:(

-- 
Rafael Sierra
http://blog.rafaelsdm.com

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



[google-appengine] Suddenly getting 404 on my application

2010-10-26 Thread Wes
One of my site's is suddenly giving a 404 on the default version as
well as the other older versions.

Is anyone aware of any system issues?

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



[google-appengine] Application limits

2010-10-26 Thread Douglas Finley
How does Google App Engine for Business work?
It looks like it's only for intranet, how would a tech company create a
product on Google App Engine
and deploy instances to multiple clients?
Or is Google App Engine designed to be take one application, and it's
on the developer to partition the database
tables properly to separate each client properly versus giving each
client an entire instance.

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



[google-appengine] Re: High count of 500

2010-10-26 Thread Rafael Sierra
Just found out what could be my problem:

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

My main.py is also deleting django from sys.modules, I'll give a try
to use_library, let's se what happens

On Tue, Oct 26, 2010 at 7:16 PM, Rafael Sierra rafaeljs...@gmail.com wrote:
 Hi, I'm getting a really high number of errors which I don't get, this
 is the error:

  File /base/data/home/apps/myapp/version/django/core/urlresolvers.py,
 line 188, in _populate
    lookups.appendlist(pattern.name, (bits, p_pattern))
 AttributeError: 'RegexURLResolver' object has no attribute 'name'

 It is inside Django, ok? Now we look into urlresolvers.py:

            if isinstance(pattern, RegexURLResolver):
                # blah blah
            else:
                bits = normalize(p_pattern)
                lookups.appendlist(pattern.callback, (bits, p_pattern))
                lookups.appendlist(pattern.name, (bits, p_pattern))

 (As it may take away the formatting, here is the code:
 http://dpaste.com/hold/264574/ )

 The last line is the line 188, where it's reached ONLY IF pattern is
 not a RegexURLResolver instance, so, how could `pattern` not be a
 RegexURLResolver and then become one?

 I'm getting this error in almost 2 of 3 requests...:(

 --
 Rafael Sierra
 http://blog.rafaelsdm.com




-- 
Rafael Sierra
http://blog.rafaelsdm.com

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



[google-appengine] Re: Suddenly getting 404 on my application

2010-10-26 Thread Wes
Now the latest version (13), which is the default, is serving the only
working version (10).

Any help?

On Oct 26, 4:49 pm, Wes westho...@gmail.com wrote:
 One of my site's is suddenly giving a 404 on the default version as
 well as the other older versions.

 Is anyone aware of any system issues?

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



Re: [google-appengine] datastore advice?

2010-10-26 Thread djidjadji
Parent and child objects are stored in the same Bigtable node. This is
done for the transactions. A transaction works on a single
entity-group.
If you perform a query you use an index to find the objects needed. At
this point there is no performance penalty for parent or child objects
that match the query. The query results in a number of keys of objects
that need to be retrieved. The best query responds time is when the
objects
to fetch are stored in as many Bigtable nodes as possible (parallel fetch).

Why do you need so many child objects?
Can you implement it with adding a Parent Reference Property to the
child object and thus remove the need to store the entity group all in
one Bigtable node?

The parent-child objects are needed
1) if you need transactions on them
or
2) if you want to extract the parent key given a child key
Perform a keys_only query on child objects and from these keys get
the set of parent keys of objects that you need to fetch complete.
Brett Slatkin uses this technique in a number of Google IO talks,
the child object has a ListProperty that is used in the keys_only
query.

Most other applications can be implemented without the explicit parent object.

2010/10/26 Charles char...@whoischarles.com:
 Hi all,

 I'm wondering, since the datastore is hierarchical, does the number of
 children an entity has affect the performance on querying on the parents
 themselves?  For example, if I have a set of parents, say...

 Jane
 Margaret
 Graham
 Arthur

 ...and I have a set of children associated with those parents...

 Jane
   -Sam
   -Robert
 Margaret
   -Lisa
 Graham
 Arthur
   -Rowen
   -Jerry

 ...will the number of children for each parent affect the performance of
 querying the parents themselves?  For instance, if I wanted to select all of
 the parents (SELECT * FROM parents), that would be easy with the data
 above.  But, since the datastore is hierarchical, does the performance get
 hampered if say the parents have many thousands or even millions of
 children?  Say, like...

 Jane
   -Sam
   -Robert
   ...1 million more
 Margaret
 ...

 If so, I'm just wondering if it would make more sense to make the children
 root entities too, so as not to affect the performance of querying on the
 parents.  Anyways, hope I've explained my question well enough.

 Thanks in advance!


 Charles

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


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



[google-appengine] Re: Error code 203 - What is meaning of this error

2010-10-26 Thread hawkett
Hi Matija,

   I'm not using java on app engine, but I can offer the following

- the ms count on the two variations is hugely different - one is less
than a second, and one is over 40s - if commenting out those lines
causes such a difference, then I don't think it is inside this
function that the problem exists.
- I can't see where you define the 'sequence' variable, or guess how
you use either the 'sequence' array or the 'ai' array, but my money
would be on the processing of those arrays - after the call to the
function is complete. e.g. commenting out those lines means those
arrays have different content, which affects processing elsewhere.
- guessing even more, I would say that 203 is not the correct error
code, and that perhaps GAE exited from too much recursion, stack
overflow, infinite loop or something like that. That should probably
be a 500 range error code, as a 2xx range code indicates success,
which does not seem right based on the error message.
- My understanding is that to deal with memory leaks, GAE will kill a
server that uses too much memory and start a new one if necessary to
handle subsequent requests. This also makes me wonder about too much
recursion or stack overflow etc.
- it is strange that the request took 40s and used no cpu - this also
makes me wonder about too much recursion - i.e. GAE never gets the
opportunity to measure CPU before your process crashes.

Anyway - some log messages in your processing would go a long way to
identifying the real problem (assuming you are getting log message
output before this crashes).

Cheers,

Colin

On Oct 26, 4:42 pm, Matija matija.jerko...@gmail.com wrote:
 I have a rather complex code for traveling salesman problem that is
 trowing this error. I have located lines that produce this error and
 it is pretty strange.

 int[] sequence = new int[dimension];

 private void reverse(int i, int j, final int ai[]) {
         int i1 = j - i;
         if (i1  0)
             i1 += dimension;
         i1 = i1 / 2 + 1;
         int l, k;
         for (l = 0; l  i1; l++) {
             k = sequence[i];
             sequence[i] = sequence[j];
             ai[sequence[i]] = i;
 //            sequence[j] = k;
 //            ai[sequence[j]] = j;
             if (++i = dimension)
                 i -= dimension;
             if (--j  0)
                 j += dimension;
         }
     }

 If I leave commented this two lines task request finishes with this
 performance parameters (ms=842 cpu_ms=97 api_cpu_ms=0).

 If I uncomment this two lines I get:

 ms=40087 cpu_ms=0 api_cpu_ms=0 exit_code=203 throttle_code=1

 A serious problem was encountered with the process that handled this
 request, causing it to exit. This is likely to cause a new process to
 be used for the next request to your application. If you see this
 message frequently, you should contact the App Engine team. (Error
 code 203)

 Why ?!

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



[google-appengine] Re: Error code 203 - What is meaning of this error

2010-10-26 Thread hawkett
my mistake - I can see where you define the 'sequence' array - I'm
just blind - other observations stand :)

On Oct 26, 11:26 pm, hawkett hawk...@gmail.com wrote:
 Hi Matija,

    I'm not using java on app engine, but I can offer the following

 - the ms count on the two variations is hugely different - one is less
 than a second, and one is over 40s - if commenting out those lines
 causes such a difference, then I don't think it is inside this
 function that the problem exists.
 - I can't see where you define the 'sequence' variable, or guess how
 you use either the 'sequence' array or the 'ai' array, but my money
 would be on the processing of those arrays - after the call to the
 function is complete. e.g. commenting out those lines means those
 arrays have different content, which affects processing elsewhere.
 - guessing even more, I would say that 203 is not the correct error
 code, and that perhaps GAE exited from too much recursion, stack
 overflow, infinite loop or something like that. That should probably
 be a 500 range error code, as a 2xx range code indicates success,
 which does not seem right based on the error message.
 - My understanding is that to deal with memory leaks, GAE will kill a
 server that uses too much memory and start a new one if necessary to
 handle subsequent requests. This also makes me wonder about too much
 recursion or stack overflow etc.
 - it is strange that the request took 40s and used no cpu - this also
 makes me wonder about too much recursion - i.e. GAE never gets the
 opportunity to measure CPU before your process crashes.

 Anyway - some log messages in your processing would go a long way to
 identifying the real problem (assuming you are getting log message
 output before this crashes).

 Cheers,

 Colin

 On Oct 26, 4:42 pm, Matija matija.jerko...@gmail.com wrote:







  I have a rather complex code for traveling salesman problem that is
  trowing this error. I have located lines that produce this error and
  it is pretty strange.

  int[] sequence = new int[dimension];

  private void reverse(int i, int j, final int ai[]) {
          int i1 = j - i;
          if (i1  0)
              i1 += dimension;
          i1 = i1 / 2 + 1;
          int l, k;
          for (l = 0; l  i1; l++) {
              k = sequence[i];
              sequence[i] = sequence[j];
              ai[sequence[i]] = i;
  //            sequence[j] = k;
  //            ai[sequence[j]] = j;
              if (++i = dimension)
                  i -= dimension;
              if (--j  0)
                  j += dimension;
          }
      }

  If I leave commented this two lines task request finishes with this
  performance parameters (ms=842 cpu_ms=97 api_cpu_ms=0).

  If I uncomment this two lines I get:

  ms=40087 cpu_ms=0 api_cpu_ms=0 exit_code=203 throttle_code=1

  A serious problem was encountered with the process that handled this
  request, causing it to exit. This is likely to cause a new process to
  be used for the next request to your application. If you see this
  message frequently, you should contact the App Engine team. (Error
  code 203)

  Why ?!

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



[google-appengine] Re: Cron scheduling at runtime

2010-10-26 Thread sodso
this is easily possible using command script.

refer here -
http://code.google.com/appengine/docs/java/tools/uploadinganapp.html#Command_Line_Arguments

you will just need to create a small script which will run the script
and hence upload the updated cron using update_cron optionread
the above article for full details

thanks.

On Oct 26, 10:58 pm, Vibhuti Gupta guptavibh...@gmail.com wrote:
 Hi

 I need to do runtime scheduling for certain tasks in my application. In GAE
 we need to modify cron.xml and upload it to the server.
 I am using java and am not able to find a way to accomplish this at runtime.
 Anyone has any ideas regarding this!!

 Regards

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



[google-appengine] Re: When using an automatically Long id as a key, is it possible the Long value is a zero?

2010-10-26 Thread Tim Hoffman
Hi

In fact you can create references to entities that don't exist yet.
(Sometimes this can be useful ;-)

So as keakon mentioned the only way to know that the reference points
to an actual entity is to retrieve it.

Rgds

T

On Oct 26, 11:40 pm, Tapir tapir@gmail.com wrote:
 I want to check whethor or not a reference id is invalid by comparing
 it with a zero.
 Works?

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



[google-appengine] Re: Suddenly getting 404 on my application

2010-10-26 Thread sodso
URL is case-sensitive in GAE

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



Re: [google-appengine] Re: Image Upload

2010-10-26 Thread ego008
you can do it step by step here

http://code.google.com/intl/en/appengine/docs/python/images/usingimages.html

http://code.google.com/intl/en/appengine/docs/python/images/usingimages.html
 GAE Geek http://gaefons.appspot.com/

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



Re: [google-appengine] Register more than 10 app

2010-10-26 Thread ego008
No way


GAE Geek http://gaefons.appspot.com/

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



Re: [google-appengine] Register more than 10 app

2010-10-26 Thread Robert Kluin
You can fill out a request here:
http://www.google.com/url?sa=Dq=http://code.google.com/support/bin/request.py%3Fcontact_type%3DAppEngineContactusg=AFQjCNGhN1Q0nHGhFREUuXAwFqrZgjdhZw

See:
http://groups.google.com/group/google-appengine/browse_thread/thread/b65ab0b40c803b74/1c475b9be3afbd62?pli=1







On Mon, Oct 25, 2010 at 03:25, asicfr asi...@gmail.com wrote:
 Hi everyone,

 I would like to register more than 10 app, how can i do that ?
 Thanks for all

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



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



Re: [google-appengine] Bug in Datastore Admin page

2010-10-26 Thread Robert Kluin
I have seen similar issues with custom admin pages too.  For me it
occurs with apps using a Google Apps Domain to authenticate and a
custom domain.

I thought there was already an issue in the issue tracker related to
this, but I could not find it.


Robert






On Mon, Oct 18, 2010 at 06:19, Andrius andriu...@gmail.com wrote:
 Hi,

 when I try to open datastore admin page in google app engine admin
 area I get frame window asking me to provide google account to log in.
 Not sure why is it asking because I am already logged in. If I try to
 login within that frame I get error: Error: Server Error The server
 encountered an error and could not complete your request. If the
 problem persists, please report your problem and mention this error
 message and the query that caused it. Tried few times with no luck.

 Could someone from google have a look please?
 ID: cloudbidder

 Regards,
 Andrius

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



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