Announcement

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

    Strange errorlog in TimeLine when loading data

    Hi, i'm getting some really strange errors when i load data in my Timeline:

    "getVisibleEvents() encountered a place-holder for a loading record, rather than a valid record"

    I'm kind of at a loss for what that means, all my events are loaded from the server, and have ID's. From what i can tell, the events do end up in the timeline when all is finished.

    If you had any pointer as to where i should start looking, i'd appreciate it.


    ERROR: 23:36:10.686:XRP2:WARN:TimelineView:isc_MyScheduleTimeline_0_timelineView:timeline.getVisibleEvents() encountered a place-holder for a loading record, rather than a valid record. Can't continue: "\r\n CalendarView.getVisibleEvents(_1=>null)\r CalendarView.refreshVisibleEvents(_1=>null, _2=>null, _3=>\"refreshEvents\")\r CalendarView.refreshEvents()\r Calendar.refreshSelectedView()\r Calendar.dataChanged()\r anonymous(operationType=>undef, originalRecord=>undef, rowNum=>undef, updateData=>undef, filterChanged=>undef, dataFromCache=>undef)\r thunk(operationType=>undef, originalRecord=>undef, rowNum=>undef, updateData=>undef, filterChanged=>undef, dataFromCache=>undef)\r dataChangedObservation(undef, undef, undef, undef, undef, undef)\r ResultSet.$ee(_1=>undef, _2=>undef)\r ResultSet.$390(_1=>Array[75], _2=>Obj)\r ResultSet.fetchRemoteDataReply(dsResponse=>Obj, data=>Array[75], request=>Obj)\r [c]Class.fireCallback(_1=>Obj, _2=>\"dsResponse,data,dsRequest\", _3=>Array[3], _4=>[DataSource ID:schedule], _5=>undef)\r [a]MathFunction.fireCallback(_1=>Obj, _2=>\"dsResponse,data,dsRequest\", _3=>Array[3], _4=>undef)\r DataSource.fireResponseCallbacks(_1=>Obj, _2=>Obj, _3=>Obj, _4=>Obj)\r DataSource.$38b(_1=>Array[75], _2=>Obj, _3=>Obj, _4=>Obj, _5=>Obj)\r DataSource.$50h(_1=>Obj, _2=>Array[75], _3=>Obj)\r ** recursed on [c]Class.fireCallback\r"
    com.smartgwt.client.core.JsObject$SGWT_WARN: 23:36:10.686:XRP2:WARN:TimelineView:isc_MyScheduleTimeline_0_timelineView:timeline.getVisibleEvents() encountered a place-holder for a loading record, rather than a valid record. Can't continue: "\r\n CalendarView.getVisibleEvents(_1=>null)\r CalendarView.refreshVisibleEvents(_1=>null, _2=>null, _3=>\"refreshEvents\")\r CalendarView.refreshEvents()\r Calendar.refreshSelectedView()\r Calendar.dataChanged()\r anonymous(operationType=>undef, originalRecord=>undef, rowNum=>undef, updateData=>undef, filterChanged=>undef, dataFromCache=>undef)\r thunk(operationType=>undef, originalRecord=>undef, rowNum=>undef, updateData=>undef, filterChanged=>undef, dataFromCache=>undef)\r dataChangedObservation(undef, undef, undef, undef, undef, undef)\r ResultSet.$ee(_1=>undef, _2=>undef)\r ResultSet.$390(_1=>Array[75], _2=>Obj)\r ResultSet.fetchRemoteDataReply(dsResponse=>Obj, data=>Array[75], request=>Obj)\r [c]Class.fireCallback(_1=>Obj, _2=>\"dsResponse,data,dsRequest\", _3=>Array[3], _4=>[DataSource ID:schedule], _5=>undef)\r [a]MathFunction.fireCallback(_1=>Obj, _2=>\"dsResponse,data,dsRequest\", _3=>Array[3], _4=>undef)\r DataSource.fireResponseCallbacks(_1=>Obj, _2=>Obj, _3=>Obj, _4=>Obj)\r DataSource.$38b(_1=>Array[75], _2=>Obj, _3=>Obj, _4=>Obj, _5=>Obj)\r DataSource.$50h(_1=>Obj, _2=>Array[75], _3=>Obj)\r *

    #2
    You say "all my events are loaded from the server" - do you mean they are always loaded all at once, and never incrementally (as a ResultSet does)?

    If you never use load on demand, this suggests that you call some kind of Timeline API that requires the widget to look at the set of events, but you do this before any of the events have loaded. Or similarly, you do so right after clearing cache while events are still being re-loaded from the server.

    Comment


      #3
      I just meant that i don't create any data in the client code.

      I have defined a datasource that fetches all data with start-end dates from a springcomponent i have defined in my .ds-file. It gets called correctly from the server with startrow and endrow, i do calcs and set the totalrows in the response, as i do with all other datasources that work fine.

      This is my Timeitem class constructor that causes the explosion in the logs, when it is displayed and fetches data from the server, since autofetchdata is set.

      EDIT: as you can see, i load and set the lanes in the constructor, which i guess would mean that it happens in parallell to the autofetchdata call. Surely that should not be an issue?

      Code:
      public GenericTimeline(DataSource dataSource, DataSource laneDS, final String laneNameField) {
              super();
              this.laneNameField = laneNameField;
              this.laneDS = laneDS;
              setDataSource(dataSource);
              setAutoFetchData(true);
              setWidth100();
              setHeight100();
              loadLanes();//sets the rows
              
              setCanEditEvents(canEditEvents);
              Date begin = new Date();
              Date end = new Date();
              CalendarUtil.addMonthsToDate(end, 1);
              setStartDate(begin);
              setEndDate(end);
              setCanEditLane(false);
              setShowEventDescriptions(true);
              setLaneNameField(ClientServerConstants.FIELD_REPORTERID);//this is what must match the "id" values for the lane data
      
              setStartDateField("inTime");
              setEndDateField("outTime");
              setNameField(ClientServerConstants.FIELD_LOCATIONNAME);
              setShowEventDescriptions(true);
              setDescriptionField("note");
      
      
              setMinLaneWidth(130);
              setTimeFormatter(TimeDisplayFormat.TOSHORTPADDED24HOURTIME);
      
              setHeaderLevels(createHeaderLevels());
              setLaneFields(new ListGridField[]{new ListGridField("title", CommonConstants.constants.reportUser(), CommonConstants.FIELD_WIDTH_REPORTERNAME)});
              setLaneEventPadding(2);
              setEventStyleName("nubaEventWindow");
              setDataSource(ds);
      
          }
          
          
          public void loadLanes(){
              Criteria crit = new Criteria();
              crit.setAttribute("enabled", true);
              laneDS.fetchData(crit, new DSCallback() {
                  @Override
                  public void execute(DSResponse dsResponse, Object o, DSRequest dsRequest) {
                      Record[] data = dsResponse.getData();
                      Lane[] lanes = new Lane[dsResponse.getData().length];
                      for (int i = 0; i < data.length; i++) {
                          lanes[i] = new Lane(data[i].getAttribute("id"), data[i].getAttribute(laneNameField));
                      }
                      setLanes(lanes);              
                  }
              });
          }

      Comment


        #4
        Our apologies - we neglected to update this thread.

        Many changes have been made since your post that should address these logs you were seeing (which were related to CalendarView.refreshEvents() running before data had actually arrived at the client) - please retest with the most recent build from smartclient.com/builds - if you still see these logs, please provide a minimal, runnable test-case that we can run on our end to see the issue, and we'll take another look.

        Comment


          #5
          No worries, it's only been 4 months... i had given up on this, so not sure about current status. Will look when i have time.

          Comment


            #6
            Yes, it's been a while, and it's also been fixed for a while - as we noted, we neglected to update the thread.

            If you need responses with fixed ETAs, consider purchasing support.

            Comment

            Working...
            X