question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TileLayer perfomance issue

See original GitHub issue

Hi, I found a strange performance issue - I added a TileLayer to the SceneView and started zooming in and out. In my Chrome’s performance monitor DOM nodes began to increase, and the garbage collector not removing them - only a small part of them.

Description

I used jsapi-resources demo page, and that’s my code for adding a layer to the SceneView:

import "./config";

import TileLayer from "esri/layers/TileLayer";
import ArcGISMap from "esri/Map";
import SceneView from "esri/views/SceneView";

const map = new ArcGISMap();

const view = new SceneView({
    map,
    container: "app",
    extent: {
        spatialReference: {
            wkid: 102100
        },
        xmax: -13581772,
        xmin: -13584170,
        ymax: 4436367,
        ymin: 4435053
    }
});

const tileLayer = new TileLayer({url: 'https://sampleserver6.arcgisonline.com/arcgis/rest/services/World_Street_Map/MapServer'});

map.add(tileLayer);

Expected Behavior

Garbage collector should remove the DOM nodes which are not using anymore.

Actual Behavior

The amount of DOM nodes increases while using a map-based app for a long time. I added only a small part of the video - I zoomed in for a minute, or so, and the amount of DOM nodes increased from ~100 to 7,000. The garbage collector removed only a small part from this amount.

arcgis_tilelayer

Steps to Reproduce

  1. Create Map and SceneView
  2. Add TileLayer to the Map
  3. Start to zoom in and out
  4. Open the performance monitor and watch the amount of DOM nodes and JS event listeners

Context

We noticed a lack of performance when the users of our app using it for a long time.

Your Environment

  • Version used: 4.13
  • Browser Name and version: Google Chrome version 78.0.3904.70 (Official Build) (64-bit)
  • Operating System and version (desktop or mobile): Desktop, Windows 10

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
besLisbethcommented, Dec 27, 2019

Thanks for your work, tiles working perfectly now!

1reaction
besLisbethcommented, Nov 25, 2019

Thank you a lot, I’ll test it as soon as it will be published at the github page

Read more comments on GitHub >

github_iconTop Results From Across the Web

Laggy pan-performance with multiple tile layers (Desktop ...
Pan around trying to stick to newly high zoom level rendered tiles to see responsiveness drop (you might need a larger screen to...
Read more >
Openlayers 6.3.1 - rendering tilelayers - Stack Overflow
In my project I have more then 20 TileLayers (TileWMS), and the loading, panning, scrolling performance worse then in openlayers 5.
Read more >
Openlayers ArcGIS image vs tile service performance
ImageLayer gets large size images like 1390x800 px. But TileLayer gets smaller size images like 256px. I am using dynamic ArcGIS REST service....
Read more >
Tile layers—ArcGIS Online Help | Documentation
Tile layers can be stored as prerendered raster tiles or as vector tiles. Both raster and vector tiles are designed to provide high-performance...
Read more >
L.TileLayer
Option Type Default minZoom Number 0 maxZoom Number 18 maxNativeZoom Number null
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found