[appengine-java] Is endsWith(String) not supported in org.datanucleus.store.appengine.query.DatastoreQuery

2010-01-11 Thread Steph
When I make a query of type:

SELECT FROM Business WHERE url.endsWith('google.com')

I get the following exception:

 [java] org.datanucleus.store.appengine.query.DatastoreQuery
$UnsupportedData
storeFeatureException: Problem with query SELECT FROM Business WHERE
url.endsWith('google.com'): Unsupported method endsWith while pa
rsing expression: InvokeExpression{[PrimaryExpression{url}].endsWith
(Literal{google.com})}


Is endsWith(String) not supported?

Seemed like the documentation was saying otherwise:
http://www.datanucleus.org/products/accessplatform/jdo/jdoql_methods.html

Am I missing something?

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




[appengine-java] Re: First Request High CPU

2010-01-11 Thread Bert Peters
I believe that, in normal situations, App Engine shuts down your
application if it has not had any request for the last 10 minutes. You
could set your cron to run it every five, and it should be good. I
however do not understand how your (Ikai) cron could take up so much
CPU use. I'd profile that.

On Jan 11, 4:58 am, Shrek srikanth.pagad...@gmail.com wrote:
 hi Ikai

 does appengine suffer from this anomaly even when billing is
 enabled?
 my application doesn't receive much traffic, but i still need it to be
 ready.
 I don't mind enabling billing and don't even mind any $ value (as a
 consequence), but I would like to know if the problem will go away...

 Does anybody else know the answer for this question?

 Thanks

 On Nov 30 2009, 11:38 am, Ikai L (Google) ika...@google.com wrote: Yes. 
 This is an issue we are working on. Basically, what happens is that
  instances of your application are elastic and loaded up upon demand. As your
  application grows, we will grow with you, but one of the consequences of
  this is that if your application is not receiving many requests, we may
  cycle you out to allocate more instances for an application with higher
  resource requirements.

  We discourage running cron jobs to reduce startup time because ultimately,
  this will result in more aggressive cycling for all of our users. We're
  looking at several techniques to speed up Java application startup time.
  It's also been suggested that we should look at a billing enabled option for
  keeping a certain number of instances warm at all times.

  On Sun, Nov 29, 2009 at 11:22 PM, Jeffrey Goetsch 
  jeffg@gmail.comwrote:

   I have noticed that the first request to a server instance has really high
   CPU usage (7000+ milliseconds).  After the server is up, the same request
   takes only 20 milliseconds.  I am not using Spring or any other framework.
    It appears that the time is used during the first execute call on a
   Datastore query.

   Is this a normal behavior?

   I have a cron job that I was running every 2 minutes, but that alone was
   using 15% of my free quota.  I have moved the cron to every minute, and 
   I'm
   seeing huge improvement on performance and quota.  The cron used to take
   7000+ ms  and now I am getting 20ms.  Does this mean you should make sure
   you have at least on cron running every minute?

   Thanks,
   Jeffrey

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

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




[appengine-java] Re: Beginner question: one to many relationship

2010-01-11 Thread Bert Peters
If your database has been normalized, I'd say you need something these
2 queries:
SELECT FROM author.id WHERE author.name = nameParam, PARAMETER string
nameParam
SELECT FROM books WHERE book.author = idParam, PARAMETERS Key
idParam

Or something like that. HTH.

On Jan 10, 11:40 pm, fhucho fhu...@gmail.com wrote:
 Hi, sorry for beginner question. I have authors and books in the
 database. Every author has list of books in a one to many owned
 relationship. I know the author's name, how can I retrieve the author
 and his books from database? I know how to get the author but not his
 books (Author.books).
-- 
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: Maven

2010-01-11 Thread drone
No, central repo has 1.2.0 and 1.2.1 only.
1.3.0 is available at 
http://www.mvnsearch.org/maven2/com/google/appengine/appengine-java-sdk/
(Whole SDK packaged as a zip file. There is still no place where you
could fetch only GAE jars you need).

On Jan 7, 5:10 pm, David Karlsen davidkarl...@gmail.com wrote:
 They seem to ignore the maven question completely (there has been a request
 for this since end of dawn).
 One of the factors which limits GAE in widespreading...

 2010/1/6 Marcel Overdijk marceloverd...@gmail.com

  Is GAE 1.3.0 available in central maven repo?

  Would be nice if Google GAE team could create a subpage on the GAE
  docs homepage with information for maven.

  Many users would appreciate this.

  Thanks,
  Marcel

  --
  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: App Engine SDK 1.3.0 maven repo

2010-01-11 Thread drone
Again, If you need this to work on integration servers and other
developer machines right away, you might consider configuring maven-
dependency-plugin and maven-install-plugin to do this for you (your
pom.xml becomes quite large, but it works).

See example at 
http://maven-gae-plugin.googlecode.com/svn/example/jsp-persistence-app/pom.xml

(Don't forget to add mvnsearch repository).

On Jan 9, 8:21 am, Rusty Wright rwright.li...@gmail.com wrote:
 Those instructions seem a bit more than what is needed in my opinion.  I just 
 used the maven command to install the jars in my local repository ~/.m2 
 (actually some place different on my Windows pc).  I use the following 
 copy.cmd file on my pc; all of the jar files it references are in the same 
 directory:

 rem PATH=C:\Program Files\Apache Software Foundation\apache-maven-2.0.9\bin

 start mvn install:install-file -DgroupId=com.google.appengine 
 -DartifactId=appengine-api-1.0-labs -Dversion=1.3.0 -Dpackaging=jar 
 -DcreateChecksum=true  -Dfile=appengine-api-1.0-labs-1.3.0.jar 
 -DgeneratePom=true

 pause

 start mvn install:install-file -DgroupId=com.google.appengine 
 -DartifactId=appengine-api-1.0-sdk -Dversion=1.3.0 -Dpackaging=jar 
 -DcreateChecksum=true  -Dfile=appengine-api-1.0-sdk-1.3.0.jar 
 -DgeneratePom=true

 pause

 start mvn install:install-file -DgroupId=com.google.appengine 
 -DartifactId=appengine-api-1.0-stubs -Dversion=1.3.0 -Dpackaging=jar 
 -DcreateChecksum=true  -Dfile=appengine-api-1.0-stubs.jar -DgeneratePom=true

 pause

 start mvn install:install-file -DgroupId=com.google.appengine.orm 
 -DartifactId=datanucleus-appengine -Dversion=1.0.4.1.final -Dpackaging=jar 
 -DcreateChecksum=true  -Dfile=datanucleus-appengine-1.0.4.1.final.jar 
 -DgeneratePom=true

 I run it in a dos window and it creates a new window for each maven line.  On 
 windows each maven line has to be one long line; on Unix you can use 
 backslashes and wrap them.

 James Cooper wrote:
  Here's an article that documents how to deploy the App Engine JARs to
  your own maven repo:

 http://www.bitmechanic.com/blog/?p=30

  -- James

  On Dec 22 2009, 1:32 pm, Andreas K llberg andreas.kallb...@gmail.com
  wrote:
  Is someone going to do something about this?
  It's has been wrong for some time now.
  And also, another 
  typo:http://www.mvnsearch.org/maven2/com/google/appengine/orm/datanucleus-...
  It's a space in the version folder name :-(

  Please, there are a significant number ofmavenusers out here that
  would appreciate this...

  .../Andreas

  On 15 Dec, 20:11, Rusty Wright rwright.li...@gmail.com wrote:

  Here I am, yet anothermavenuser whining about some new release not being 
  correct in themavenrepo.
  The appengine-api-1.0-labs directory has a1.3.0 directory, but in it are 
  jars named with 1.2.8:
 http://www.mvnsearch.org/maven2/com/google/appengine/appengine-api-1
  George Moschovitis wrote:
  This is a long awaited feature.
  Some problems though:
  - Instead of the serve() helper I would expect access to the blobs
  through a url, something like:
   http://my-app.appenginebs.com/blob-key
  - No support for organization in directories
  - A method to manipulate the uploaded blobs is missing (for example
  cropping/resizing big images)
  - No free quota
  -g.
  On Dec 15, 6:00 am, Jason (Google) apija...@google.com wrote:
  Hi Everyone. We just released version1.3.0 of the App Engine SDK for
  both Python and Java. The most notable change is the new experimental
  Blobstore API which allows billed apps to store files up to 50 MB. The
  release also includes some performance tweaks to the Java runtime.
  Blog 
  post:http://googleappengine.blogspot.com/2009/12/app-engine-sdk-130-releas...
  Release notes:
  Python:http://code.google.com/p/googleappengine/wiki/SdkReleaseNotes
  Java:http://code.google.com/p/googleappengine/wiki/SdkForJavaReleaseNotes
  Cheers!
  - Jason
  --
  You received this message because you are subscribed to the Google 
  Groups Google App Engine for Java group.
  To post to this group, send email to 
  google-appengine-j...@googlegroups.com.
  To unsubscribe from this group, send email to 
  google-appengine-java+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/google-appengine-java?hl=en.
-- 
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.




[appengine-java] Problem with JDO 1-1 mapping

2010-01-11 Thread Kamlesh
 When ever I try to save object of class UserPrincipalCredentials ,
using persistancemanager (see snippet below) , the child property
userProfile does not get saved. can anyone please review my
annotations and tell me what could be wrong with them ?

Code for saving Operation

public UserPrincipalCredentials create(UserPrincipalCredentials
credentials) {
final PersistenceManager pm = 
PMFProvider.get().getPersistenceManager
();
try {
System.out.println(trying to save);
//final UserProfile profile = 
credentials.getUserProfile();
//profile.setLoginAccount(credentials);
pm.makePersistent(credentials);

} finally {
pm.close();
}

System.out.println(New User Added... );
System.out.println(UserName :  + credentials.getUserName());
System.out.println(Password :  + credentials.getPassword());
System.out.println(Role :  + 
credentials.getRoles().get(0).getRole
());
System.out.println(Perm : 
+ 
credentials.getRoles().get(0).getPermissions());
System.out.println(Profile :  + credentials.getUserProfile()
+  , persistent ? : 
+ 
JDOHelper.isPersistent(credentials.getUserProfile()));
return credentials;
}

and out put at sysout is

New User Added...
UserName : loginAccount5
Password :
52cfddd56f5ff8dd68f564b8172efe27ae14d7fe1f93d89828ab96dcf6ea6670
Role : DEFAULT
Perm : []
Profile : com.kpatil.global.persistance.model.userprof...@1bca1c3 ,
persistent ? : false

Class
UserPrincipalCredentials

package com.kpatil.global.persistance.model;

import java.util.List;

import javax.jdo.annotations.IdentityType;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.PersistenceModifier;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

@PersistenceCapable(identityType = IdentityType.APPLICATION)
public class UserPrincipalCredentials {

@PrimaryKey
@Persistent
private String userName;

@Persistent(persistenceModifier=PersistenceModifier.PERSISTENT)
private UserProfile userProfile;

@Persistent
private String password;

@Persistent
private ListUserRole roles;

public String getUserName() {
return userName;
}

public void setUserName(String userName) {
this.userName = userName;
}

public UserProfile getUserProfile() {
return userProfile;
}

public void setUserProfile(UserProfile userProfile) {
this.userProfile = userProfile;
}

public String getPassword() {
return password;
}

public void setPassword(String password) {
this.password = password;
}

public ListUserRole getRoles() {
return roles;
}

public void setRoles(ListUserRole roles) {
this.roles = roles;
}

}

Class UserProfile

package com.kpatil.global.persistance.model;

import java.io.Serializable;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.IdentityType;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

import com.google.appengine.api.datastore.Key;

@PersistenceCapable(identityType = IdentityType.APPLICATION)
public class UserProfile implements Serializable {

private static final long serialVersionUID = -303737956990979603L;
@PrimaryKey
@Persistent(valueStrategy=IdGeneratorStrategy.IDENTITY)
private Key key;

@Persistent
private String firstName;
@Persistent
private String lastName;


public Key getKey() {
return key;
}

public void setKey(Key key) {
this.key = key;
}

public String getFirstName() {
return firstName;
}

public void setFirstName(String firstName) {
this.firstName = firstName;
}

public String getLastName() {
return lastName;
}

public void setLastName(String lastName) {
this.lastName = lastName;
}

}

Re: [appengine-java] Re: After how much time of no traffic does GAE shut-down the instance

2010-01-11 Thread 杨浩
my GAE app too shutdown every tow minutes when no request!
so when my app init that is terrible, because spring init need 15s!
so my answer is:
create a cron:every one minutes to run once,It's work very good!(every tow
minutes don't keep my app online, It's still shutdown!)
-- 

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] Eclipse plugin failure after log4j added to the classpath (WEB-INF/lib)

2010-01-11 Thread 杨浩
*Check your Java Build Path of GAE App!*
notice that:add your log4j lib into your app build path

2010/1/11 杨浩 skzr@gmail.com

 I have the slf4j + log4j in my GAE app, it's work fine!
 war/WEB-INF/lib/slf4j-log4j12-1.5.10.jar
 war/WEB-INF/lib/log4j-1.2.15.jar
 you can try version 1.2.15 of log4j!
 ^ ^

-- 

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] Eclipse plugin failure after log4j added to the classpath (WEB-INF/lib)

2010-01-11 Thread 杨浩
I have the slf4j + log4j in my GAE app, it's work fine!
war/WEB-INF/lib/slf4j-log4j12-1.5.10.jar
war/WEB-INF/lib/log4j-1.2.15.jar
you can try version 1.2.15 of log4j!
^ ^
-- 

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] blobstore api and guice

2010-01-11 Thread smalex
Hello all,

I tried uploading files using Blogstore API but it doesn't work for
me.
I use guice and I think there is a problem with this forward in
UploadBlobServlet.java

getServletContext().getRequestDispatcher(successPath).forward
(wrappedRequest, wrappedResponse);

May be something wrong with catching forwards in Guice?

I don't know how do solve this problem, I hope somebody response me.

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




[appengine-java] app engine urlfetch without new heap allocation every time you set a new url

2010-01-11 Thread devadvocate
I'm working on an algorithm that runs in a tight loop.  I don't want
to call new() on anything every time I want to change my url I am
going to use for a rest call via urlfetch.  however, the java.net
httpclient, url, urlstreamhandler, and the urlfetch HTTPRequest all
require this.  In c#/.net there is a factory for creating new
httpwebrequest objects each time you want to change the url.

All I really need is a setUrl(String url) method I can call on an
instantiated urlfetch HTTPRequest object.  Why does this not exist?  I
have found this to be quite a pain point.   I could easily write my
own implementation with raw tcp sockets if app engine supported that.

Does anyone know of a workaround here?  Any plans to add an instance
method to HTTPRequest for setUrl(String url)?

Thanks,
David Nelson
http://developeradvocate.appspot.com
http://twitter.com/devadvocate
-- 
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] Servlet Mapping not working as expected

2010-01-11 Thread Icarus
Hi,

 I have the following issue :

 The below servlet mapping when run on the local app engine instance
maps
 correctly for http://localhost:8080/sitefeed/
but not for
http://localhost:8080/sitefeed  !-- The '/' is not used --

servlet
servlet-nameSiteUploadServlet/servlet-name
servlet-classcom.mysite.SiteUploadServlet/servlet-class
/servlet
servlet
servlet-nameSiteFeedServlet/servlet-name
servlet-classcom.mysite.SiteFeedServlet/servlet-class
/servlet

servlet-mapping
servlet-nameSiteUploadServlet/servlet-name
url-pattern/siteupload/*/url-pattern
/servlet-mapping
servlet-mapping
servlet-nameSiteFeedServlet/servlet-name
url-pattern/sitefeed/*/url-pattern
/servlet-mapping

Is this an issue on the GAE ?
-- 
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] why memcache doesn't saves @NonPersistent child object of a detached parent?

2010-01-11 Thread Prashant Gupta
Hi,

I found a weird behaviour (testing in dev mode). Suppose I have an entity
with a NonPersistent child, say *child*. I want to cache parent to memcache
for fast access also I want child to be cached with parent. Since *child* is
NonPersistent, so, after fetching (and detaching) parent from datastore I am
assigning *child* an instance (parent.*child* = new Child()) then saving it
to memcache. But next time when I fetched parent from memcache, *child* is
again null. Why? I noticed that this happens only if I detach parent, if I
don't, *child* survives. It doesn't matter weather I detach before or after
assignment, *child* dies. Is it an expected behaviour of an detached object
or a 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: Servlet Mapping not working as expected

2010-01-11 Thread Peter Ondruska
You need additional mapping for /sitefeed:

servlet-mapping
servlet-nameSiteFeedServlet/servlet-name
url-pattern/sitefeed/url-pattern
/servlet-mapping


/sitefeed/* will not match /sitefeed

On Jan 11, 11:40 am, Icarus pr.a...@gmail.com wrote:
 Hi,

  I have the following issue :

  The below servlet mapping when run on the local app engine instance
 maps
  correctly forhttp://localhost:8080/sitefeed/
 but not forhttp://localhost:8080/sitefeed         !-- The '/' is not used --

 servlet
 servlet-nameSiteUploadServlet/servlet-name
 servlet-classcom.mysite.SiteUploadServlet/servlet-class
 /servlet
 servlet
 servlet-nameSiteFeedServlet/servlet-name
 servlet-classcom.mysite.SiteFeedServlet/servlet-class
 /servlet

 servlet-mapping
 servlet-nameSiteUploadServlet/servlet-name
 url-pattern/siteupload/*/url-pattern
 /servlet-mapping
 servlet-mapping
 servlet-nameSiteFeedServlet/servlet-name
 url-pattern/sitefeed/*/url-pattern
 /servlet-mapping

 Is this an issue on the GAE ?
-- 
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] Building Scalable Complex App

2010-01-11 Thread Duong BaTien
Hi:

Is there any blog and/or note to apply list properties and merge-join in
python as in the following talk and demos
http://code.google.com/events/io/2009/sessions/BuildingScalableComplexApps.html 
using Java and JDO?

Thanks
Duong BaTien
DBGROUPS and BudhNet


-- 
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] Problem running on datastore first time

2010-01-11 Thread Fugitive Steak
I am trying to create a simple top score keeping app where you first
enter game you want to keep top score for and number of top scores to
keep track of.

This is done using the simple form on 
http://helloworldfromfs.appspot.com/ScoreBoards.jsp
but then the simple score board object is trying to be persisted to
the database it blows up with

Error: Server Error

The server encountered an error and could not complete your request.

Funny part is that it runs fine in my Eclipse IDE.

Is there something special you need to do when you run your datastore
for the first time on google app engine? Or is there any difference
between local dev environment and online one?

Is there a place where you can see the log files for this problem?

I am just learning so any help will be appreciated.

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




[appengine-java] Re: app engine urlfetch without new heap allocation every time you set a new url

2010-01-11 Thread Brian
Are you sure you are getting bad performance out of calling new too
many times? I would be interested to see benchmarks showing the
performance.

The JVM is very smart, worrying about using a new vs not is usually
is a losing battle. Brian Goetz has some good presentations on this
topic I have attended, and 99% of the time trying to be smart and
write fast code (by not using new(), etc.) gave me code that ran the
same or slower than the more readable version of the code.

On a side note, a URL fetch is an external request, very likely taking
100-500ms. Making a new object is a few cycles of the processor. I
think you are optimizing at the wrong level, if you can cache the
results of your URL fetch you could have 1x the performance of
avoiding calls to new.



On Jan 10, 4:04 pm, devadvocate david.jonathan.nel...@gmail.com
wrote:
 I'm working on an algorithm that runs in a tight loop.  I don't want
 to call new() on anything every time I want to change my url I am
 going to use for a rest call via urlfetch.  however, the java.net
 httpclient, url, urlstreamhandler, and the urlfetch HTTPRequest all
 require this.  In c#/.net there is a factory for creating new
 httpwebrequest objects each time you want to change the url.

 All I really need is a setUrl(String url) method I can call on an
 instantiated urlfetch HTTPRequest object.  Why does this not exist?  I
 have found this to be quite a pain point.   I could easily write my
 own implementation with raw tcp sockets if app engine supported that.

 Does anyone know of a workaround here?  Any plans to add an instance
 method to HTTPRequest for setUrl(String url)?

 Thanks,
 David Nelsonhttp://developeradvocate.appspot.comhttp://twitter.com/devadvocate
-- 
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] GAE + GWT + ECLIPSE (GAE Arguments)

2010-01-11 Thread Jason Parekh
Hi Sebastian,

You shouldn't need the --address parameter since GWT will bind to 0.0.0.0
(all addresses) by default.

Unfortunately, if you want to restrict the server to a specific address, I
don't think there's a way to do this.  You can ask on the GWT mailing list.

jason

On Sat, Jan 9, 2010 at 10:03 PM, Sebastian Quiles qse...@gmail.com wrote:

 Hi... i want to use GAE + GWT  but I need to set the --adress argument
 for GAE

 I've started on a working GAE project with the --address argument
 setted in the run configuration in the ecplise and in the arguments
 tabs in program arguments the --address argument...

 That's worked fine...

 now i ve just tilded the GWT  option in the google plugin .. and now
 it not compile anymore because GWT do not recognize the --address
 argument... where I put this argument now?

 --
 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] No JDO support for datanucleus ObjectStringConverter?

2010-01-11 Thread Max Ross (Google)
I'm sorry to report that we have not yet hooked in support for
ObjectStringConverter.  It shouldn't be too difficult though and I can
definitely see how it would be useful.  Please file an issue and we'll get
to it as soon as we can.

http://code.google.com/p/datanucleus-appengine/issues/list

Thanks,
Max
On Fri, Jan 8, 2010 at 3:47 PM, inetdevboy inetdev...@gmail.com wrote:

 I wrote a datanucleus javaTypes plugin (for joda-time LocalDate) based
 on the org.datanuclues.store.types.ObjectStringConverter interface.
 You probably know that this interface allows non-basic types to
 declare their ability to marshal themselves to/from a String
 representation for persistence.  In my case it'd be particularly
 helpful because the String representation's natural sort order matches
 the sort order of the class itself, so it'd be indexable.

 The datanucleus layer seems to find and register the plugin, because I
 get this FINE debug line when I include my plugin:

 Jan 8, 2010 8:47:42 PM org.datanucleus.store.types.TypeManager
 addJavaType
 FINE: Adding support for Java type org.joda.time.LocalDate
 (persistent=true, DFG=true, embedded=true)

 But when it tries to persist a field of type LocalDate I still get the
 following stack, with or without my plugin:

 java.lang.IllegalArgumentException: eventDate: org.joda.time.LocalDate
 is not a supported property type.
at
 com.google.appengine.api.datastore.DataTypeUtils.checkSupportedSingleValue
 (DataTypeUtils.java:145)
at
 com.google.appengine.api.datastore.DataTypeUtils.checkSupportedValue
 (DataTypeUtils.java:127)
at
 com.google.appengine.api.datastore.Entity.setProperty(Entity.java:
 280)
at
 org.datanucleus.store.appengine.DatastoreFieldManager.storeObjectField
 (DatastoreFieldManager.java:798)
at org.datanucleus.state.AbstractStateManager.providedObjectField
 (AbstractStateManager.java:1037)
at com.inetdevboy.model.Event.jdoProvideField(Event.java)
at com.inetdevboy.model.Event.jdoProvideFields(Event.java)
 [more]...

 I'd really like to avoid having to declare separate persistence fields
 with lifecycle listeners to accommodate every LocalDate field.  Is
 there a lever in the existing GAE implementation I haven't pulled to
 engage my plugin?

 BTW, I'm aware that there's an existing JodaTime datanucleus plugin,
 but it appears to require DataNucleus 2, and my implementation is
 essentially the same as theirs, just without the ORM support.

 Please help!

 [Using GAE SDK 1.3.0]

 --
 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] Persist/query test.test1.Test and test.test2.Test

2010-01-11 Thread Max Ross (Google)
By default the kind of the datastore entity is derived from the simple name
of the class, and test.test1.Test.class.getSimpleName() is the same as
test.test2.Test.class.getSimpleName().  This is documented here:
http://code.google.com/appengine/docs/java/datastore/dataclasses.html#Class_and_Field_Annotations

If you need to persist two classes in different packages but with the same
name you can override the kind like this:

@PersistenceCapable(table = SomethingElse)
public class Test {
  // ...
}

Hope this helps,
Max

On Fri, Jan 8, 2010 at 3:45 PM, w windic...@gmail.com wrote:

 I have two persistable classes: test.test1.Test and test.test2.Test,
 but I can't persist/query objects of these classes right. There is a
 simple example shows wrong behavior:

 test.TestServlet.java:

 package test;

 import java.io.IOException;

 import javax.jdo.JDOHelper;
 import javax.jdo.PersistenceManager;
 import javax.jdo.PersistenceManagerFactory;
 import javax.servlet.http.HttpServlet;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;

 public class TestServlet extends HttpServlet {

  public void doGet(HttpServletRequest request, HttpServletResponse
 response) throws IOException {
PersistenceManager pm = pmFactory.getPersistenceManager();
pm.makePersistent(new test.test1.Test(1, test1));
pm.close();

pm = pmFactory.getPersistenceManager();
pm.makePersistent(new test.test2.Test(1, test2));
pm.close();

pm = pmFactory.getPersistenceManager();
response.getWriter().println(RESULT:   + pm.getObjectById
 (test.test1.Test.class, 1));
pm.close();
  }

  public static final PersistenceManagerFactory pmFactory =
 JDOHelper.getPersistenceManagerFactory(transactions-optional);

 }

 test.test1.TestServlet.java and test.test2.TestServlet.java are the
 same except package name, so I missed it:

 import javax.jdo.annotations.*;

 @PersistenceCapable(identityType = IdentityType.APPLICATION)
 public class Test {

  public Test(String id, String data) {
this.id = id; this.data = data;
  }

  public String toString() {
return getClass().getName() + : id= + id +  data= + data;
  }

  @PrimaryKey
  private String id;

  @Persistent
  private String data;

 }

 Surprising result I got is following:

 RESULT:  test.test1.Test: id=1 data=test2

 Expected result:

 RESULT:  test.test1.Test: id=1 data=test1

 --
 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] GAE Plugin not working.

2010-01-11 Thread Ryan Feeney
I recently installed Windows 7 onto my lap top. I was previously using
eclipse with the GAE plugin without any problems. Since installing
Windows 7, each time I install the GAE plugin it is displayed on the
workspace and works properly, until I re-open eclipse. At which point
the plugin is missing from the workspace and all areas which I should
be given GAE options are missing (For example run configurations). I
have tried re-installing the plugin many times with the same result.

Has anyone experienced this?

Thanks for any advice.
-- 
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] GAE Plugin not working.

2010-01-11 Thread Jason Parekh
Hi Ryan,

That sounds really strange.  Is there any way you can launch Eclipse as an
Administrator, then install the plugin?  I remember in Vista some folks had
to do this trick.

jason

On Mon, Jan 11, 2010 at 1:00 PM, Ryan Feeney rfeeney0...@gmail.com wrote:

 I recently installed Windows 7 onto my lap top. I was previously using
 eclipse with the GAE plugin without any problems. Since installing
 Windows 7, each time I install the GAE plugin it is displayed on the
 workspace and works properly, until I re-open eclipse. At which point
 the plugin is missing from the workspace and all areas which I should
 be given GAE options are missing (For example run configurations). I
 have tried re-installing the plugin many times with the same result.

 Has anyone experienced this?

 Thanks for any advice.

 --
 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] GAE + GWT + ECLIPSE (GAE Arguments)

2010-01-11 Thread Jason Parekh
Actually, you should be able to use  -Djetty.host=ADDRESS when your project
is GWT-enabled.

jason

On Mon, Jan 11, 2010 at 12:40 PM, Jason Parekh jasonpar...@gmail.comwrote:

 Hi Sebastian,

 You shouldn't need the --address parameter since GWT will bind to 0.0.0.0
 (all addresses) by default.

 Unfortunately, if you want to restrict the server to a specific address, I
 don't think there's a way to do this.  You can ask on the GWT mailing list.

 jason

 On Sat, Jan 9, 2010 at 10:03 PM, Sebastian Quiles qse...@gmail.comwrote:

 Hi... i want to use GAE + GWT  but I need to set the --adress argument
 for GAE

 I've started on a working GAE project with the --address argument
 setted in the run configuration in the ecplise and in the arguments
 tabs in program arguments the --address argument...

 That's worked fine...

 now i ve just tilded the GWT  option in the google plugin .. and now
 it not compile anymore because GWT do not recognize the --address
 argument... where I put this argument now?

 --
 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] Grails GoogleAppEngine no metadata problem

2010-01-11 Thread Don
Hi

I am trying to run grails on google app engine using JDO,
but I got this:

org.codehaus.groovy.runtime.InvokerInvocationException:
javax.jdo.JDOFatalUserException: No meta data for Book.  Perhaps you
need to run the enhancer on this class?
NestedThrowables:
org.datanucleus.exceptions.NucleusUserException: No meta data for
Book.  Perhaps you need to run the enhancer on this class?

I am confused, because when I did grails app-engine package it looks
like the DataNucleus enhancer was running.

How can I fix this?

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




[appengine-java] Re: Grails GoogleAppEngine no metadata problem

2010-01-11 Thread datanucleus
 How can I fix this?

Provide metadata at runtime in valid location(s), as per the JDO
spec ? you don't say if you use annotations, XML, or programmatic
metadata.
-- 
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 type conversion?

2010-01-11 Thread Joel Weight
I'm attempting to use the low level data api and I've seen multiple messages
on this list from people that have claimed great success with it.  I'm
having one issue that I'm wondering about.

My object has a ListKey where Key is the google type key.  As I understand
the docs, I should be able to store List... where ... is any core
datatype.  Key is listed as one of those core data types.  When I read my
entity out of the data store, I get a List of Strings instead of a List of
Keys.  Is it expected that when I read the datastore and get the property
from the resulting Entity that I have to convert all of these Strings into
Keys using the KeyFactory?

Thanks,
Joel
-- 

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: Grails GoogleAppEngine no metadata problem

2010-01-11 Thread Don
Hi

I believe the grails app-engine plugin uses annotation and should
take care of this?
I see in my log:
Enhancing JDO classes
 [enhance] ...
 [enhance] DataNucleus Enhancer completed with success for 1 classes.
Timings : 


I tried to enhance it manually too, but I got lost following the GAE
App-engine tutorial.

Please help

Thanks

On Jan 12, 3:17 am, datanucleus andy_jeffer...@yahoo.com wrote:
  How can I fix this?

 Provide metadata at runtime in valid location(s), as per the JDO
 spec ? you don't say if you use annotations, XML, or programmatic
 metadata.
-- 
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] Youtube api issues - too many recent calls only on GAE

2010-01-11 Thread Kishore Jaladi
Hi,
We have a small YoutubeAPI mashup App hosted on Google App engine.
From last friday; we have been getting yt:quota -
too_many_recent_calls error from youtube even though we call once in
an hour. We suspected Google App engine; and hosted our war to some
hosting provider  it was Rock Solid  we are NOT getting those
youtube quota limit errors (too_many_recent_calls). Unable to
understand why we are getting that error only when we host on Google
App engine . Are there any problems with Google App engine from the
last few days?

Any help would be greatly appreciated

Thanks,
-Kishore
-- 
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: Maven

2010-01-11 Thread Rusty Wright

It looks like the folder

http://www.mvnsearch.org/maven2/com/google/appengine/appengine-api-1.0-labs/1.3.0/

has finally been fixed (as of January 9).


drone wrote:

No, central repo has 1.2.0 and 1.2.1 only.
1.3.0 is available at 
http://www.mvnsearch.org/maven2/com/google/appengine/appengine-java-sdk/
(Whole SDK packaged as a zip file. There is still no place where you
could fetch only GAE jars you need).

On Jan 7, 5:10 pm, David Karlsen davidkarl...@gmail.com wrote:

They seem to ignore the maven question completely (there has been a request
for this since end of dawn).
One of the factors which limits GAE in widespreading...

2010/1/6 Marcel Overdijk marceloverd...@gmail.com


Is GAE 1.3.0 available in central maven repo?
Would be nice if Google GAE team could create a subpage on the GAE
docs homepage with information for maven.
Many users would appreciate this.
Thanks,
Marcel
--
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: Low Level API type conversion?

2010-01-11 Thread Joel Weight
Ok, this was just me being lame.  I'm using JSF and I didn't have a
converter defined for Google's Key type, so in the transition between server
and client side it was getting converted into some lame String, which was
then getting stored in the data store.  So... to make a short story Long,
the datastore does support ListKey just fine and I'm still learning how
all this works.

Joel

On Mon, Jan 11, 2010 at 12:46 PM, Joel Weight digitalj...@gmail.com wrote:

 I'm attempting to use the low level data api and I've seen multiple
 messages on this list from people that have claimed great success with it.
 I'm having one issue that I'm wondering about.

 My object has a ListKey where Key is the google type key.  As I
 understand the docs, I should be able to store List... where ... is any
 core datatype.  Key is listed as one of those core data types.  When I read
 my entity out of the data store, I get a List of Strings instead of a List
 of Keys.  Is it expected that when I read the datastore and get the property
 from the resulting Entity that I have to convert all of these Strings into
 Keys using the KeyFactory?

 Thanks,
 Joel

-- 

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: Blobstore - delete record from apps console

2010-01-11 Thread YONG
Can anyone from Google App Engine team provide an answer for 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.




[google-appengine] Re: Updating an object fails when accessing application through Twilio

2010-01-11 Thread Danielle Morrill
Hi Kelvin,

I work for Twilio and I'm happy to help (sorry I didn't catch this
conversation sooner).  You might want to take a look a the debugger in
your account first as @dreadjr suggested.  If that doesn't help you
get unstuck, drop us a line at h...@twilio.com so we can take a look.

Cheers,
Danielle (at Twilio)

On Dec 26 2009, 5:53 pm, Kelvin krsc2...@gmail.com wrote:
 Hi,

 I have an application that receives parameters two parameters using
 GET method.  The parameters are:

      Caller, Digits

 Using those two parameters it actually updates an object in the
 datastore.  The problem I'm having is that if I use a web browser to
 access the link which receives the parameters everything works fine,
 the records are updated.  However, when I point myTwiliophone number
 to the application it actually looks like it is working fine over the
 phone, the process goes as it's supposed to look but the record never
 gets updated (i'm passing the exact same parameters.

 I have tried switching from POST to GET and back and forth but no luck
 so far.

 Any ideas as to why this is happening?
-- 
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: Best way to model relations

2010-01-11 Thread Daniel Aguilar
Hi again,

thanks a lot for your answers.
So it looks like developing for GAE is quite a different paradigm...
From your answers i understand that:

1. I should precompute and store all aggregated data I might need
2. Changes to my database are NOT immediate (hence I can't expect accuracy)

I will consider this from now on.

Thanks again!


On Thu, Jan 7, 2010 at 8:25 PM, Satoshi satoshi.nakaj...@gmail.com wrote:

 I'd add reference_count property (IntegerProperty(default=0)) to
 Photo entity, and increment it each time a reference happens. Then,
 call Photo.all().order(-reference_count).fetch(100) to get the top
 100 most referenced photos.

 A few additional notes:
 1. If you need an accurate reference count number, you need to put the
 routine (which reads the Photo entity, increment the reference count,
 and put it back to the database) into a transaction, but it is
 relatively expensive. I usually don't put it in a transaction unless I
 absolutely need an accurate number.
 2. Making too many put() calls in one HTTP request is not a good idea.
 I'd suggest to perform non critical operations (such as incrementing
 reference count) asynchronously using Task Queue.

 Satoshi

 On Jan 6, 4:15 pm, Daniel Aguilar dani.agui...@gmail.com wrote:
  Hi Satoshi,
 
  thanks for your reply, it really helped.
  In fact I just read this artile:
 http://code.google.com/appengine/articles/modeling.html
  and have started implementing based on it.
  Still wondering a couple of things, though...
  for instance, in my app I have another class called Collage.
  A collage entity has properties like name, date_created, etc... but also
  layer_0, layer_1 and layer_2, which are references to Photo entities.
  What kind of query could i perform in order to get the most referenced
  Photos?
 
  Thanks again!
 
  need to keep track of how many times
 
 
 
  On Thu, Jan 7, 2010 at 12:51 AM, Satoshi satoshi.nakaj...@gmail.com
 wrote:
   First of all, please remember that GAE/database is an Object-database,
   not a Relational-database. You can design your database with
   relations, but you will likely hit a roadblock later if you heavily
   rely on relations (because of the lack of JOIN and the performance
   problem of nested queries).
 
   If I were you, I would simply create two models (Artist and Photo),
   and have the artist property on Photo class, which is just a
   reference to an Artist entity (ReferenceProperty).  If you want to
   show all the Photos done by a particular Artist, you just need to
   query it (Photos.all().filter('artist', ...)).
 
   Alternatively, you could specify the Artist entity as the parent
   entity of each Photo, which essentially creates an entity group for
   each Artist - which has pros (transactions) and cons (possible
   performance hit because of transactions).
 
   Third alternative is ListProperty, but this is difficult to do it
   right without putting them in an entity group (which is alternative
   two)...
 
   Satoshi
 
   On Jan 5, 9:52 am, Daniel A dani.agui...@gmail.com wrote:
Hi there,
 
I just started writting my first app after reading some documentation
and tutorials.
Looks like an exciting platform to develop on, but there're many
things I still have doubts about.
I used to develop in PHP/MySQL, and I quite don't get how should I
proceed in order to get an efficient relational model.
 
To simplify things, I have two kind of entities: Artist and Photo. I
need to define relations one-to-many between instances of these two
entities. That is, an Artist can have many Photos, and a Photo can
only have one Artist.
 
In my table-shaped mind, I would model three kinds of entities
(Artist, Photo, ArtistPhotoRelation). Would this approach be the
 right
thing in GAE/datastore? Maybe I should avoid the relational entity,
and use multiple-valued properties in the Artist instead?
 
Thanks a lot!
 
   --
   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-appengine@googlegroups.com
 .
   To unsubscribe from this group, send email to
   google-appengine+unsubscr...@googlegroups.comgoogle-appengine%2bunsubscr...@googlegroups.comgoogle-appengine%2Bunsubscrib
 e...@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.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 

[google-appengine] Can't see the datastore viewer

2010-01-11 Thread Amit
Hi,
 When I go to the admin console and click on Datastore Viewer I get an
error page. This used to work a couple of days ago but now it
consistently fails with the following message:

Server Error
A server error has occurred.

Return to Applications screen »

Anyone else experiencing this?

My appid is living-life
-thanks,
Amit

-- 
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] Issue storing image in blob property, then retrieving

2010-01-11 Thread Daniel Aguilar
Hi there,

I'm just running into an issue trying to store an image in a blob property,
and trying to load it afterwards.
The process is as follows:
1. My front-end (a Flash application) sends the data to be stored to GAE
(i'm using pyamf)
2. The remote function stores the data (I save the image in a blob property)
and replies back (success/error)
3. The Flash application receives the result, and if ok, tries to load the
image I just saved.

This works perfectly locally (local GAE development environment), but when
running it online I get an Error 500 on step 3, as if the image was never
saved.
Next time I try to load the same image, it works.

So am I running some kind of delay-related issue here? Of course I tried
waitting a couple of seconds (even a minute) before attempting to load the
saved images, but didn't work either.

Does anyone know what may be happening here?

Thanks!
-- 

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: How to test my application with local database

2010-01-11 Thread ivanceras
Hi!,

I tried configuring my jdoconfig.xml but always with an error.

Here is my configuration

  persistence-manager-factory name=mysql
property name=javax.jdo.PersistenceManagerFactoryClass
value=org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFactory/

property name=datanucleus.ConnectionDriverName
value=com.mysql.jdbc.Driver/
property name=datanucleus.ConnectionURL value=jdbc://mysql://
localhost:3306/jdo/
property name=datanucleus.ConnectionUserName value=jdo/
property name=datanucleus.ConnectionPassword value=jdo/
property name=datanucleus.appengine.autoCreateDatastoreTxns
value=true/
property name=datanucleus.autoStartMechanism value=None/
property name=datanucleus.autoCreateSchema value=true/
property name=datanucleus.validateTables value=true/
property name=datanucleus.validateConstraints value=true/
property name=datanucleus.validateColumns value=true/
property name=datanucleus.DetachAllOnCommit value=true/
property name=datanucleus.maxFetchDepth value=1/
property name=datanucleus.storeManagerType value=rdbms/
  /persistence-manager-factory

I appreciate if you could help me on this.
Thanks,

On Jan 4, 9:56 pm, Ian Marshall ianmarshall...@gmail.com wrote:
 Hi mobject,

 I use MySQL for developer testing when running my app on a development
 web server before unleashing it onto my GAE developer web server
 (using BigTable)!

 I give you the contents of my jdoconfig.xml file below. You will be
 able to see that I have two persistence manager factory names; I use
 one for GAE (dev server and production) and the other for my local
 MySQL dev testing.

 One warning though: I have found that JDO behaviour differs when using
 MySQL and BigTable. So until it works on BigTable, it doesn't
 necessarily work!

 Enjoy,

 Ian

 jdoconfig.xml
 -
 ?xml version=1.0 encoding=UTF-8?
 jdoconfig
   persistence-manager-factory name=big-table
     property
      name=javax.jdo.PersistenceManagerFactoryClass

 value=org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFa 
 ctory
     /

     property name=javax.jdo.option.ConnectionURL value=appengine/



     property name=datanucleus.appengine.autoCreateDatastoreTxns
 value=true/
     property name=datanucleus.autoStartMechanism value=None/
     property name=datanucleus.autoCreateSchema value=true/
     property name=datanucleus.validateTables value=true/
     property name=datanucleus.validateConstraints value=true/
     property name=datanucleus.validateColumns value=true/
 !--property name=datanucleus.persistenceByReachabilityAtCommit
 value=false/--
     property name=datanucleus.DetachAllOnCommit value=true/
 !--property name=datanucleus.detachAsWrapped value=true/--

     !--  The default value is 1  --
     property name=datanucleus.maxFetchDepth value=1/

     !--  The default value is JDO2  --
 !--property name=datanucleus.deletionPolicy value=DataNucleus/--

   /persistence-manager-factory

   persistence-manager-factory name=mysql
     property
      name=javax.jdo.PersistenceManagerFactoryClass

 value=org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFa 
 ctory
     /

     !--  Settings for connection to a local MySQL database  --
     property
      name=datanucleus.ConnectionDriverName
      value=com.mysql.jdbc.Driver
     /
     property
      name=datanucleus.ConnectionURL
      value=jdbc:mysql://localhost:3306/[...]
     /
     property name=datanucleus.ConnectionUserName value=[...]/
     property name=datanucleus.ConnectionPassword value=[...]/

     property name=datanucleus.appengine.autoCreateDatastoreTxns
 value=true/
     property name=datanucleus.autoStartMechanism value=None/
     property name=datanucleus.autoCreateSchema value=true/
     property name=datanucleus.validateTables value=true/
     property name=datanucleus.validateConstraints value=true/
     property name=datanucleus.validateColumns value=true/
 !--property name=datanucleus.persistenceByReachabilityAtCommit
 value=false/--
     property name=datanucleus.DetachAllOnCommit value=true/
 !--property name=datanucleus.detachAsWrapped value=true/--

     !--  The default value is 1  --
     property name=datanucleus.maxFetchDepth value=1/

     !--  The default value is JDO2  --
 !--property name=datanucleus.deletionPolicy value=DataNucleus/--



     !--
     property name=javax.jdo.option.NontransactionalRead
 value=true/
     property name=javax.jdo.option.NontransactionalWrite
 value=true/
     property name=javax.jdo.option.RetainValues value=true/
     property name=datanucleus.autoCreateTables value=true/
     property name=datanucleus.autoCreateColumns value=true/
     property name=datanucleus.autoCreateConstraints value=true/

     property name=datanucleus.cache.collections.lazy value=true/
     property name=datanucleus.RetainValues value=true/
     --
   /persistence-manager-factory
 /jdoconfig
-- 
You received this message because you are subscribed 

[google-appengine] Problems with App Engine Eclipse Plugin

2010-01-11 Thread Manish
Hi All

I am having problems trying to install the app engine eclipse plugin
in Eclipse Java EE IDE for Web Developers(Galileo).
The installation of plugin completes without any errors. I can see the
plugin listed under Help  About Eclipse  Installation Details. But I
am not having any option such as New Web Application Project in File
 New Menu. I have tried using Java5 as well as Java6 jre's. Any help
in this regard would be appreciated.

Thanks
Manish
-- 
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: How to test my application with local database

2010-01-11 Thread ivanceras
BTW, I forgot the error log:

Here is it:

Caused by: javax.jdo.JDOFatalUserException: No available StoreManager
found for the datastore URL key jdbc. Please make sure you have all
relevant plugins in the CLASSPATH (e.g datanucleus-rdbms?, datanucleus-
db4o?), and consider setting the persistence property
datanucleus.storeManagerType to the type of store you are using e.g
rdbms, db4o
NestedThrowables:
org.datanucleus.exceptions.NucleusUserException: No available
StoreManager found for the datastore URL key jdbc. Please make sure
you have all relevant plugins in the CLASSPATH (e.g datanucleus-
rdbms?, datanucleus-db4o?), and consider setting the persistence
property datanucleus.storeManagerType to the type of store you are
using e.g rdbms, db4o
at
org.datanucleus.jdo.NucleusJDOHelper.getJDOExceptionForNucleusException
(NucleusJDOHelper.java:354)
at
org.datanucleus.jdo.JDOPersistenceManagerFactory.freezeConfiguration
(JDOPersistenceManagerFactory.java:544)
at
org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFactory.getPersistenceManagerFactory
(DatastoreJDOPersistenceManagerFactory.java:127)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.appengine.tools.development.agent.runtime.Runtime.invoke
(Runtime.java:100)
at javax.jdo.JDOHelper$16.run(JDOHelper.java:1956)
at java.security.AccessController.doPrivileged(Native Method)
at javax.jdo.JDOHelper.invoke(JDOHelper.java:1951)
at
javax.jdo.JDOHelper.invokeGetPersistenceManagerFactoryOnImplementation
(JDOHelper.java:1159)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(JDOHelper.java:
803)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(JDOHelper.java:
1086)
at javax.jdo.JDOHelper.getPersistenceManagerFactory(JDOHelper.java:
914)
at com.ivanceras.server.PMF.clinit(PMF.java:9)
... 37 more
Caused by: org.datanucleus.exceptions.NucleusUserException: No
available StoreManager found for the datastore URL key jdbc. Please
make sure you have all relevant plugins in the CLASSPATH (e.g
datanucleus-rdbms?, datanucleus-db4o?), and consider setting the
persistence property datanucleus.storeManagerType to the type of
store you are using e.g rdbms, db4o
at org.datanucleus.store.FederationManager.initialiseStoreManager
(FederationManager.java:197)
at org.datanucleus.store.FederationManager.init
(FederationManager.java:70)
at org.datanucleus.ObjectManagerFactoryImpl.initialiseStoreManager
(ObjectManagerFactoryImpl.java:153)
at
org.datanucleus.jdo.JDOPersistenceManagerFactory.freezeConfiguration
(JDOPersistenceManagerFactory.java:526)
... 51 more

Have you confgured yours successfully?. I tried also postgresql but
still similar error continually emerge.

Regards,
ivanceras

On Jan 4, 9:56 pm, Ian Marshall ianmarshall...@gmail.com wrote:
 Hi mobject,

 I use MySQL for developer testing when running my app on a development
 web server before unleashing it onto my GAE developer web server
 (using BigTable)!

 I give you the contents of my jdoconfig.xml file below. You will be
 able to see that I have two persistence manager factory names; I use
 one for GAE (dev server and production) and the other for my local
 MySQL dev testing.

 One warning though: I have found that JDO behaviour differs when using
 MySQL and BigTable. So until it works on BigTable, it doesn't
 necessarily work!

 Enjoy,

 Ian

 jdoconfig.xml
 -
 ?xml version=1.0 encoding=UTF-8?
 jdoconfig
   persistence-manager-factory name=big-table
     property
      name=javax.jdo.PersistenceManagerFactoryClass

 value=org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFa 
 ctory
     /

     property name=javax.jdo.option.ConnectionURL value=appengine/



     property name=datanucleus.appengine.autoCreateDatastoreTxns
 value=true/
     property name=datanucleus.autoStartMechanism value=None/
     property name=datanucleus.autoCreateSchema value=true/
     property name=datanucleus.validateTables value=true/
     property name=datanucleus.validateConstraints value=true/
     property name=datanucleus.validateColumns value=true/
 !--property name=datanucleus.persistenceByReachabilityAtCommit
 value=false/--
     property name=datanucleus.DetachAllOnCommit value=true/
 !--property name=datanucleus.detachAsWrapped value=true/--

     !--  The default value is 1  --
     property name=datanucleus.maxFetchDepth value=1/

     !--  The default value is JDO2  --
 !--property name=datanucleus.deletionPolicy value=DataNucleus/--

   /persistence-manager-factory

   persistence-manager-factory name=mysql
     property
      name=javax.jdo.PersistenceManagerFactoryClass

 

[google-appengine] Download avatar 2009 for free

2010-01-11 Thread avatar3

Download avatar 2009
In the future, Jake, a paraplegic war veteran, is brought to another planet, Pandora, which is inhabited by the Na'vi, a humanoid race with their own language and culture. Those from Earth find themselves at odds with each other and the local culture.
Download avatar 2009

-- 

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: NotSerializableException cache problem

2010-01-11 Thread Brian Wawok
Does your list use generics? Does the type of object stored in the
list implement Serializable?



On Jan 9, 6:51 pm, Amir  Michail amich...@gmail.com wrote:
 Hello,

 When attempting to put a list of ScoreData into the cache, I get this
 exception:

 Caused by: java.io.NotSerializableException:
 com.dropzap.DropZap.client.ScoreData

 Returning a list of ScoreData to the client works fine.

 Any ideas what could be wrong?  Why does serialization work in one
 case but not the other?

 Amir
-- 
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] OverQuotaError, but I have a huge allowance?

2010-01-11 Thread Emanuel
I am having problems when running an application I've built.

I add users to my application by posting text through a regular form,
the text is split by line breaks and then resulting array is then
processed one entry at the time. The user is saved and afterwards a
welcome email is sent out.

I wanted to add 74 people to my application, but the function broke
after 66 people had been added, just 6 people short, the page
displayed this error:
OverQuotaError: The API call mail.Send() required more quota than is
available.

This is odd because I have a huge allowance and according to the
dashboard email quota:
66.00 of 12000.00 Emails (1%)


While going through the array row-by-row and processing each entry at
the time I build up a string that will be displayed by the HTML once
the whole list has been processed. This string is then passed on to
the template rendering and displayed in the HTML.
Could this affect what is taking place or would it not matter?


-- 
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] Advanced query performance issue

2010-01-11 Thread Mauricio Desiderio
Hello everyone.

I am trying to figure out a way so support an advanced search need
that we have using JDO in Google Apps. Here is the scenario:

Imagine we have a Doctor object as follows:

Doctor
  Key
  Name
  List of specialties (could be a list of strings)
  Location (to keep it simple city and state)

Suppose we have 20,000 doctors in the database, and my user needs to
be able to do advanced searches based on specialty and location at the
same time, including all or including any of the specified. E.g.:

- All doctors specialized in neurology and oncology in the Chicago
or Milwaukee area
- All doctors specialized in cardiology or neurology or
physiotherapy in Aurora

Note: I only need to return the first 1000 that match the search.

I have tried a few different approaches but none had a satisfactory
performance* and supported all scenarios

* By satisfactory performance I mean measuring only the query, under
one second.

I would really appreciate any input.

Thanks!
-- 
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: How to test my application with local database

2010-01-11 Thread Ian Marshall
Hello ivanceras,


YOUR PROPERTY datanucleus.ConnectionURL
-
I do not know what your dev environment is. I use NetBeans; this has a
connection set up to use my local MySQL database. I noticed an extra
// between the jdbc: and mysql parts of your connection URL. But
you might need this for your environment. You might want to verify
your value for this property.


YOUR PROPERTY datanucleus.storeManagerType

I personally do not use this property. As you will probably know, the
relevant DataNucleus documentation describes this property as:

'Type of the StoreManager to use for this PMF/EMF. This has typical
values of rdbms, db4o. If it isn't specified then it falls back to
trying to find the StoreManager from the connection URL. The
associated DataNucleus plugin has to be in the CLASSPATH when
selecting this. When using data sources (as usually done in a JavaEE
container), DataNucleus cannot find out the correct type automatically
and this option must be set.'

I assume that your set-up requires this property (otherwise I would
suggest omitting it as I do). All I can suggest here is to verify that
you have the relevant DataNucleus plug-in and that it can be found
from your class path. I do not speak from experience about this
property since I have never used it.

Don't make the mistake I have made: ensure that you use the same
DataNucleus plug-in version number as is used by the version of GAE
that you use!


Cheers,

Ian
-- 
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] PersistenceManager multiple instances

2010-01-11 Thread Patrick Twohig
I'm having some difficulty with the PersistenceManager class.  When
running my app locally, it appears I can have multiple
PersistenceManagers open at once operating on different entity groups
at the same time.  However, when I try to do this in a JUnit test, I
end up getting all sorts of exceptions.  It stands to reason that it
should be okay opening up multiple PersistenceManagers, but my unit
tests beg to differ.  In this case, what's wrong, my code or the unit
test?  Would it be better, too, if I provided a testcase as to what's
going on?  Thanks in advance.
-- 
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: XMMP IQ stanzas App Engine ... supported ? workaround ?

2010-01-11 Thread Olemis Lang
On Thu, Jan 7, 2010 at 10:54 AM, Olemis Lang ole...@gmail.com wrote:
 Before jumping I wanted to know if the pool is empty ... ;o)

 IOW. I've been reading the XMPP API docs and I found nothing about
 support for IQ stanzas. I wanted to implement some RPC (probably SOAP)
 services using App Engine  conforming to standards XEP-0009 (probably
 XEP-0072) but both of them use IQ stanzas.

 If IQs are not supported yet then

 Q:
  - Is there a suggested workaround in order to get this done using App Engine 
 ?

 Thnx in advance !

 PS: I read an entry in the archive and know that once upon a time IQs
 were not supported, but would like to know the current situation and
 possible workarounds ... or if I have to give up and look for another
 way of implementing what I need .


Any suggestions ?

-- 
Regards,

Olemis.

Blog ES: http://simelo-es.blogspot.com/
Blog EN: http://simelo-en.blogspot.com/

Featured article:
#6396: Method `ticket.getActions` in `1.0.6` does not display actions
like in ticket UI  - http://trac-hacks.org/ticket/6396

TracRpc: Removed call to `rpc_match` inside `rpc_info`. + docs ;o)  -
http://bitbucket.org/osimons/trac-rpc-mq/changeset/f7fd46580552/
-- 
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] mazen samir wants to chat

2010-01-11 Thread mazen samir
---

mazen samir wants to stay in better touch using some of Google's coolest new
products.

If you already have Gmail or Google Talk, visit:
http://mail.google.com/mail/b-85d987f5ad-6c70274248-d63d4080d430cba1
You'll need to click this link to be able to chat with mazen samir.

To get Gmail - a free email account from Google with over 2,800 megabytes of
storage - and chat with mazen samir, visit:
http://mail.google.com/mail/a-85d987f5ad-6c70274248-d63d4080d430cba1

Gmail offers:
- Instant messaging right inside Gmail
- Powerful spam protection
- Built-in search for finding your messages and a helpful way of organizing
  emails into conversations
- No pop-up ads or untargeted banners - just text ads and related information
  that are relevant to the content of your messages

All this, and its yours for free. But wait, there's more! By opening a Gmail
account, you also get access to Google Talk, Google's instant messaging
service:

http://www.google.com/talk/

Google Talk offers:
- Web-based chat that you can use anywhere, without a download
- A contact list that's synchronized with your Gmail account
- Free, high quality PC-to-PC voice calls when you download the Google Talk
  client

We're working hard to add new features and make improvements, so we might also
ask for your comments and suggestions periodically. We appreciate your help in
making our products even better!

Thanks,
The Google Team

To learn more about Gmail and Google Talk, visit:
http://mail.google.com/mail/help/about.html
http://www.google.com/talk/about.html

(If clicking the URLs in this message does not work, copy and paste them into
the address bar of your browser).
-- 
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] OverQuotaError, but I have a huge allowance?

2010-01-11 Thread OvermindDL1
On Mon, Jan 11, 2010 at 10:44 AM, Emanuel emanuel.bergl...@gmail.com wrote:
 I am having problems when running an application I've built.

 I add users to my application by posting text through a regular form,
 the text is split by line breaks and then resulting array is then
 processed one entry at the time. The user is saved and afterwards a
 welcome email is sent out.

 I wanted to add 74 people to my application, but the function broke
 after 66 people had been added, just 6 people short, the page
 displayed this error:
 OverQuotaError: The API call mail.Send() required more quota than is
 available.

 This is odd because I have a huge allowance and according to the
 dashboard email quota:
 66.00 of 12000.00 Emails (1%)


 While going through the array row-by-row and processing each entry at
 the time I build up a string that will be displayed by the HTML once
 the whole list has been processed. This string is then passed on to
 the template rendering and displayed in the HTML.
 Could this affect what is taking place or would it not matter?

If is most likely that you were throttled, that is why you should
create a task to continue it in a few minutes.
-- 
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] Is something wrong with deployment?

2010-01-11 Thread prgmratlarge
I tried deploying multiple times to find this error:

Application: [***]; version: 3.
Server: appengine.google.com.
Scanning files on local disk.
Initiating update.
Password for [***]:
Could not guess mimetype for iphone/iui/Thumbs.db.  Using application/
octet-stre
am.
Could not guess mimetype for images/Thumbs.db.  Using application/
octet-stream.
Cloning 405 static files.
Cloned 100 files.
Cloned 200 files.
Cloned 300 files.
Cloned 400 files.
2010-01-11 21:36:53,713 ERROR __init__.py:1294 An unexpected error
occurred. Abo
rting.
Traceback (most recent call last):
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1425, in DoUpload
missing_files = self.Begin()
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1262, in Begin
CloneFiles('/api/appversion/cloneblobs', blobs_to_clone, 'static')
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1257, in CloneFiles
payload=BuildClonePostBody(chunk))
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pengine_rpc.py, line 344, in Send
f = self.opener.open(req)
  File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 381,
in open
response = self._open(req, data)
  File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 399,
in _open
'_open', req)
  File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 360,
in _call_ch
ain
result = func(*args)
  File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1115,
in https_o
pen
return self.do_open(httplib.HTTPSConnection, req)
  File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1080,
in do_open

r = h.getresponse()
  File E:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 928,
in getrespo
nse
response.begin()
  File E:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 385,
in begin
version, status, reason = self._read_status()
  File E:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 349,
in _read_st
atus
raise BadStatusLine(line)
BadStatusLine
Rolling back the update.
Traceback (most recent call last):
  File ../PortablePython_1.1_py2.5.4/google_appengine/appcfg.py,
line 67, in 
module
run_file(__file__, globals())
  File ../PortablePython_1.1_py2.5.4/google_appengine/appcfg.py,
line 63, in r
un_file
execfile(script_path, globals_)
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 2548, in module
main(sys.argv)
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 2539, in main
result = AppCfgApp(argv).Run()
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1640, in Run
self.action(self)
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 2427, in __call__
return method()
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1935, in Update
lambda path: open(os.path.join(basepath, path), 'rb'))
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1425, in DoUpload
missing_files = self.Begin()
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1262, in Begin
CloneFiles('/api/appversion/cloneblobs', blobs_to_clone, 'static')
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pcfg.py, line 1257, in CloneFiles
payload=BuildClonePostBody(chunk))
  File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
\tools\ap
pengine_rpc.py, line 344, in Send
f = self.opener.open(req)
  File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 381,
in open
response = self._open(req, data)
  File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 399,
in _open
'_open', req)
  File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 360,
in _call_ch
ain
result = func(*args)
  File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1115,
in https_o
pen
return self.do_open(httplib.HTTPSConnection, req)
  File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1080,
in do_open

r = h.getresponse()
  File F:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 928,
in getrespo
nse
response.begin()
  File F:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 385,
in begin
version, status, reason = self._read_status()
  File F:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 349,
in _read_st
atus
raise BadStatusLine(line)
httplib.BadStatusLine

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

[google-appengine] Re: How to test my application with local database

2010-01-11 Thread ivanceras
Hello ian,

Thanks for your reply.

BTW, im using eclipse 3.5 (Galileo) and had just configured the
datasource for mysql successfully.
I edited my configuration like this(commented out storeManagerType)
and the connectionURL:
I had also replaced the datanucleus jars with version 1.1.5 as its the
version GAE uses.
I used Mysql server 5.1.

  persistence-manager-factory name=mysql
property name=javax.jdo.PersistenceManagerFactoryClass
value=org.datanucleus.store.appengine.jdo.DatastoreJDOPersistenceManagerFactory/

property name=datanucleus.ConnectionDriverName
value=com.mysql.jdbc.Driver/
property name=datanucleus.ConnectionURL value=jdbc:mysql://
localhost:3306/jdo/
property name=datanucleus.ConnectionUserName value=root/
property name=datanucleus.ConnectionPassword value=[*]/
property name=datanucleus.appengine.autoCreateDatastoreTxns
value=true/
property name=datanucleus.autoStartMechanism value=None/
property name=datanucleus.autoCreateSchema value=true/
property name=datanucleus.validateTables value=true/
property name=datanucleus.validateConstraints value=true/
property name=datanucleus.validateColumns value=true/
property name=datanucleus.DetachAllOnCommit value=true/
property name=datanucleus.maxFetchDepth value=1/
!-- property name=datanucleus.storeManagerType value=rdbms/
--
  /persistence-manager-factory

But still the error persist.
Here is the error logs:

Caused by: org.datanucleus.exceptions.NucleusUserException: No
available StoreManager found for the datastore URL key jdbc. Please
make sure you have all relevant plugins in the CLASSPATH (e.g
datanucleus-rdbms?, datanucleus-db4o?), and consider setting the
persistence property datanucleus.storeManagerType to the type of
store you are using e.g rdbms, db4o
at org.datanucleus.store.FederationManager.initialiseStoreManager
(FederationManager.java:197)
at org.datanucleus.store.FederationManager.init
(FederationManager.java:70)
at org.datanucleus.ObjectManagerFactoryImpl.initialiseStoreManager
(ObjectManagerFactoryImpl.java:153)
at
org.datanucleus.jdo.JDOPersistenceManagerFactory.freezeConfiguration
(JDOPersistenceManagerFactory.java:526)
... 51 more

Here is my PMF.java class. I guess there are still more configurations
to make. I created the database jdo. I guess there will be no need to
create a table?

public final class PMF {
private static final PersistenceManagerFactory pmfInstance =
JDOHelper.getPersistenceManagerFactory(mysql);
//JDOHelper.getPersistenceManagerFactory(postgresql);
 //JDOHelper.getPersistenceManagerFactory(transactions-
optional);

private PMF() {}

public static PersistenceManagerFactory get() {
return pmfInstance;
}
}


Hope someone could help me with this.

Thanks,
ivanceras

On Jan 12, 2:54 am, Ian Marshall ianmarshall...@gmail.com wrote:
 Hello ivanceras,

 YOUR PROPERTY datanucleus.ConnectionURL
 -
 I do not know what your dev environment is. I use NetBeans; this has a
 connection set up to use my local MySQL database. I noticed an extra
 // between the jdbc: and mysql parts of your connection URL. But
 you might need this for your environment. You might want to verify
 your value for this property.

 YOUR PROPERTY datanucleus.storeManagerType
 
 I personally do not use this property. As you will probably know, the
 relevant DataNucleus documentation describes this property as:

 'Type of the StoreManager to use for this PMF/EMF. This has typical
 values of rdbms, db4o. If it isn't specified then it falls back to
 trying to find the StoreManager from the connection URL. The
 associated DataNucleus plugin has to be in the CLASSPATH when
 selecting this. When using data sources (as usually done in a JavaEE
 container), DataNucleus cannot find out the correct type automatically
 and this option must be set.'

 I assume that your set-up requires this property (otherwise I would
 suggest omitting it as I do). All I can suggest here is to verify that
 you have the relevant DataNucleus plug-in and that it can be found
 from your class path. I do not speak from experience about this
 property since I have never used it.

 Don't make the mistake I have made: ensure that you use the same
 DataNucleus plug-in version number as is used by the version of GAE
 that you use!

 Cheers,

 Ian
-- 
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: Is something wrong with deployment?

2010-01-11 Thread prgmratlarge
Hmm... Seems to be fixed... Never mind

On Jan 11, 9:39 pm, prgmratlarge yossiele...@gmail.com wrote:
 I tried deploying multiple times to find this error:

 Application: [***]; version: 3.
 Server: appengine.google.com.
 Scanning files on local disk.
 Initiating update.
 Password for [***]:
 Could not guess mimetype for iphone/iui/Thumbs.db.  Using application/
 octet-stre
 am.
 Could not guess mimetype for images/Thumbs.db.  Using application/
 octet-stream.
 Cloning 405 static files.
 Cloned 100 files.
 Cloned 200 files.
 Cloned 300 files.
 Cloned 400 files.
 2010-01-11 21:36:53,713 ERROR __init__.py:1294 An unexpected error
 occurred. Abo
 rting.
 Traceback (most recent call last):
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1425, in DoUpload
     missing_files = self.Begin()
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1262, in Begin
     CloneFiles('/api/appversion/cloneblobs', blobs_to_clone, 'static')
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1257, in CloneFiles
     payload=BuildClonePostBody(chunk))
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pengine_rpc.py, line 344, in Send
     f = self.opener.open(req)
   File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 381,
 in open
     response = self._open(req, data)
   File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 399,
 in _open
     '_open', req)
   File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 360,
 in _call_ch
 ain
     result = func(*args)
   File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1115,
 in https_o
 pen
     return self.do_open(httplib.HTTPSConnection, req)
   File E:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1080,
 in do_open

     r = h.getresponse()
   File E:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 928,
 in getrespo
 nse
     response.begin()
   File E:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 385,
 in begin
     version, status, reason = self._read_status()
   File E:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 349,
 in _read_st
 atus
     raise BadStatusLine(line)
 BadStatusLine
 Rolling back the update.
 Traceback (most recent call last):
   File ../PortablePython_1.1_py2.5.4/google_appengine/appcfg.py,
 line 67, in 
 module
     run_file(__file__, globals())
   File ../PortablePython_1.1_py2.5.4/google_appengine/appcfg.py,
 line 63, in r
 un_file
     execfile(script_path, globals_)
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 2548, in module
     main(sys.argv)
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 2539, in main
     result = AppCfgApp(argv).Run()
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1640, in Run
     self.action(self)
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 2427, in __call__
     return method()
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1935, in Update
     lambda path: open(os.path.join(basepath, path), 'rb'))
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1425, in DoUpload
     missing_files = self.Begin()
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1262, in Begin
     CloneFiles('/api/appversion/cloneblobs', blobs_to_clone, 'static')
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pcfg.py, line 1257, in CloneFiles
     payload=BuildClonePostBody(chunk))
   File F:\PortablePython_1.1_py2.5.4\google_appengine\google\appengine
 \tools\ap
 pengine_rpc.py, line 344, in Send
     f = self.opener.open(req)
   File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 381,
 in open
     response = self._open(req, data)
   File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 399,
 in _open
     '_open', req)
   File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 360,
 in _call_ch
 ain
     result = func(*args)
   File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1115,
 in https_o
 pen
     return self.do_open(httplib.HTTPSConnection, req)
   File F:\PortablePython_1.1_py2.5.4\app\lib\urllib2.py, line 1080,
 in do_open

     r = h.getresponse()
   File F:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 928,
 in getrespo
 nse
     response.begin()
   File F:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 385,
 in begin
     version, status, reason = self._read_status()
   File F:\PortablePython_1.1_py2.5.4\app\lib\httplib.py, line 349,
 in _read_st
 atus
     raise BadStatusLine(line)
 httplib.BadStatusLine

 ???
-- 
You received this message because you are subscribed to the Google Groups 

[google-appengine] Re: This App Engine is a JOKE

2010-01-11 Thread Greg
On Jan 12, 1:41 pm, mateusz mateusz.r...@gmail.com wrote:
 It's wasting time to think that you can use google app engine as
 production environment event for the smallest form based application.

It has worked very well for my business for over a year now. If you
build your application right, I see no reason why Appengine can't be
an excellent platform.

To address your email issues more specifically, you should be aware
that there is a limit to the number of emails you can send per minute,
to prevent spammers abusing the system. Because Gmail is on their own
network and is therefore under their control, it's not surprising
messages are delivered quickly. My experience is that many mail
systems introduce significant delays for spam filtering etc, but you
can't blame that on Appengine.
-- 
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] auto run tasks using dev sdk

2010-01-11 Thread Philip
I've read some articles on auto running tasks using the developer sdk
and python. The articles I've found don't provide a good workaround. I
am POSTing tasks using the Task class with parameters. I would like to
run concurrent background tasks on my dev machine. If I can only run
them single threaded, I guess that's OK for now.

What type of shell script or equivalent should I write that will
automatically run tasks by first discovering them in the queues and
then submitting them as POSTs to the appropriate queue URLs with the
original parameters?

Note: The GAE SDK is running on OS X.
-- 
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.