Closed mingfang closed 3 years ago
https://github.com/kiegroup/kogito-apps/blob/07160792a3f5bb9c36ccf0b66c6de745d5c410ee/data-index/data-index-service/data-index-service-common/src/main/java/org/kie/kogito/index/graphql/GraphQLSchemaManager.java#L174
should use lastIndexOf(), e.g.
lastIndexOf()
return endpoint.contains("/" + context) ? endpoint.substring(0, endpoint.lastIndexOf("/" + context)) : null;
To see the problem using Kogito-travel-agency example, in travels app set kogito.service.url=http://travels.example.com. Then start a new process instance. When you query data-index service you will see the serviceUrl field as http:/ which is wrong.
Kogito-travel-agency
travels
kogito.service.url=http://travels.example.com
data-index
serviceUrl
http:/
@mingfang thanks for reporting it.
https://github.com/kiegroup/kogito-apps/blob/07160792a3f5bb9c36ccf0b66c6de745d5c410ee/data-index/data-index-service/data-index-service-common/src/main/java/org/kie/kogito/index/graphql/GraphQLSchemaManager.java#L174
should use
lastIndexOf()
, e.g.To see the problem using
Kogito-travel-agency
example, intravels
app setkogito.service.url=http://travels.example.com
. Then start a new process instance. When you querydata-index
service you will see theserviceUrl
field ashttp:/
which is wrong.