appwrite / appwrite/functions-starter

🐛 Bug Report: Java Function - Host Is Unreachable

Open
#41 2 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Java
Stars
32
Forks
13
PR merge metrics
No merged PRs in 30d

Description

### 👟 Reproduction steps

Java Function:

```
var client = new Client();
client
.setEndpoint("http://192.168.1.3/v1")
.setProject("java0001")
.setKey("...");
var databases = new Databases(client);
```

Gradle:
```
dependencies {
implementation 'io.appwrite:sdk-for-kotlin:1.1.0'
implementation 'com.google.code.gson:gson:2.9.1'
implementation 'com.fasterxml.jackson.dataformat:jackson-dataformat-csv:2.13.4'
implementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.12.0'
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.24'
annotationProcessor 'org.projectlombok:lombok:1.18.24'
}
tasks.withType(Jar) { duplicatesStrategy = DuplicatesStrategy.INCLUDE }
```
**NOTE:** please document last line setting of this Gradle; otherwise it won't compile probably because of known Kotlin bug.

### 👍 Expected behavior

Can connect to database

### 👎 Actual Behavior

Different types of logs; I tried both, `localhost` and IP address:

```
An internal curl error has occurred within the executor! Error Msg: Host is unreachable
```
```
An internal curl error has occurred within the executor! Error Msg: Operation timed out
```
```
An internal curl error has occurred within the executor! Error Msg: Could not resolve host: java0001-6345a364024ea2ad902e
```

Last one is very strange because I use custom ID `java0001`.

### 🎲 Appwrite version

Version 1.0.x

### 💻 Operating system

MacOS

### 🧱 Your Environment

_No response_

### 👀 Have you spent some time to check if this issue has been raised before?

- [X] I checked and didn't find similar issue

### 🏢 Have you read the Code of Conduct?

- [X] I have read the [Code of Conduct](https://github.com/appwrite/appwrite/blob/HEAD/CODE_OF_CONDUCT.md)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.