Results comments of sillies_3

不知道您是怎么验证的,我是写了两个setTimeout,第一个setTimeout里面的图片名称(test)是随便写的一个,第二个setTimeout里面的图片名称(05)是真实存在的: // 测试代码 ``` setTimeout(() => { imageLayer.shape('test') scene.render(); }, 1000) setTimeout(() => { imageLayer.shape('05') scene.render(); }, 2000) ``` 我这么测试是会报异常的

demo地址: https://codesandbox.io/p/sandbox/vigilant-lovelace-42k9z9?file=%2Findex.js

@dead-horse 当使用CAS做单点登出的时候,是需要获取session id的。原因: 如果有A,B两个子系统。它们都处于登录状态,当B系统退出登录,A系统也需要自动退出,这样A系统之前存储在redis中的session就需要手动进行销毁。现在因为没有sessionId,无法销毁session,导致A系统刷新页面,仍然处于登录状态。 提到的配置opts.genid,我在config.default.js中: config.session = { genid: () => return uuid;} 但存在的问题是,config.default.js中无法获取ctx,如何将该id传到middleware中进行使用呢? 我看了koa-session源码,不知道作者出于什么样的考虑,没有在context.js的create方法中将生成的externalKey挂载到session上 我现在的解决方案是: 1、修改源码,在create方法中,this.session.id = this.externalKey; 2、从cookie中获取,this.session.id = ctx.cookies.get('EGG_SESS', ctx.sessionOptions); 这样做会有什么潜在的问题吗?

逻辑是这样的: 如果没有开启redis,即session没有配置store的情况下,egg-session会对session中的内容进行加密,然后以EGG_SESS(默认的)为key,将其存储在cookie里发送到浏览器。下次请求,再将cookie中的内容进行解密,恢复到服务器的session里。 如果开启redis,即session配置了store,egg-session会自动将session内容和配置选项(maxAge,expire等)存入redis中,期间会判断session是否配置了genid函数,如果没有配置,会生成一个随机的extenalKey作为session的key。接下来会将EGG_SESS作为key,externalKey作为value,存入cookie中,响应到前端。 app.sessionStore 只是对redis存取,销毁做的封装,跟sessionId没有关系。 总结: 如果session没有配置store选项,cookie中存的是session加密后的内容。如果session配置了store,cookie中存的是redis中的key(即sessionId)。

@zheng199512 我在issue 2010做了回答,请参照https://github.com/eggjs/egg/issues/2010

> I have the same problem Now, I get all characters of every layer. But the Performance is too low.

My device pixel ratio is 1.5 . Can the deck.gl not recognize device pixel ratio by itself ?

> > Can the deck.gl not recognize device pixel ratio by itself > > deck.gl uses `window.devicePixelRatio` by default. You can try manually increasing it and see if it reduces...