And Todays’s Quote Would Be..

Life begins at the end of your comfort zone.

Neale Donald Walsch

How to Extract SRT (Subtitle File) From MKV Movie File on Windows

Ive just download a very good, and a highly recommended anime, Digimon Adventure Tri. It can play well on my laptop, but when i put it on my TV, somehow the subtitle is gone. I notice that it happen because the srt got burn inside the video file.

After browsing for a while, i found out that i can extract my srt using MKVToolNix tools. I downloaded it, and using one of its tools, mkvextract.exe, i can extract the subtitles i wanted from my mkv files.

But first, make sure you use mkvinfo.exe to check your mkv information.

C:\Program Files\MKVToolNix>mkvinfo.exe 
        "C:\Users\edw\Downloads\[HorribleSubs] Digimon Adventure tri - 01 [1080p].mkv"

And find track id for subtitles.

| + A track
|  + Track number: 3 (track ID for mkvmerge & mkvextract: 2)
|  + Track UID: 3
|  + Track type: subtitles
|  + Lacing flag: 0
|  + Codec ID: S_TEXT/ASS
|  + CodecPrivate, length 1934

In this scenario, my subtitle track id is 2 and subtitle format is .ass

Okay, whit that information, i can start to extracting my subtitle file.

C:\MKVToolNix>mkvextract tracks 
        "C:\Users\edw\Downloads\[HorribleSubs] Digimon Adventure tri - 01 [1080p].mkv" 

It will extract subtitle from “Digimon Adventure tri – 04 [1080p].mkv” and put the subtitle on E:\ with named mysubtitle.ass. You can convert .ass file into .srt file easily using online converter tools.


[Java] How to Create a HTTP Get Request

Basically i use this class to mimic a json request to a different domain, to prevent CORS error. So this is my code, oh and i use Spring Framework, which explain the Service annotation .

import org.springframework.stereotype.Service;

public class JsonService {

    public String get() {
        try {
            return getHTML("myurl");
        } catch (Exception e) {
            return "";
   private String getHTML(String urlToRead) throws Exception {
      StringBuilder result = new StringBuilder();
      URL url = new URL(urlToRead);
      HttpURLConnection conn = (HttpURLConnection) url.openConnection();
      BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
      String line;
      while ((line = rd.readLine()) != null) {
      return result.toString();

Hope it can help others, cheers (B)


Daftar Kode Provinsi, Kecamatan, Kabupaten dan Desa di Indonesia Menurut Kemendagri

Setelah berkeliaran kesana-kesini, apalagi data kemendagri berupa pdf sehingga menyulitkan diparsing :-P , akhirnya dapet juga versi sql dari data Kemendagri. Setelah diparsing sehingga mysql-compatible, hasil akhir sql filenya bisa diunduh di —> sini

Data Kemendagri


How to Handle Error on Mule, “Flow exception listener contains and exception strategy that doesn’t handle all request”

Today i had a very weird error on Mule ESB, that somehow never happened to my other colleague. This is the complete stacktrace,

+ Failed to deploy artifact 'edw-soa', see below              +
org.mule.module.launcher.DeploymentInitException: FlowConstructInvalidException: Flow exception listener 
contains and exception strategy that doesn't handle all request, Perhaps there's an exception strategy 
with a when attribute set but it's not part of a catch exception strategy
	at org.mule.module.launcher.application.DefaultMuleApplication.init( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.artifact.ArtifactWrapper$2.execute( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.artifact.ArtifactWrapper.executeWithinArtifactClassLoader( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.artifact.ArtifactWrapper.init( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DefaultArtifactDeployer.deploy( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DefaultArchiveDeployer.guardedDeploy( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DefaultArchiveDeployer.deployArtifact( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DefaultArchiveDeployer.deployPackagedArtifact( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DefaultArchiveDeployer.deployPackagedArtifact( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DefaultArchiveDeployer.deployPackagedArtifact( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DeploymentDirectoryWatcher.deployPackedApps( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.DeploymentDirectoryWatcher.start( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.MuleDeploymentService.start( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.module.launcher.MuleContainer.start( ~[mule-module-launcher-3.6.1.jar:3.6.1]
	at org.mule.tooling.server.application.ApplicationDeployer.main( ~[tooling-support-3.6.1.jar:?]

Basically, it happen because of MuleESB backward incompatibility. And after adding these line, the error seems to go away (forever hopefully :D )

<catch-exception-strategy doc:name="Catch Exception Strategy">
	<logger level="ERROR" message="[Exception thrown]" />
		value="#[com.edw.soa.process.Utils.responseProcess(originalPayload,'Transaksi gagal','1')]" />

Thank you to Muhammad Reza Nurhakim and Adhi Wicaksono for solving this.


Error No Buffer Space Available when Using Java, MyBatis and MySql

I’ve met a very weird error, that are not supposed to happen, when using MyBatis and MySql. Somehow my Windows OS is running out of ports, this is the complete stacktrace.

Caused by: No buffer space available (maximum connections reached?): connect
    at Method)
    at Source)
    at Source)
    at Source)
    at Source)
    at Source)
    at Source)
    at<init>(Unknown Source)
    at<init>(Unknown Source)
    at com.mysql.jdbc.StandardSocketFactory.connect(
    at com.mysql.jdbc.MysqlIO.<init>(]

I found out it happened because im using traditional unpooled connection, changing it into pooled connection in MyBatis solved it.

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE configuration
PUBLIC "-// Config 3.0//EN"
    <environments default="development">
        <environment id="development">
            <transactionManager type="JDBC"/>
            <dataSource type="POOLED">
                <property name="driver" value="com.mysql.jdbc.Driver"/>
                <property name="url" value="jdbc:mysql://localhost/xxxx"/>
                <property name="username" value="xxxx"/>
                <property name="password" value=""/>
                <property name="poolMaximumActiveConnections" value="20"/>