Search in sources :

Example 26 with Seckill

use of com.goodskill.entity.Seckill in project goodsKill by techa03.

the class BaseServiceConfigForTest method testUpdate.

public void testUpdate() throws InterruptedException {
    signal.set(true);
    redisTemplate.delete(1000);
    Seckill entity = new Seckill();
    entity.setSeckillId(1000L);
    entity.setNumber(1220);
    seckillMapper.updateById(entity);
    signal.set(false);
    condition.signalAll();
}
Also used : Seckill(com.goodskill.entity.Seckill)

Aggregations

Seckill (com.goodskill.entity.Seckill)26 Test (org.junit.jupiter.api.Test)10 Date (java.util.Date)5 Goods (com.goodskill.entity.Goods)4 SeckillMockRequestDTO (com.goodskill.api.dto.SeckillMockRequestDTO)3 ValueOperations (org.springframework.data.redis.core.ValueOperations)3 Page (com.baomidou.mybatisplus.extension.plugins.pagination.Page)2 SeckillCloseException (com.goodskill.common.exception.SeckillCloseException)2 SuccessKilled (com.goodskill.entity.SuccessKilled)2 AlipayTradePrecreateResponse (com.alipay.easysdk.payment.facetoface.models.AlipayTradePrecreateResponse)1 QueryWrapper (com.baomidou.mybatisplus.core.conditions.query.QueryWrapper)1 UpdateWrapper (com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper)1 RepeatKillException (com.goodskill.common.exception.RepeatKillException)1 SeckillException (com.goodskill.common.exception.SeckillException)1 GlobalTransactional (io.seata.spring.annotation.GlobalTransactional)1 ApiOperation (io.swagger.annotations.ApiOperation)1 IOException (java.io.IOException)1 InetAddress (java.net.InetAddress)1 UnknownHostException (java.net.UnknownHostException)1 CountDownLatch (java.util.concurrent.CountDownLatch)1