Hello:
If someone has any experience with client-only data source I would really appreciate some insight. From my experience with client-only data sources nothing works as advertised. For example here is a datasource that I have that talks to my back-end PHP scripts connected to MYSQL:
Simple enough. But when I set the setAutoCacheAllData to true I get the following error message:
TMR1:WARN:ResultSet:isc_ResultSet_6 (created by: undefined):cacheAllData - cacheResultSet.dataArrived: startRow/endRow: 0/0
com.smartgwt.client.core.JsObject$SGWT_WARN: 08:27:54.330:TMR1:WARN:ResultSet:isc_ResultSet_6 (created by: undefined):cacheAllData - cacheResultSet.dataArrived: startRow/endRow: 0/0
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:105)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:157)
at com.google.gwt.dev.shell.BrowserChannel.reactToMessages(BrowserChannel.java:1668)
at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:401)
at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:222)
at java.lang.Thread.run(Thread.java:637)
I've asked this question before and have never received an answer. If someone... SOMEONE has worked with client-side data sources and/or caching I would really appreciate it.
Thanks.
Chris
If someone has any experience with client-only data source I would really appreciate some insight. From my experience with client-only data sources nothing works as advertised. For example here is a datasource that I have that talks to my back-end PHP scripts connected to MYSQL:
Code:
public class ContactsLimitedDataSource extends RestDataSource{ public ContactsLimitedDataSource(String id){ setID(id); setShowPrompt(false); setDataFormat(DSDataFormat.JSON); setDataProtocol(DSProtocol.POSTPARAMS); setDataURL(Utils.constants.url()); HashMap<String, String> m = new HashMap<String, String>(); m.put("app", "contacts"); m.put("cmd", "getlist"); m.put("limit","yes"); setDefaultParams(m); setAddDataURL(Utils.constants.url()); DataSourceIntegerField idField = new DataSourceIntegerField("id"); idField.setPrimaryKey(true); idField.setHidden(true); DataSourceTextField nameField = new DataSourceTextField("name"); DataSourceIntegerField typeField = new DataSourceIntegerField("ttype"); setFields(idField,nameField,typeField); } }
TMR1:WARN:ResultSet:isc_ResultSet_6 (created by: undefined):cacheAllData - cacheResultSet.dataArrived: startRow/endRow: 0/0
com.smartgwt.client.core.JsObject$SGWT_WARN: 08:27:54.330:TMR1:WARN:ResultSet:isc_ResultSet_6 (created by: undefined):cacheAllData - cacheResultSet.dataArrived: startRow/endRow: 0/0
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:105)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:157)
at com.google.gwt.dev.shell.BrowserChannel.reactToMessages(BrowserChannel.java:1668)
at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:401)
at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:222)
at java.lang.Thread.run(Thread.java:637)
I've asked this question before and have never received an answer. If someone... SOMEONE has worked with client-side data sources and/or caching I would really appreciate it.
Thanks.
Chris
Comment