Pecandu Internet Profesional • Penggemar Game • Kreator Teknologi
Pecandu Internet Profesional • Penggemar Game • Kreator Teknologi

Cara terhubung ke situs Google App Engine lokal dari Android Anda

Cara menghubungkan ke situs Google App Engine Anda dari emulator Android di localhost, tanpa mendapatkan ConnectException!
Halaman ini telah diterjemahkan dari bahasa Inggris oleh para intern AI saya yang sangat termotivasi demi kenyamanan Anda. Mereka masih belajar, jadi mungkin ada beberapa kesalahan yang terlewat. Untuk informasi yang lebih akurat, silakan lihat versi bahasa Inggris.
Rumah Blog Cara terhubung ke situs Google App Engine lokal dari Android Anda

Harap dicatat bahwa postingan blog ini diterbitkan pada Juni 2011, jadi tergantung kapan Anda membacanya, beberapa bagian mungkin sudah kedaluwarsa. Sayangnya, saya tidak selalu dapat memperbarui postingan ini sepenuhnya untuk memastikan keakuratan informasinya.

    If you are trying, from your Android application through the Android emulator, to access an external service on the same computer (such as your own Google App Engine site) by using the host name localhost or the IP-address 127.0.0.1, you might get a java.net.ConnectException java.net.ConnectException: localhost/127.0.0.1:8888 - Connection refused error - even though you can perfectly well access the service outside the Android application.
    The reason why a ConnectException occurs is because "localhost" or "127.0.0.1" inside the Android emulator is the emulator's own loopback interface, meaning all request sent to the destination will be looped backed to the emulator and won't actually be sent to your local machine.
    To by pass this, simply replace "localhost" with the IP-address "10.0.2.2", as this is a special address towards the real local host.
    Done!

    Ditulis oleh Special Agent Squeaky. Pertama kali diterbitkan 03-06-2011. Terakhir diperbarui 03-06-2011.

    📺 Tonton video terbarunya dari Squeaky!

    Cara Menambahkan Subtitel Waktu Nyata yang Sederhana untuk Siaran Langsung Anda