Skip to content

Instantly share code, notes, and snippets.

View rodrix's full-sized avatar
⚛️
Rose are red, violet are blue. I like to write code and a lot of bugs too.

rodrix

⚛️
Rose are red, violet are blue. I like to write code and a lot of bugs too.
View GitHub Profile
@aoudiamoncef
aoudiamoncef / LoggingAspect.java
Last active February 5, 2024 08:53
Spring Boot with Spring AOP Logging (Use for debugging only)
package com.maoudia.app;
import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.AfterReturning;
import org.aspectj.lang.annotation.AfterThrowing;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
@sistematico
sistematico / feriados.json
Last active January 28, 2024 00:16
Json com os feriados nacionais
{
"2001-01-01": "Confraternização Universal",
"2001-02-27": "Carnaval",
"2001-04-13": "Paixão de Cristo",
"2001-04-21": "Tiradentes",
"2001-05-01": "Dia do Trabalho",
"2001-06-14": "Corpus Christi",
"2001-09-07": "Independência do Brasil",
"2001-10-12": "Nossa Sr.a Aparecida - Padroeira do Brasil",
"2001-11-02": "Finados",
@svanoort
svanoort / gist:532a6918389b3a0e9dd4
Created March 18, 2016 13:11
Tuning Java for minimal memory footprint
One source: http://developers.redhat.com/blog/2014/07/22/dude-wheres-my-paas-memory-tuning-javas-footprint-in-openshift-part-2/
# Set the XMX to cap your max heap, set the xms to a reasonable minimum
-Xmx384m -Xms100m
# No more than 40% of heap free, lowest GC overhead and keeps heap small - still under 0.5% GC time
seropt:
-XX:+UseSerialGC -XX:MinHeapFreeRatio=20 -XX:MaxHeapFreeRatio=40
# parallel version, allows up to 4% time spent on GC, generally uses heap more efficiently, but at cost of 2x the CPU USE

Why I hate TypeScript

Warning: These views are highly oppinated and might have some slightly incorrect facts. My experience with typescript was about 2 weeks in Node and a week in angular2.

Not Standard

TypeScript is implementing their own take on JavaScript. Some of the things they are writing will likely never make it in an official ES* spec either.

Technologies that have competing spec / community driven development have a history of failing; take: Flash, SilverLight, CoffeeScript, the list goes on. If you have a large code base, picking TypeScript is something your going to be living with for a long time. I can take a bet in 3 years JavaScript will still be around without a doubt.

Its also worth noting that they have built some things like module system and as soon as the spec came out they ditched it and started using that. Have fun updating!