Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Gelin Luo greenlaw110

🏠
Working from home
View GitHub Profile
@greenlaw110
greenlaw110 / issue-install-wine-on-mint-19.2
Created Oct 29, 2019
Issue installing wine on mint 19.2
View issue-install-wine-on-mint-19.2
root@luog-X510UQR:~# sudo apt install --install-recommends winehq-stable
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
View TestTfb.java
public static void main(String[] args) throws Exception {
long ts = $.ms();
final OkHttpClient http = new OkHttpClient.Builder().build();
final AtomicInteger backlog = new AtomicInteger(100000);
final AtomicInteger exceptions = new AtomicInteger(0);
ExecutorService exec = Executors.newFixedThreadPool(100);
for (int i = 0; i < 150; ++i) {
exec.submit(new Runnable() {
@Override
public void run() {
@greenlaw110
greenlaw110 / DisableClientCacheInterceptor.java
Created Oct 22, 2019
Intercepter to disable client cache for all endpoints - ActFramework
View DisableClientCacheInterceptor.java
import act.util.Global;
import org.joda.time.DateTimeZone;
import org.joda.time.LocalDateTime;
import org.joda.time.format.DateTimeFormat;
import org.joda.time.format.DateTimeFormatter;
import org.osgl.$;
import org.osgl.aaa.NoAuthentication;
import org.osgl.http.H;
import org.osgl.mvc.annotation.After;
import org.osgl.util.S;
View beetlsql.stack
ANTLR Tool version 4.7.2 used for code generation does not match the current runtime version 4.5.3ANTLR Runtime version 4.7.2 us23:06:50.978 [XNIO-1 task-4] ERROR a.x.NetworkHandler - Fatal Error encountered handling request:
java.lang.ExceptionInInitializerError: null
at org.beetl.core.engine.DefaultTemplateEngine.createProgram(DefaultTemplateEngine.java:36)
at org.beetl.sql.core.engine.SQLTemplateEngine.createProgram(SQLTemplateEngine.java:17)
at org.beetl.core.GroupTemplate.loadTemplate(GroupTemplate.java:573)
at org.beetl.core.GroupTemplate.getTemplateByLoader(GroupTemplate.java:526)
at org.beetl.core.GroupTemplate.getTemplate(GroupTemplate.java:503)
at org.beetl.sql.core.SQLScript.run(SQLScript.java:76)
at org.beetl.sql.core.SQLScript.run(SQLScript.java:66)
at org.beetl.sql.core.SQLScript.select(SQLScript.java:326)
View FastJsonIssue.java
public class FastJsonIssue {
public static class Record {
@JSONField(format = "yyyy-MMM-dd")
public Date date1 = new Date();
@JSONField(format = "yyyyMMdd")
public Date date2 = date1;
@JSONField(format = "yyyy_MM_dd hh:mm")
public DateTime dateTime = DateTime.now();
@greenlaw110
greenlaw110 / routes.conf
Created Jan 4, 2018
A complex route table for routing benchmark
View routes.conf
# Routes
# This file defines all application routes (Higher priority routes first)
# ~~~~
#Runtime
GET /yemian/{yemianId}/ CMYingyong.jiazaiYemian
* /tuiguang/{tuiguangId}/ CMYingyong.jiazaiTuiguang
GET /jilu/{jiluId} CMYingyong.jilu
GET /toupiao CMYingyong.toupiao
GET /tandcdialog CMYingyong.tAndCDialog
@greenlaw110
greenlaw110 / create-act-app.sh
Created Jan 3, 2018
Simple way to create actframework app project skeleton
View create-act-app.sh
wget https://github.com/actframework/act-starter-kit/archive/master.zip && unzip master.zip && ./act-starter-kit-master/act-new.sh
@greenlaw110
greenlaw110 / javadoc.css
Last active Sep 17, 2017
my javadoc stylesheet
View javadoc.css
body {
background-color:#222222;
color:#D2DECA;
font-family: serif;
font-size:16px;
margin:0;
}
a:link, a:visited {
text-decoration:none;
color:#999;
View xyz.md
head1 head 2
3 5
  • list 1
  • list 2
Hello Markdown

...

@greenlaw110
greenlaw110 / act-release-notes-20170911.md
Last active Sep 10, 2017
ACT Release Notes - 1.4.11
View act-release-notes-20170911.md

ActFramework Release notes for 1.4.11

Change log

  • catch up update to 1.3.14-LTS
  • Support running CLI Job in background #267
  • job.list CLI command failure #355

The followings are catch up from 1.3.14-LTS

You can’t perform that action at this time.