The story of catch ghost for Cloud Service use REST DataSnap

Chinese language version in here.

Generally, develop REST DataSnap project is easy and right for Delphier.


When I performanced.

I have exception in REST DataSnap service demo incredibly...
and in local area network(with VPN), I cannot believe it!

I don't have the foggiest idea what REST DataSnap service connection failed, and it's very hurry as the deadline approached!
Fortunately, I was develop DataSnap framework, it flexible!
So, fine tuning, only fine tuning, the service is fine!

Though, the substitute solution performance is slow and not good.
We must understand where the problam.

===I flying to trouble site from office to factory...(It's overkill!)===

User1: I can to access internet, but your app can not connection. 
Me: Impossible! Maybe you have install some banned application!User2: Maybe? Maybe your app is super bug in my PC.
Me: Call MIS ......re-format! re-install!

---30 minutes passed---

Me: Look! It's fine!

User1: So?

Me: You should not question Delphier profession, because Delphier was the only one who can solve the problem!

But, connect error occurs when I left. (Murphy's Law?)

User2: Stop! Your app connect error occurs in my PC!
User1: Now, It can not work too. 
MIS: My work is only re-format, I don't know why.
Me: ............................

User can connect to internet.
But, I didn't to connect my service...

Now debuging... Source

After waiting for so long...I got it!

And the answer is not "Firewall".

The answer is

Proxy! The answer is Proxy!
The arch criminal is Proxy!

Oh, dear. That's dreadful. In the year Halloween. :-P



How to use URLEncode in Delphi

URL編碼,也稱【百分號編碼(Percent-encoding)】 由於 URL 不能直接接受 UTF8 文字,所以要先轉成百分號編碼後,如此網址才能順利送給 HTTP Server 從 Indy 加入 Delphi 後,就可以用 IdURI.TIdURI 單元進行編碼 ...