Visitar URL original
【小程序】建议提供获取access_token成功后相关回调 · Issue #3000 · binarywang/WxJava · GitHub
Skip to content

【小程序】建议提供获取access_token成功后相关回调 #3000

Closed

Description

@FreeOfYou

每次更新小程序access_token时,想把access_token持久化到数据库,每当项目启动的时候,先查看数据库是否过期,如果没过期,则进行redis的access_token初始化。这样能做到access_token高可用

Activity

  1. FreeOfYou commented on Apr 30, 2023

    @FreeOfYou
    Author

    目前我的解决方案是重写了 cn.axzo.diplomat.server.infrastructure.wx.WxMaCustomerRedisBetterConfigImpl#updateAccessToken 方法,提供了一个更新access_token前的回调函数

  2. binarywang commented on May 4, 2023

    @binarywang
    Owner

    欢迎提供PR代码,另外你这个包名也不是本SDK提供的啊

  3. FreeOfYou commented on May 5, 2023

    @FreeOfYou
    Author

    目前我的解决方案是重写了 cn.axzo.diplomat.server.infrastructure.wx.WxMaCustomerRedisBetterConfigImpl#updateAccessToken 方法,提供了一个更新access_token前的回调函数

    这个,上面写错了
    cn.binarywang.wx.miniapp.config.impl.WxMaRedisBetterConfigImpl#updateAccessToken

  4. binarywang commented on May 5, 2023

    @binarywang
    Owner

    写错了,无所谓,你可以把你重写的方法代码贡献出来,提交PR即可

  5. added a commit that references this issue on May 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions