[appengine-java] how to share local_db.bin to others
we have 4 membership in google app engine project. we code in local Machine and manager source by subverion, in devolop ,when some one create a record(eg.create a company object) but others membership can't use this company object. is there any way to share local_db.bin to each other or all membership use same local_db.bin ? -- 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] Object property cannot accept null values.
I have create lot of Object in past. when I add a property " private double price;" to this object today .but i query the record again,the exception is throw: java.lang.NullPointerException: Datastore entity with kind PurchaseBilling and key PurchaseBilling(178) has a null property named price. This property is mapped to com.datong.drp.model.PurchaseBilling.price, which cannot accept null values. I must clear all data and insert again? is there any other method to add this property? -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to share local_db.bin to others
thanks to John Patterson as you said, i do 1.copy /WEB-INF/appengine-generated/ to D:/ and delete the old local_db.bin 2.create showcut (D:\appengine-generated\local_db.bin) and copy to / WEB-INF/appengine-generated/ 3.restart server. but the exception throws: java.lang.NullPointerException at java.util.concurrent.ConcurrentHashMap.put(ConcurrentHashMap.java: 881) at com.google.appengine.tools.development.LocalHttpRequestEnvironment.(LocalHttpRequestEnvironment.java: 45) at com.google.appengine.tools.development.JettyContainerService $ApiProxyHandler.handle(JettyContainerService.java:348) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java: 139) at org.mortbay.jetty.Server.handle(Server.java:313) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java: 506) at org.mortbay.jetty.HttpConnection $RequestHandler.headerComplete(HttpConnection.java:830) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:514) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java: 396) at org.mortbay.thread.BoundedThreadPool $PoolThread.run(BoundedThreadPool.java:442) -- 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: Unable to run on local server after an upgrade to 1.2.8
please clean the brower cookie. i don't know why but it works for me -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to share local_db.bin to others
you are right ,thanks a lot. when i clean the browse cookie . the exception is ok. follow your method, in my windows xp system command line: "linkd D:/drp/war/WEB-INF/appengine-generated d:/appengine-generated " create a symbolic link, I't success to write to the two files(D:/drp/ war/WEB-INF/appengine-generated/local_db.bin and d:/appengine- generated/local_db.bin) and can read the new record.but when i use "linkd D:/drp/war/WEB-INF/appengine-generated //192.168.1.5/share/ appengine-generated(a network path)" it's failure。 share to 4 programers ,local_db.bin need to be share to network path. is there any other way? -- 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: Object property cannot accept null values.
it's pretty well. thank a lot -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to share local_db.bin to others
thanks for your attention. We Persistence Object by JDO in our Project, All model are like @PersistenceCapable(identityType = IdentityType.APPLICATION) public class SysCode extends BaseModel { //code_id @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String sys_code_id; //code_type @Persistent private String code_type; //code_key @Persistent private String code_key; //code_value @Persistent private String code_value; //remark @Persistent private String remark; public void setSys_code_id(String sys_code_id) { this.sys_code_id = sys_code_id; } public String getSys_code_id() { return sys_code_id; } ... } On 2月5日, 下午4時31分, Guillaume Laforge wrote: > I'd be curious to know what's the format of that database bin file. > That would perhaps be interesting to be able to create such local dbs > easily, for creating data fixtures for our unit and/or integration > tests. > Is it some form of SQLLite, or some custom object serialization? > > Guillaume > > > > On Wed, Feb 3, 2010 at 14:23, dreamy wrote: > > we have 4 membership in google app engine project. we code in local > > Machine and manager source by subverion, in devolop ,when some one > > create a record(eg.create a company object) but others membership > > can't use this company object. > > > is there any way to share local_db.bin to each other or all > > membership use same local_db.bin ? > > > -- > > 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. > > -- > Guillaume Laforge > Groovy Project Manager > Head of Groovy Development at SpringSourcehttp://www.springsource.com/g2one -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to share local_db.bin to others
We have no success to implement gae junit test. We use spring 2.5.6 and follow the http://code.google.com/appengine/docs/java/howto/unittesting.html . public class BaseTestCase extends AbstractDependencyInjectionSpringContextTests { @Override public void onSetUp() throws Exception { ApiProxy.setEnvironmentForCurrentThread(new TestEnvironment()); ApiProxy.setDelegate(new ApiProxyLocalImpl(new File("D:/work/ drp/src/drp/war")){}); super.onSetUp(); } @Override public void onTearDown() throws Exception { super.onTearDown(); // not strictly necessary to null these out but there's no harm either ApiProxy.setDelegate(null); ApiProxy.setEnvironmentForCurrentThread(null); } public String[] getConfigLocations() { String[] configLocations = { "file:war/WEB-INF/ applicationContext.xml" }; return configLocations; } } but when run junit test. the exception is throw Failed to load from the backing store, D:\work\drp\src\drp\war\WEB-INF \appengine-generated\local_db.bin java.io.InvalidClassException: com.google.appengine.api.datastore.dev.LocalDatastoreService$Profile; local class incompatible: stream classdesc serialVersionUID = -6517584213397327068, local class serialVersionUID = -5383535353082918279 at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:562) at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java: 1583) at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java: 1496) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java: 1732) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351) at java.util.HashMap.readObject(HashMap.java:1030) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java: 39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java: 25) at java.lang.reflect.Method.invoke(Method.java:597) at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java: 974) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java: 1849) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java: 1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java: 1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java: 1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java: 1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351) at com.google.appengine.api.datastore.dev.LocalDatastoreService.load(LocalDatastoreService.java: 949) at com.google.appengine.api.datastore.dev.LocalDatastoreService.start_(LocalDatastoreService.java: 281) at com.google.appengine.api.datastore.dev.LocalDatastoreService.access $300(LocalDatastoreService.java:90) at com.google.appengine.api.datastore.dev.LocalDatastoreService $1.run(LocalDatastoreService.java:273) at java.security.AccessController.doPrivileged(Native Method) at com.google.appengine.api.datastore.dev.LocalDatastoreService.start(LocalDatastoreService.java: 271) at com.google.appengine.tools.development.ApiProxyLocalImpl.startServices(ApiProxyLocalImpl.java: 373) at com.google.appengine.tools.development.ApiProxyLocalImpl.access $500(ApiProxyLocalImpl.java:42) at com.google.appengine.tools.development.ApiProxyLocalImpl $2.run(ApiProxyLocalImpl.java:356) at com.google.appengine.tools.development.ApiProxyLocalImpl $2.run(ApiProxyLocalImpl.java:354) at java.security.AccessController.doPrivileged(Native Method) at com.google.appengine.tools.development.ApiProxyLocalImpl.getService(ApiProxyLocalImpl.java: 353) at com.google.appengine.tools.development.ApiProxyLocalImpl.makeSyncCall(ApiProxyLocalImpl.java: 100) at com.google.apphosting.api.ApiProxy.makeSyncCall(ApiProxy.java:83) at com.google.appengine.api.datastore.DatastoreApiHelper.makeSyncCall(DatastoreApiHelper.java: 52) at com.google.appengine.api.datastore.DatastoreServiceImpl.beginTransaction(DatastoreServiceImpl.java: 516) at org.datanucleus.store.appengine.RuntimeExceptionWrappingDatastoreService.beginTransaction(RuntimeExceptionWrappingDatastoreService.java: 209) at org.datanucleus.store.appengine.DatastoreXAResource.start(DatastoreXAResource.java: 63) at org.datanucleus.transaction.Transaction.enli
[appengine-java] Re: how to share local_db.bin to others
If local_db.bin is not large, you can open it ultraEdit or notepad and find by id or a specal key On Feb 8, 4:56 pm, Andrés Cerezo wrote: > Hello, Is there a way to see the data of the > WEB-INf/appengine-generated/local_db.bin from Eclipse? > > Thanks. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] how to build same entity group
I have two entity. @PersistenceCapable(identityType = IdentityType.APPLICATION) public class Person{ @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String person_id; } public class Telephone{ @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String telephone_id; @Persistent private String person_id; //this field point to Person } Person Module manager Person create/update/delete/query Telephone module manaer telephone create/update/delete/query Person can have 0 or mulity telephone but telephone only point to one person or Telephone.person_id=null Now there is a third module manager relation of Person and Telephone . if person have telephone( telephone1,telephone2,telephone3) and user update person's telephone is telephone2,telephone3,telephone4,how to implements this? is there and code example? thants a lot -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to build same entity group
Hello Ikai L thanks for your reply. You just have to persist the Person first, or create a Person, attach Telephone entities, then call pm.makePersistent() on the Person. >>but this is problem. Telephone must not belong to Person. Telephone module manaer telephone create/update/delete/query , telphone have many active or property to be managered and then there is no idea of Person I need set Telephone.person only after this person have buy the telephone. there is any other idea ? thanks a lot -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to build same entity group
for instance, you can just use a Key and reference the Person in the Telephone. >you are right. and i just do it as you say. public class Telephone{ @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String telephone_id; @Persistent private String person_id; //this field point to Person } my question is " if person have telephone( telephone1,telephone2,telephone3) and user update person's telephone is telephone2,telephone3,telephone4,how to implements this? " but in a same transactions , I need update 2 telephone object .--telephone1.person_id=null telephone4.person_id=person_id. and the 2 telephone object is not in same entity group. the question seem to equal " how to update multi object (same class) in same transaction?" Thank you for your help -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to build same entity group
Thanks to Chau Huynh. as you said, how to find all the list of telephone( has belong to a person )? because of these telephone can't sale again. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-j...@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
[appengine-java] Re: how to build same entity group
now i have done it by part transaction. use case: Person buy three Telephone update Person property(and other sub class property) ---use transaction update three Telephone.person_id=person_id. not use transaction thanks to all -- 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: Trying a clean compile gives "The parameter is incorrect"
As you said, when Enhance classes is little ,there is OK, but when Enhance classes has many many(ex: 200 classes) ,the same problem is appear. how to do with it? -- 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] Problems upgrading sdk from 1.3.0 to 1.3.2
my app engine application use sdk 1.3.0, i have insert many data into local_db.bin. today ,i update sdk 1.3.2 , when i use "http:// localhost:/_ah/admin" ,find all data can't query out? but local_db.bin size is not changed .why? when i insert new data by environment of sdk 1.3.2 ,it can by queryed out, the old data can't be queryed out. -- 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.