node.js - @google-cloud/redis 获取和设置未找到
问题描述
我在 Google Cloud Platform 上创建了 Redis。我的应用程序正在连接。但是,我不能在我创建的客户端中设置、获取、打开。问题是什么?因为它不在里面。那我要怎么管理?
const connectRedis = async () => {
const { CloudRedisClient } = require('@google-cloud/redis')
const thisClient = new CloudRedisClient()
const formattedParent = thisClient.locationPath('project', 'location')
const thisRequest = {
parent: formattedParent
}
const thisResponse = (await thisClient.listInstances(thisRequest))[0]
}
thisClient.on || thisClient.on 未找到。
解决方案
推荐阅读
- php - CodeIgniter:提交表单后出现错误 403
- visual-studio-code - 你如何解开编辑器,从 2 个代码视图返回到 1 个,与终端相同
- c++ - Cocos2d-x TiledMap,调用getLayer()获取碰撞层时返回nullptr?
- python - Python boto3 按大小对 s3 对象进行排序
- node.js - 带卡 ID 的条带创建令牌
- java - Collectors.summingInt 中的减法
- php - 获取 Laravel 特定字段中的重复项数
- python - SQLalchemy:当 post_update=True 时,预删除更新未运行
- angular - 标头未赋值
- android - com.crashlytics.android.Crashlytics 不能存储在 io.fabric.sdk.android.Kit[] 类型的数组中