alibaba / alibaba/jetcache

@CacheRefresh 延时间隔任务为什么不使用scheduleAtFixedRate,这个感觉更明确些。

Open
#460 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
5.6k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

Hi 我觉得@CacheRefresh这个功能很厉害,所以阅读了源码。延时间隔任务使用scheduleWithFixedDelay但是这个会根据任务本身时间进行推移,使用时若任务过长会对设置的间隔时间产生疑问。所以为什么不考虑使用scheduleAtFixedRate 不受任务执行时间的影响,更明确些。

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the @CacheRefresh implementation and the scheduling entry point that uses scheduleWithFixedDelay. Compare the intended interval semantics with scheduleAtFixedRate, then establish the expected behavior for long-running tasks and verify it with focused tests before changing the scheduler.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.