Skip to content

Fix #769 A new option to auto-acknowledge Events API requests#820

Merged
seratch merged 5 commits into
slackapi:mainfrom
seratch:issue-769-auto-ack
Aug 25, 2021
Merged

Fix #769 A new option to auto-acknowledge Events API requests#820
seratch merged 5 commits into
slackapi:mainfrom
seratch:issue-769-auto-ack

Conversation

@seratch
Copy link
Copy Markdown
Contributor

@seratch seratch commented Aug 20, 2021

This pull request resolves #769 by adding the following new two options.

  • AppConfig#allEventsApiAutoAckEnabled: Boolean: If true, Bolt enables auto-acknowledging for all Events API requests even when corresponding listeners are missing.
  • AppConfig#subtypedMessageEventsAutoAckEnabled: Boolean: If true, Bolt enables auto-acknowledging for message + subtype Events API requests even when corresponding listeners are missing.
AppConfig config = new AppConfig();
// config.setAllEventsApiAutoAckEnabled(true);
// config.setSubtypedMessageEventsAutoAckEnabled(true);
App app = new App(config);
app.start();

As the test code shows, registered listeners are used even if these options are true.

Category (place an x in each of the [ ])

  • bolt (Bolt for Java)
  • bolt-{sub modules} (Bolt for Java - optional modules)
  • slack-api-client (Slack API Clients)
  • slack-api-model (Slack API Data Models)
  • slack-api-*-kotlin-extension (Kotlin Extensions for Slack API Clients)
  • slack-app-backend (The primitive layer of Bolt for Java)

Requirements

Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to the those rules.

@seratch seratch added enhancement M-T: A feature request for new functionality project:bolt labels Aug 20, 2021
@seratch seratch added this to the 1.11.0 milestone Aug 20, 2021
@codecov
Copy link
Copy Markdown

codecov Bot commented Aug 20, 2021

Codecov Report

Merging #820 (4e01861) into main (99b8a7f) will decrease coverage by 0.02%.
The diff coverage is 92.30%.

❗ Current head 4e01861 differs from pull request most recent head 8cda4d0. Consider uploading reports for the commit 8cda4d0 to get more accurate results
Impacted file tree graph

@@             Coverage Diff              @@
##               main     #820      +/-   ##
============================================
- Coverage     77.23%   77.20%   -0.03%     
- Complexity     3439     3441       +2     
============================================
  Files           384      384              
  Lines         10322    10332      +10     
  Branches       1004     1008       +4     
============================================
+ Hits           7972     7977       +5     
- Misses         1764     1766       +2     
- Partials        586      589       +3     
Impacted Files Coverage Δ
...lt/src/main/java/com/slack/api/bolt/AppConfig.java 72.34% <ø> (ø)
bolt/src/main/java/com/slack/api/bolt/App.java 68.21% <90.00%> (+0.39%) ⬆️
...va/com/slack/api/bolt/meta/BoltLibraryVersion.java 100.00% <100.00%> (ø)
...m/slack/api/meta/SlackApiClientLibraryVersion.java 100.00% <100.00%> (ø)
...om/slack/api/meta/SlackApiModelLibraryVersion.java 100.00% <100.00%> (ø)
...va/com/slack/api/socket_mode/SocketModeClient.java 67.76% <0.00%> (-1.98%) ⬇️
...imits/metrics/impl/BaseMemoryMetricsDatastore.java 88.66% <0.00%> (-0.67%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 99b8a7f...8cda4d0. Read the comment docs.

@seratch seratch requested review from misscoded and srajiang August 20, 2021 02:00
@seratch
Copy link
Copy Markdown
Contributor Author

seratch commented Aug 20, 2021

We just released v1.11.0-RC1, which includes this pull request changes. Anyone can try the functionality with the version. https://search.maven.org/artifact/com.slack.api/bolt/1.11.0-RC1/jar

@seratch seratch requested review from filmaj and mwbrooks August 25, 2021 01:53
@seratch
Copy link
Copy Markdown
Contributor Author

seratch commented Aug 25, 2021

To: reviewers, let me know if you have any comments like naming suggestions 👋 I'm thinking to release the next version by the end of this week.

Copy link
Copy Markdown
Contributor

@filmaj filmaj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! :shipit:

Comment thread bolt/src/main/java/com/slack/api/bolt/AppConfig.java Outdated
Co-authored-by: Fil Maj <maj.fil@gmail.com>
@seratch seratch merged commit ed6f13a into slackapi:main Aug 25, 2021
@seratch seratch deleted the issue-769-auto-ack branch August 25, 2021 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement M-T: A feature request for new functionality project:bolt

Projects

None yet

Development

Successfully merging this pull request may close these issues.

A new option to auto-acknowledge subtyped message events

2 participants