Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    3.0 to 3.1 port error on DataSource

    Hello,

    Using Smart GWT 3.0 thought I would see if 3.1 was ok.

    I get a "new" error, not present in 3.0. Seems the way I tried out DataSource is not legal

    Here is the error

    Thanks,
    Evan

    13:41:44.440 [ERROR] [winter] 13:41:44.420:XRP6:WARN:RPCManager:DSRequest for DataSource 'facetAIE' contained AdvancedCriteria, which the DataSource does not support, response: {operationId: "facetAIE_fetch",
    clientContext: Obj,
    context: Obj,
    transactionNum: 11,
    httpResponseCode: 200,
    httpResponseText: "//isc_RPCResponseStart-->[{data:"DSReque..."[222],
    xmlHttpRequest: [object XMLHttpRequest],
    transport: "xmlHttpRequest",
    status: -1,
    clientOnly: undef,
    httpHeaders: Obj,
    isStructured: true,
    callbackArgs: null,
    results: Obj,
    data: "DSRequest for DataSource 'facetAIE' cont..."[101],
    invalidateCache: false,
    isDSResponse: true,
    queueStatus: -1,
    startRow: 0,
    endRow: 0,
    totalRows: 0}

    com.smartgwt.client.core.JsObject$SGWT_WARN: 13:41:44.420:XRP6:WARN:RPCManager:DSRequest for DataSource 'facetAIE' contained AdvancedCriteria, which the DataSource does not support, response: {operationId: "facetAIE_fetch",
    clientContext: Obj,
    context: Obj,
    transactionNum: 11,
    httpResponseCode: 200,
    httpResponseText: "//isc_RPCResponseStart-->[{data:"DSReque..."[222],
    xmlHttpRequest: [object XMLHttpRequest],
    transport: "xmlHttpRequest",
    status: -1,
    clientOnly: undef,
    httpHeaders: Obj,
    isStructured: true,
    callbackArgs: null,
    results: Obj,
    data: "DSRequest for DataSource 'facetAIE' cont..."[101],
    invalidateCache: false,
    isDSResponse: true,
    queueStatus: -1,
    startRow: 0,
    endRow: 0,
    totalRows: 0}
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
    at java.lang.reflect.Constructor.newInstance(Unknown Source)
    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:172)
    at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:337)
    at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:218)
    at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
    at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
    at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:289)
    at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107)
    at com.google.gwt.user.client.Window.alert(Window.java)
    at com.smartgwt.client.SmartGwtEntryPoint$1.onUncaughtException(SmartGwtEntryPoint.java:278)
    at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:215)
    at sun.reflect.GeneratedMethodAccessor37.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
    at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
    at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
    at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:292)
    at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:546)
    at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
    at java.lang.Thread.run(Unknown Source)

    #2
    This may be a regression (we'll check on it) but you can work around it by setting allowAdvancedCriteria="true" on the DataSource.

    Comment


      #3
      Hello,

      Thank you for the quick response. I have backed out of the changes for this week. But will certainly try again soon.

      On an unrelated question:

      We are still in the eval phase of our product design usage.

      When we buy the product are we able to activate the existing eval SDK (we have GWT 3.0) or do we need to activate the current 3.1? How long does the "buy" process take to get a license.

      Thanks,
      Evan

      Comment


        #4
        You can download either version (3.0 or 3.1) but getting the licensed copy is always a new download, not "activating" anything in place.

        If you pay by credit card, you can immediately download.

        Comment


          #5
          Hello,

          Tried out the 3.1 port again, but still get a new error from one of my datasources defined in 3.0.

          Ideas?

          Still get the error, tried the setting. Here is my code
          private static final DataSource FACET_DS =
          DataSource.get(DataSourceInfo.FACET_DATASOURCE_PATH_ID);

          latter I do the setting

          FACET_DS.setAllowAdvancedCriteria(true);
          grid.setDataSource(FACET_DS);

          Here is the data source defined

          <DataSource ID="facetAIE" serverConstructor="com.relay.winter.server.AttivioFacetDataSource">
          <fields>
          <field name="field" title="Field" type="text" hidden="true" />
          <field name="label" title="Label" type="text" />
          <field name="count" title="Count" type="integer" />
          </fields>
          </DataSource>

          And here is some of my class on the server
          public class AttivioFacetDataSource extends AbstractAttivioDataSource {
          private static final long serialVersionUID = 1L;

          @SuppressWarnings("rawtypes")
          @Override
          public DSResponse executeFetch(DSRequest req) throws Exception {
          List records = fetchRecords(req.getAdvancedCriteria());
          DSResponse dsr = new DSResponse(records);
          dsr.setDataSource(this);
          return dsr;
          }

          @SuppressWarnings("rawtypes")
          private List fetchRecords(AdvancedCriteria criteria) {
          List<Map<String, Object>> res = new ArrayList<Map<String, Object>>();
          try {

          Thanks,
          Evan

          Comment


            #6
            You need to allowAdvancedCriteria in your .ds.xml file, not in client-side code.

            Also, this problem has already been fixed if you get a more recent 3.1d build.

            Comment


              #7
              cool, and thanks will download the new version and try it out.

              Comment


                #8
                listGridRank.addSelectionUpdatedHandler(new SelectionUpdatedHandler() {


                In version 3.1 this handler is not being called on our grid, while in 3.0 Smart GWT it was.

                Is this enough information or do you need more?

                Evan

                Comment


                  #9
                  got 3.1d working with our code! So have moved from 3.0 to 3.1d

                  I am explicitly using the scripts from ISC in my project, but don't see them in 3.1d samples

                  In 3.0 the directory
                  D:\library\smartgwtee-3.0p\samples\built-in-ds\war\builtinds\sc

                  we present, but is not in 3.1d

                  as my html file explicitly includes there 3.0 scripts.

                  Are they going to be updated for 3.1d? Or should one do something else.

                  Attached is my html file including these scripts

                  Evan
                  Attached Files

                  Comment


                    #10
                    There's nothing we need to update here; sounds like you may have just forgotten to run a GWT compile.

                    Comment


                      #11
                      Hello,

                      the following code compiled in Smart GWT 3.0 but not in 3.1 SEeems the handler no longer exists. What does one use now?

                      Evan

                      SectionHeaderClickHandler handlerHeader = new SectionHeaderClickHandler() {
                      @Override
                      public void onSectionHeaderClick(SectionHeaderClickEvent event) {
                      // SC.say("section header click handler");
                      SectionStackSection sss = event.getSection().getSection();
                      sssCurrentSelectedFacet = sss;
                      updateFacets();
                      }

                      };
                      sectionStack.addSectionHeaderClickHandler(handlerHeader);

                      Comment

                      Working...
                      X