Skip to content

Instantly share code, notes, and snippets.

View ilaotan's full-sized avatar
😁
talk is cheap,show me the code

不想当厨子的老谭 ilaotan

😁
talk is cheap,show me the code
  • 山东青岛
  • 08:59 (UTC +08:00)
View GitHub Profile
import com.chen.utils.LoggerUtil;
import com.google.common.util.concurrent.RateLimiter;
import org.springframework.web.servlet.HandlerInterceptor;
import org.springframework.web.servlet.ModelAndView;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
public class SimpleRateLimitInterceptor implements HandlerInterceptor {
@ilaotan
ilaotan / SpringMVCWebConfig.java
Created November 26, 2016 08:16 — forked from AWolf81/SpringMVCWebConfig.java
Spring boot configuration file (annotation-based) - configures localization
package mongodbdemo.config;
import java.util.Locale;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.support.ReloadableResourceBundleMessageSource;
以下配置在springboot-1.4.1下测试通过
import com.alibaba.druid.pool.DruidDataSource;
import com.alibaba.druid.support.http.StatViewServlet;
import com.alibaba.druid.support.http.WebStatFilter;
import com.github.pagehelper.PageHelper;
import org.apache.commons.lang3.StringUtils;
import org.apache.ibatis.plugin.Interceptor;
import org.apache.ibatis.session.SqlSessionFactory;
/* JavaScript password hash generator.
* $Id: pwd.js,v 1.5 2004/10/09 09:41:38 emikulic Exp $
*
* Copyright (c) 2004, Emil Mikulic.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
package testGetMapper;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
/**
* A Java Implementation of the MD5Crypt function
* Modified from the GANYMEDE network directory management system
* released under the GNU General Public License
* by the University of Texas at Austin