+ logger.error(EELFLoggerDelegate.errorLogger,
+ " Error retrieving Application to capture app name for analytics; Proceeding with empty app name");
+ }
+ if (app != null) {
+ String restEndPoint = app.getAppRestEndpoint();
+ if(restEndPoint.indexOf("/api")!=-1) {
+ version = restEndPoint.substring(restEndPoint.indexOf("api"));
+ }
+ }
+ String endPoint = "/storeAnalytics";
+ if(StringUtils.isNotBlank(version)) {
+ endPoint = version + "/storeAnalytics";
+ }
+
+ final String fileName = "analytics.txt";
+ try (InputStream analyticsFileStream = this.getClass().getClassLoader().getResourceAsStream(fileName)) {
+ responseText = IOUtils.toString(Objects.requireNonNull(analyticsFileStream), StandardCharsets.UTF_8.name());
+ } catch (IOException e) {