[appengine-java] Text Search API
It seems as if documentation for the Full Text Search API has appeared online as well as being included in the 1.6 java api. Is this supported in appengine now? URL of the api: http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/search/IndexManager.html -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine-java/-/PDoCmT-J_jMJ. To post to this group, send email to google-appengine-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
Re: [appengine-java] Correct way to keep track of the number of Entities of one kind.
Thank you very much! This is a good intuitive example. I only worked with relational databases in 'small' projects so far. That's why I'm often not certain about how things should be elegantly done in a scalable environment. I also found a video from Brett Slatkin which helped me out: http://www.youtube.com/watch?v=AgaL6NGpkB8 (Google I/O 2009 - Building Scalable, Complex Apps on App Engine) -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine-java/-/E502xShiZukJ. To post to this group, send email to google-appengine-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Correct way to keep track of the number of Entities of one kind.
Hello, I use Java with JDO for the datastore access on google app engine. I need the number of rows for the calculation of the number of pages in a cell table. This number can be very high so I don't want to calculate it when i query the data and implemented a class which holds the number of Entities: import javax.jdo.annotations.PersistenceCapable; import javax.jdo.annotations.Persistent; import javax.jdo.annotations.PrimaryKey; @PersistenceCapable public class Aggregate { @PrimaryKey @Persistent private String name; @Persistent private int count; public Aggregate(String name) { this.name = name; this.count = 0; } public String getName() { return this.name; } public void setName(String name) { this.name = name; } public int getCount() { return this.count; } public void setCount(int count) { this.count = count; } } To update the count value I do something like that. @PersistenceCapable public class SomeEntity { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key key; .. public SomeEntity() { // increment the count PersistenceManager pm = PMF.get().getPersistenceManager(); try { Aggregate aggregate = (Aggregate) pm.getObjectById(Aggregate.class, SomeEntity.class.getSimpleName()); int count = aggregate.getCount(); count++; aggregate.setCount(count); pm.makePersistent(aggregate); } catch (JDOObjectNotFoundException jonfe) { // the first "someEntity" ever Aggregate aggregate = new Aggregate(Player.class.getSimpleName()); aggregate.setCount(1); pm.makePersistent(aggregate); } finally { pm.close(); } } . So far, this works, but I really don't like the way how it's done. Are there any implemented tools in google app engine to handle something like that? Or is this the correct way to keep track of the number of entities? -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine-java/-/lK9o1_SMdygJ. To post to this group, send email to google-appengine-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: Chat Time!
Jason, Can't make it Wednesday. Is JAX-WS support planned? -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] javax.mail can't resolve import
I'm trying to use the various components of javax.mail in a GWT app, and I'm stumped as to how to get these imports to resolve. I don't have any errors showing up in the Eclipse editor (I used to, but don't any more for some reason), but the errors show up when I run the app as a web application on my local machine, and also when I run it from appspot. I am trying to add it to my classpath (project properties -> libraries) but I don't know where to find it in a jar file. How does one know where to look? Is this even necessary? [DEBUG] [pcrequest] - Validating newly compiled units [ERROR] [pcrequest] - Errors in 'file:/C:/java_projects/PCRequest/src/ com/tempusnova/kohls/client/EmailRequest.java' [ERROR] [pcrequest] - Line 8: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 9: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 10: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 11: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 12: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 13: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 14: The import javax.mail cannot be resolved [ERROR] [pcrequest] - Line 24: Session cannot be resolved to a type [ERROR] [pcrequest] - Line 24: Session cannot be resolved [ERROR] [pcrequest] - Line 30: Message cannot be resolved to a type [ERROR] [pcrequest] - Line 30: MimeMessage cannot be resolved to a type [ERROR] [pcrequest] - Line 31: InternetAddress cannot be resolved to a type [ERROR] [pcrequest] - Line 32: Message cannot be resolved [ERROR] [pcrequest] - Line 32: InternetAddress cannot be resolved to a type [ERROR] [pcrequest] - Line 35: Transport cannot be resolved [ERROR] [pcrequest] - Line 37: AddressException cannot be resolved to a type [ERROR] [pcrequest] - Line 39: MessagingException cannot be resolved to a type [INFO] [pcrequest] - Module pcrequest has been loaded I'm using a java email class similar to the following: http://code.google.com/appengine/docs/java/mail/usingjavamail.html Any ideas would 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-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Loading child entities with JPA
I am not able to get child entities to load once they are persisted. I am certain that they are saving because I can see them in the datastore if I deploy an application and try it. For example if I have the following two entities... public class Parent implements Serializable{ @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String key; @OneToMany(cascade=CascadeType.ALL) private List children = new ArrayList(); //getters and setters } public class Child implements Serializable{ @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String key; private String name; @ManyToOne private Parent parent; //getters and setters } I can save the parent and a child just fine using the following: Parent parent = new Parent(); Child child = new Child(); child.setName("Child Object"); parent.getChildren().add(child); em.persist(parent); However when I try to load the parent and then try to access the children (I know GAE lazy loads) I do not get the child records. //parent already successfully loaded parent.getChildren.size(); // this returns 0 I've looked at tutorial after tutorial and nothing has worked so far. I'm using version 1.3.3.1 of the SDK. I've seen the problem mentioned on various blogs and even the App Engine group I believe but the answer is always JDO related (dealing with fetch groups). Am I doing something wrong or has anyone else had this problem and solved it for JPA? -- 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.