GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — 如何解决在同一个方法中,同时操作修改、新增、删除三种操作的同时,使所有操作在同一个事务中,以此来保证`一个失败,全部回滚` · Issue #449 · APIJSON/APIJSON

如何解决在同一个方法中,同时操作修改、新增、删除三种操作的同时,使所有操作在同一个事务中,以此来保证一个失败,全部回滚 #449

New issue
Copy link
New issue
Copy link
Open
Open
如何解决在同一个方法中,同时操作修改、新增、删除三种操作的同时,使所有操作在同一个事务中,以此来保证一个失败,全部回滚#449
Copy link
Labels
Enhancement 增强增强功能、提高性能等增强功能、提高性能等Question 使用问题使用问题使用问题Transaction 事务

Description

@AwenJackson
AwenJackson
opened on Oct 9, 2022
Issue body actions

下面是主要代码,请问各位大佬该怎么解决?我并不知道我哪里出错了,就是无法实现在一个事务中保证一个失败,全部回滚

Activity

  1. TommyLemon commented on Oct 18, 2022

    @TommyLemon
    TommyLemon
    on Oct 18, 2022
    Member
    More actions

    需要复用 SQLExecutor,参考
    https://blog.csdn.net/aa330233789/article/details/105309571

    或者类似 /login, /register 接口自己通过补偿来还原失败情况导致的更改。

    当然一般不建议用 APIJSON 手写代码,APIJSON 主要用来提供零代码的万能通用 API,复杂业务建议通过现有的其它方式实现。

  2. TommyLemon
    added
    Enhancement 增强增强功能、提高性能等增强功能、提高性能等
    Question 使用问题使用问题使用问题
    Transaction 事务
    on Oct 18, 2022
  3. TommyLemon commented on Feb 17, 2023

    @TommyLemon
    TommyLemon
    on Feb 17, 2023
    Member
    More actions

    @AwenJackson 6.0.0 新增支持全能接口 /crud,一个请求 JSON 同时使用多种 CRUD 操作,并支持跨源事务,感谢 @cloudAndMonkey 的贡献 #481 #485;

    https://github.com/Tencent/APIJSON/releases/tag/6.0.0

    对应文档
    https://github.com/Tencent/APIJSON/blob/master/README-extend.md

  4. AwenJackson commented on Feb 17, 2023

    @AwenJackson
    AwenJackson
    on Feb 17, 2023 via email
    ContributorAuthor
    More actions
    谢谢!感谢提醒! 倾尽年华终是梦 ***@***.***  
    …
    ------------------ 原始邮件 ------------------ 发件人: "Tencent/APIJSON" ***@***.***>; 发送时间: 2023年2月17日(星期五) 下午4:02 ***@***.***>; ***@***.******@***.***>; 主题: Re: [Tencent/APIJSON] 如何解决在同一个方法中,同时操作修改、新增、删除三种操作的同时,使所有操作在同一个事务中,以此来保证`一个失败,全部回滚` (Issue #449) @AwenJackson 6.0.0 新增支持全能接口 /crud,一个请求 JSON 同时使用多种 CRUD 操作,并支持跨源事务,感谢 @cloudAndMonkey 的贡献 #481 #485; https://github.com/Tencent/APIJSON/releases/tag/6.0.0 对应文档 https://github.com/Tencent/APIJSON/blob/master/README-extend.md — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: ***@***.***>
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

    Enhancement 增强增强功能、提高性能等增强功能、提高性能等Question 使用问题使用问题使用问题Transaction 事务

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.