Grafana image renderer plugin not working - rendering

i have grafana 7.0.5 with image rendrer plugin v2.0
in grafana.ini
root_url = http://myServer.com/grafana
and grafana is running behind an apache with :
ProxyPass /grafana http://127.0.0.1:3000
ProxyPassReverse /grafana http://127.0.01:3000
When i try to render an image of a panle with : [Direct link rendered image], browser wait for about 1 mn and then i have :
in the log file : i have
t=2020-07-08T15:12:46+0200 lvl=info msg=Rendering logger=rendering renderer=plugin path="d-solo/mT2tktqZk/fiche-departementale?orgId=1&from=1594192067086&to=1594213667086&var-liste_dep=All&var-date2_deb=&var-date2_fin=&var-type_et=ETF&var-type_et=ETD&var-type_et=ETVM&var-type_et=ETFR&var-type_et=ETM&var-type_et=ETC&var-type_et=ETT&panelId=6&width=1000&height=500&tz=Europe%2FParis"
t=2020-07-08T15:12:46+0200 lvl=info msg="Request Completed" logger=context userId=1 orgId=1 uname= method=GET path=/d-solo/mT2tktqZk/fiche-departementale status=200 remote_addr=[::1] time_ms=2 size=34727 referer=
t=2020-07-08T15:12:47+0200 lvl=info msg="Request Completed" logger=context userId=1 orgId=1 uname= method=GET path=/api/dashboards/uid/mT2tktqZk status=200 remote_addr=[::1] time_ms=2 size=11580 referer="http://localhost:3000/grafana/d-solo/mT2tktqZk/fiche-departementale?orgId=1&from=1594192067086&to=1594213667086&var-liste_dep=All&var-date2_deb=&var-date2_fin=&var-type_et=ETF&var-type_et=ETD&var-type_et=ETVM&var-type_et=ETFR&var-type_et=ETM&var-type_et=ETC&var-type_et=ETT&panelId=6&width=1000&height=500&tz=Europe%2FParis&render=1"
t=2020-07-08T15:12:47+0200 lvl=info msg="Request Completed" logger=context userId=1 orgId=1 uname= method=POST path=/api/tsdb/query status=200 remote_addr=[::1] time_ms=2 size=927 referer="http://localhost:3000/grafana/d-solo/mT2tktqZk/fiche-departementale?orgId=1&from=1594192067086&to=1594213667086&var-liste_dep=All&var-date2_deb=&var-date2_fin=&var-type_et=ETF&var-type_et=ETD&var-type_et=ETVM&var-type_et=ETFR&var-type_et=ETM&var-type_et=ETC&var-type_et=ETT&panelId=6&width=1000&height=500&tz=Europe%2FParis&render=1"
t=2020-07-08T15:12:48+0200 lvl=info msg="Request Completed" logger=context userId=1 orgId=1 uname= method=POST path=/api/tsdb/query status=400 remote_addr=[::1] time_ms=2 size=1798 referer="http://localhost:3000/grafana/d-solo/mT2tktqZk/fiche-departementale?orgId=1&from=1594192067086&to=1594213667086&var-liste_dep=All&var-date2_deb=&var-date2_fin=&var-type_et=ETF&var-type_et=ETD&var-type_et=ETVM&var-type_et=ETFR&var-type_et=ETM&var-type_et=ETC&var-type_et=ETT&panelId=6&width=1000&height=500&tz=Europe%2FParis&render=1"
t=2020-07-08T15:12:48+0200 lvl=eror msg="Browser console error" logger=plugins.backend pluginId=grafana-image-renderer msg="Failed to load resource: the server responded with a status of 400 (Bad Request)" url=http://localhost:3000/grafana/api/tsdb/query
t=2020-07-08T15:13:48+0200 lvl=info msg="Rendering timed out" logger=rendering renderer=plugin
t=2020-07-08T15:13:48+0200 lvl=eror msg="Timeout error. You can set timeout in seconds with &timeout url parameter" logger=context userId=1 orgId=1 uname=admin error="Timeout error. You can set timeout in seconds with &timeout url parameter"
t=2020-07-08T15:13:48+0200 lvl=eror msg="Request Completed" logger=context userId=1 orgId=1 uname=admin method=GET path=/render/d-solo/mT2tktqZk/fiche-departementale status=500 remote_addr="193.41.223.244, 192.168.255.162" time_ms=62022 size=1791 referer="https://sigdca.rct01.kleegroup.com/grafana/d/mT2tktqZk/fiche-departementale?orgId=1"
t=2020-07-08T15:13:49+0200 lvl=eror msg="Render request failed" logger=plugins.backend pluginId=grafana-image-renderer url="http://localhost:3000/grafana/d-solo/mT2tktqZk/fiche-departementale?orgId=1&from=1594192067086&to=1594213667086&var-liste_dep=All&var-date2_deb=&var-date2_fin=&var-type_et=ETF&var-type_et=ETD&var-type_et=ETVM&var-type_et=ETFR&var-type_et=ETM&var-type_et=ETC&var-type_et=ETT&panelId=6&width=1000&height=500&tz=Europe%2FParis&render=1" error="TimeoutError: waiting for function failed: timeout 60000ms exceeded"
Can i get some help with this plz, i’m stuck

Provide the values as follows
GF_RENDERING_SERVER_URL: http://myServer.com/render
GF_RENDERING_CALLBACK_URL: http://myServer.com/grafana

the error came from the dashboard SQL query, so when you try to render a dashboard with an error in its SQL query it fails rendering.

Related

Server returned HTTP response code: 500 (Worklight)

I am getting HTTP response code: 500 in logs for wladmin user..because of this I am unable to deploy runtime for worklight console
[2/7/18 5:33:39:138 EST] 000000ab ServiceProxy E Received status 500 for GET https://localhost:9444/wladmin/management-apis/1.0/loginAudit
java.io.IOException: Server returned HTTP response code: 500 for URL: https://localhost:9444/wladmin/management-apis/1.0/loginAudit
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
Any help?
Error log:
NDIUtils I Resource conf/jndi/default.properties not found. This is not an error. Context path is __globalscope__
[2/7/18 5:33:38:815 EST] 000000ad RuntimeServic E Failed to obtain JMX connection to access an MBean.
There might be a JMX configuration error: null
[2/7/18 5:33:39:138 EST] 000000ab ServiceProxy E Received status 500 for GET https://localhost:9444/wladmin/management-apis/1.0/loginAudit
java.io.IOException: Server returned HTTP response code: 500 for URL: https://localhost:9444/wladmin/management-apis/1.0/loginAudit
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:80)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:57)
at java.lang.reflect.Constructor.newInstance(Constructor.java:539)
at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1686)
at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1684)
at java.security.AccessController.doPrivileged(AccessController.java:280)
at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1682)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1255)
at com.ibm.net.ssl.www2.protocol.https.b.getInputStream(b.java:49)
at com.ibm.worklight.management.ui.servlet.ServiceProxy.service(ServiceProxy.java:172)
at com.ibm.worklight.management.ui.servlet.ConsoleServicesServlet.service(ConsoleServicesServlet.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1227)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:776)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:458)
at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.invokeTarget(WebAppFilterChain.java:136)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:97)
at com.ibm.worklight.admin.common.filter.HSTSFilter.doFilter(HSTSFilter.java:110)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:195)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:91)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:928)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1025)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3761)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:304)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:976)
at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1662)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:200)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:459)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:526)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:312)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:88)
at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:175)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1862)

What could be causing this heroku crash? error code=H10

I've looked over past posts on this question and many suggest heroku restart, or restarting dynos, or making sure to use var PORT = process.env.PORT || 3000. I have done all of these, but my app still crashes. The app runs using node/express sequelize / auth0.
Does any one have any suggestions? Thanks!
Here are the logs:
2017-09-08T02:11:37.293051+00:00 app[web.1]: at emitOne
(events.js:96:13)
2017-09-08T02:11:37.293052+00:00 app[web.1]: at Socket.emit
(events.js:188:7)
2017-09-08T02:11:37.293053+00:00 app[web.1]: at emitErrorNT
(net.js:1277:8)
2017-09-08T02:11:37.293054+00:00 app[web.1]: at
_combinedTickCallback (internal/process/next_tick.js:80:11)
2017-09-08T02:11:37.293055+00:00 app[web.1]: at
process._tickCallback (internal/process/next_tick.js:104:9)
2017-09-08T02:11:37.364314+00:00 heroku[web.1]: State changed from
starting to crashed
2017-09-08T02:11:37.353673+00:00 heroku[web.1]: Process exited with
status 0
2017-09-08T02:11:49.712881+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/" host=roadie2.herokuapp.com
request_id=79e0bc3a-aa28-44bb-ab80-cfcf4f6cd97d fwd="99.92.51.34"
dyno= connect= service= status=503 bytes= protocol=https
2017-09-08T02:11:50.564503+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/favicon.ico"
host=roadie2.herokuapp.com request_id=c72e5077-494c-41f5-8be1-
f0c2c329d080 fwd="99.92.51.34" dyno= connect= service= status=503
bytes= protocol=https
2017-09-08T02:12:24.838901+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/" host=roadie2.herokuapp.com
request_id=ca551858-5372-40c9-abf1-670176b159dc fwd="99.92.51.34"
dyno= connect= service= status=503 bytes= protocol=https
2017-09-08T02:12:25.340624+00:00 heroku[router]: at=error code=H10
desc="App crashed" method=GET path="/favicon.ico"
host=roadie2.herokuapp.com request_id=c37b876d-5a59-40d0-9d59-
9be013c58d94 fwd="99.92.51.34" dyno= connect= service= status=503
bytes= protocol=https
Here is the last part of what results after entering heroku logs --tail
2017-09-08T02:11:27.589912+00:00 heroku[web.1]: State changed from
crashed to starting
2017-09-08T02:11:29.599921+00:00 heroku[web.1]: Starting process with
command `npm start`
2017-09-08T02:11:32.504222+00:00 app[web.1]:
2017-09-08T02:11:32.504242+00:00 app[web.1]: > 15.2#1.0.0 start /app
2017-09-08T02:11:32.504243+00:00 app[web.1]: > node server.js
2017-09-08T02:11:32.504243+00:00 app[web.1]:
2017-09-08T02:11:33.199936+00:00 app[web.1]: Unhandled rejection
SequelizeConnectionRefusedError: connect ECONNREFUSED 127.0.0.1:3306
2017-09-08T02:11:33.199952+00:00 app[web.1]: at
Handshake._callback
(/app/node_modules/sequelize/lib/dialects/mysql/connection-
manager.js:80:20)
2017-09-08T02:11:33.199953+00:00 app[web.1]: at
Protocol.handleNetworkError
(/app/node_modules/mysql/lib/protocol/Protocol.js:364:14)
2017-09-08T02:11:33.199953+00:00 app[web.1]: at
Connection._handleNetworkError
(/app/node_modules/mysql/lib/Connection.js:428:18)
2017-09-08T02:11:33.199954+00:00 app[web.1]: at emitOne
(events.js:96:13)
2017-09-08T02:11:33.199952+00:00 app[web.1]: at
Handshake.Sequence.end
(/app/node_modules/mysql/lib/protocol/sequences/Sequence.js:86:24)
2017-09-08T02:11:33.199954+00:00 app[web.1]: at Socket.emit
(events.js:188:7)
2017-09-08T02:11:33.199955+00:00 app[web.1]: at emitErrorNT
(net.js:1277:8)
2017-09-08T02:11:33.199956+00:00 app[web.1]: at
_combinedTickCallback (internal/process/next_tick.js:80:11)
2017-09-08T02:11:33.199956+00:00 app[web.1]: at
process._tickCallback (internal/process/next_tick.js:104:9)
2017-09-08T02:11:33.302346+00:00 heroku[web.1]: State changed from
starting to crashed
2017-09-08T02:11:33.305267+00:00 heroku[web.1]: State changed from .
crashed to starting
2017-09-08T02:11:33.286200+00:00 heroku[web.1]: Process exited with .
status 0
2017-09-08T02:11:34.845606+00:00 heroku[web.1]: Starting process with
command `npm start`
2017-09-08T02:11:36.543285+00:00 app[web.1]:
2017-09-08T02:11:36.543298+00:00 app[web.1]: > 15.2#1.0.0 start /app
2017-09-08T02:11:36.543299+00:00 app[web.1]: > node server.js
2017-09-08T02:11:36.543299+00:00 app[web.1]:
2017-09-08T02:11:37.293030+00:00 app[web.1]: Unhandled rejection .
SequelizeConnectionRefusedError: connect ECONNREFUSED 127.0.0.1:3306
2017-09-08T02:11:37.293048+00:00 app[web.1]: at
Handshake._callback .
(/app/node_modules/sequelize/lib/dialects/mysql/connection-
manager.js:80:20)
2017-09-08T02:11:37.293049+00:00 app[web.1]: at
Handshake.Sequence.end
(/app/node_modules/mysql/lib/protocol/sequences/Sequence.js:86:24)
2017-09-08T02:11:37.293049+00:00 app[web.1]: at .
Protocol.handleNetworkError
(/app/node_modules/mysql/lib/protocol/Protocol.js:364:14)
2017-09-08T02:11:37.293050+00:00 app[web.1]: at
Connection._handleNetworkError
(/app/node_modules/mysql/lib/Connection.js:428:18)
2017-09-08T02:11:37.293051+00:00 app[web.1]: at emitOne
(events.js:96:13)
2017-09-08T02:11:37.293052+00:00 app[web.1]: at Socket.emit
(events.js:188:7)
2017-09-08T02:11:37.293053+00:00 app[web.1]: at emitErrorNT
(net.js:1277:8)
2017-09-08T02:11:37.293054+00:00 app[web.1]: at
_combinedTickCallback (internal/process/next_tick.js:80:11)
2017-09-08T02:11:37.293055+00:00 app[web.1]: at
process._tickCallback (internal/process/next_tick.js:104:9)
2017-09-08T02:11:37.364314+00:00 heroku[web.1]: State changed from
starting to crashed
2017-09-08T02:11:37.353673+00:00 heroku[web.1]: Process exited with .
status 0
2017-09-08T02:11:49.712881+00:00 heroku[router]: at=error code=H10 .
desc="Appcrashed" method=GET path="/" host=roadie2.herokuapp.com
request_id=79e0bc3a-aa28-44bb-ab80-cfcf4f6cd97d fwd="99.92.51.34"
dyno= connect= service= status=503 bytes= protocol=https
2017-09-08T02:11:50.564503+00:00 heroku[router]: at=error code=H10
desc="Appcrashed" method=GET path="/favicon.ico"
host=roadie2.herokuapp.com request_id=c72e5077-494c-41f5-8be1-
f0c2c329d080 fwd="99.92.51.34" dyno= connect= service= status=503
bytes= protocol=https
2017-09-08T02:12:24.838901+00:00 heroku[router]: at=error code=H10 .
desc="Appcrashed" method=GET path="/" host=roadie2.herokuapp.com
request_id=ca551858-5372-40c9-abf1-670176b159dc fwd="99.92.51.34"
dyno= connect= service= status=503 bytes= protocol=https
2017-09-08T02:12:25.340624+00:00 heroku[router]: at=error code=H10
desc="Appcrashed" method=GET path="/favicon.ico"
host=roadie2.herokuapp.com request_id=c37b876d-5a59-40d0-9d59-
9be013c58d94 fwd="99.92.51.34" dyno= connect= service= status=503
bytes= protocol=https
config.json
{
"development": {
"username": "root",
"password":"",
"database": "roadie2",
"host": "127.0.0.1",
"dialect": "mysql"
},
"test": {
"username": "root",
"password": null,
"database": "database_test",
"host": "127.0.0.1",
"dialect": "mysql"
},
"production": {
"use_env_variable": "JAWSDB_URL",
"dialect": "mysql"
}
}
server.js
var express = require("express");
var bodyParser = require("body-parser");
// Sets up the Express App
// =============================================================
var app = express();
// var PORT = process.env.PORT || 3000;
var port = process.env.PORT
// Requiring our models for syncing
var db = require("./models");
// Sets up the Express app to handle data parsing
app.use(bodyParser.json());
app.use(bodyParser.urlencoded({ extended: true }));
app.use(bodyParser.text());
app.use(bodyParser.json({ type: "application/vnd.api+json" }));
// Static directory
app.use(express.static("./public"));
// Routes =============================================================
require("./routes/html-routes.js")(app);
require("./routes/api-routes.js")(app);
// Syncing our sequelize models and then starting our express app
db.sequelize.sync().then(function() {
app.listen(port, function() {
console.log("App listening on PORT " + port);
});
});
models/index.js
'use strict';
var fs = require('fs');
var path = require('path');
var Sequelize = require('sequelize');
var basename = path.basename(module.filename);
var env = process.env.NODE_ENV || 'development';
var config = require(__dirname + '/../config/config.json')[env];
var db = {};
if (config.use_env_variable) {
var sequelize = new
Sequelize(process.env[config.use_env_variable]);
} else {
var sequelize = new Sequelize(config.database, config.username,
config.password, config);
}
fs
.readdirSync(__dirname)
.filter(function(file) {
return (file.indexOf('.') !== 0) && (file !== basename) &&
(file.slice(-3) === '.js');
})
.forEach(function(file) {
var model = sequelize['import'](path.join(__dirname, file));
db[model.name] = model;
});
Object.keys(db).forEach(function(modelName) {
if (db[modelName].associate) {
db[modelName].associate(db);
}
});
db.sequelize = sequelize;
db.Sequelize = Sequelize;
module.exports = db;
https://devcenter.heroku.com/articles/error-codes#h10-app-crashed
Your logs clearly tell you why it's crash:
2017-09-08T02:11:37.293030+00:00 app[web.1]: Unhandled rejection .
SequelizeConnectionRefusedError: connect ECONNREFUSED 127.0.0.1:3306
You are unable to connect to your SQL server.
From the looks of it, you seemed to be trying to connect to 127.0.0.1:3306 which will not work. 127.0.0.1 or localhost is your local IP.
You need to either setup/connect to Heroku's Postgres addon or use an external SQL service such as Amazon RDS.

How to run the "PushNotification" Sample on the MF Test Server (Remote Server)?

I try to run the sample push notification, from getting started (https://developer.ibm.com/mobilefirstplatform/documentation/getting-started-6-3/notifications/push-notifications-hybrid-applications/), on the MF Server using WAS and DB2. The sample inside the MF Studio Eclipse works on the MF development server.
Problem: Getting a pushNotification on the MobilDevice
IT WORKS with MF Studio Eclipse on the default the MF development server
IT DOES NOT WORK on the MF TEST SERVER using WAS and DB2
Question: How to run the "PushNotification" Sample on the MF Test Server?
Following environment is given:
MF Server (WAS,DB2)
MobileFirstTestServer (ServerConfiguration)
|-> PushNotifications (Environment)
|-> PushNotification (Application) (Deployed)
|-> PushAdapter (Adapter) (Deployed)
|-> Device Registered
Using the browser to submit a notification works:
Request:
http://192.168.126.133:9082/PushNotifications/invoke?adapter=PushAdapter&procedure=submitNotification&parameters=[%22Thomas%22,%22TEST%22]
Response from the adapter:
/*-secure-
{"isSuccessful":true,"result":"Notification :: TEST is sent to user :: Thomas"}*/
Adapter Code:
WL.Logger.debug("submitNotification >> userId :: " + userId + ", text :: " + notificationText);
WL.Server.notifyAllDevices(userSubscription, notification);
return { result: "Notification :: " + notificationText + " is sent to user :: " + userId };
It seems "WL.Server.notifyAllDevices" does not work, but why?
Any idea?
LogCat Device
04-22 11:12:18.280: D/WLNativeXHR(3146): callback {"headers":{"Content-Language":"en-US","Date":"Wed, 22 Apr 2015 16:22:18 GMT","Content-Length":"70","P3P":"policyref=\"/w3c/p3p.xml\", CP=\"CAO DSP COR CURa ADMa DEVa OUR IND PHY ONL UNI COM NAV INT DEM PRE\"","Expires":"Thu, 01 Jan 1970 00:00:00 GMT","Content-Type":"application/json; charset=UTF-8","X-Powered-By":"Servlet/3.0","Pragma":"no-cache","Cache-Control":"no-cache, no-store, must-revalidate"},"status":200,"responseText":"/*-secure-\n{\"isSuccessful\":true,\"warnings\":[],\"errors\":[],\"info\":[]}*/\n","statusText":"OK"}
04-22 11:12:18.280: W/PluginManager(3146): THREAD WARNING: exec() call to LoggerPlugin.log blocked the main thread for 46ms. Plugin should use CordovaInterface.getThreadPool().
04-22 11:12:18.296: D/NONE(3146): Application is now online.
04-22 11:12:18.324: D/NONE(3146): response [/apps/services/api/PushNotifications/android/notifications] success: /*-secure-
04-22 11:12:18.324: D/NONE(3146): {"isSuccessful":true,"warnings":[],"errors":[],"info":[]}*/
04-22 11:12:18.344: D/CordovaLog(3146): file:///android_asset/www/default/worklight/worklight.js: Line 5755 : No matching configurations found from the server. Defaulting to local configuration
04-22 11:12:18.344: I/Web Console(3146): No matching configurations found from the server. Defaulting to local configuration at file:///android_asset/www/default/worklight/worklight.js:5755
04-22 11:12:18.448: D/dalvikvm(3146): GC_CONCURRENT freed 244K, 14% free 9237K/10631K, paused 37ms+8ms, total 63ms
04-22 11:12:22.440: D/NONE(3146): Piggybacking event transmission
04-22 11:12:22.440: D/NONE(3146): Flush called
WAS TRACE LOG .. working push .. after changing the Firewall settings and the log level of was for the MF Test Server (Remote Server)
[4/24/15 10:19:53:754 CEST] 00000160 E UOW= source=com.worklight.gadgets.serving.GadgetAPIServlet class=com.worklight.gadgets.serving.GadgetAPIServlet method=createAjaxRequestExceptionJSON org= prod= component= thread=[WebContainer : 4] requestID=[AAAGStFDCFY-AAAAAAAAALb] appName=[IBM_Worklight_project_runtime_PushNotificationsMobileFirstTestServer]
FWLSE0020E: Ajax request exception: Notification token unknown, subscribe to PushAdapter.PushEventSource failed. [project PushNotifications]
[4/24/15 10:19:53:767 CEST] 00000160 E UOW= source=com.worklight.gadgets.serving.GadgetAPIServlet method=createAjaxRequestExceptionJSON org=null prod=null component=null thread=[WebContainer : 4] requestID=[AAAGStFDCFY-AAAAAAAAALb] appName=[IBM_Worklight_project_runtime_PushNotificationsMobileFirstTestServer]
FWLSE0117E: Error code: 1, error description: INTERNAL_ERROR, error message: FWLSE0069E: An internal error occurred during gadget request [project PushNotifications]Notification token unknown, subscribe to PushAdapter.PushEventSource failed., User Identity {wl_anonymousUserRealm=null, wl_deviceNoProvisioningRealm=(name:0ef47860-0edb-3d98-b495-df2c2efd3cbc, loginModule:WLDeviceNoProvisioningLoginModule), wl_directUpdateRealm=(name:null, loginModule:WLDirectUpdateNullLoginModule), wl_deviceAutoProvisioningRealm=null, wl_antiXSRFRealm=(name:92h5o8g0b3n396s0ovnbjhhr1k, loginModule:WLAntiXSRFLoginModule), wl_authenticityRealm=null, wl_remoteDisableRealm=(name:null, loginModule:WLRemoteDisableNullLoginModule), SampleAppRealm=null, PushAppRealm=(name:Thomas, loginModule:PushAppLoginModule), SubscribeServlet=null, myserver=(name:Thomas, loginModule:PushAppLoginModule)}. [project PushNotifications]
[4/24/15 10:20:34:639 CEST] 00000160 E UOW= source=com.worklight.integration.js.JavaScriptIntegrationLibraryImplementation class=com.worklight.integration.js.JavaScriptIntegrationLibraryImplementation method=sendMessage org= prod= component= thread=[WebContainer : 4] requestID=[AAAGStFDCFY-AAAAAAAAALr] appName=[IBM_Worklight_project_runtime_PushNotificationsMobileFirstTestServer]
FWLSE0227E: Failed to send notification. Reason: FPWSE0009E: Internal server error. No devices found [project PushNotifications]
[4/24/15 10:21:43:126 CEST] 00000161 E UOW= source=com.ibm.isclite.runtime.aggregation.tags.PageTitleTag class=com.ibm.isclite.runtime.aggregation.tags.PageTitleTag method= doStartTag() org= prod= component= thread=[WebContainer : 5] requestID=[AAAGStFDCFY-AAAAAAAAAMI] appName=[isclite]
CWLAA5015W: Exception while rendering a page: com.ibm.isclite.datastore.TitleServiceException: Error retrieving title for "com.ibm.isclite.wccm.base.impl.TextImpl#ecc458d2 (string: null, uniqueName: null)"
[4/24/15 10:21:43:130 CEST] 00000161 W UOW= source=com.ibm.isclite.runtime.aggregation.tags.WindowTitleTag class=com.ibm.isclite.runtime.aggregation.tags.WindowTitleTag method=doStartTag() org= prod= component= thread=[WebContainer : 5] requestID=[AAAGStFDCFY-AAAAAAAAAMI] appName=[isclite]
CWLAA5015W: Exception while rendering a page: com.ibm.isclite.datastore.TitleServiceException: Error retrieving title for "com.ibm.isclite.wccm.base.impl.TextImpl#a895a4ef (string: null, uniqueName: null)"
[4/24/15 10:22:16:666 CEST] 00000161 I UOW= source=com.ibm.ws.webcontainer.servlet.ServletWrapper class=com.ibm.ws.webcontainer.servlet.ServletWrapper method=init org= prod= component= thread=[WebContainer : 5] requestID=[AAAGStFDCFY-AAAAAAAAAMZ] appName=[IBM_Worklight_project_runtime_PushNotificationsMobileFirstTestServer]
SRVE0242I: [IBM_Worklight_project_runtime_PushNotificationsMobileFirstTestServer] [/PushNotifications] [ClientLogUploaderServlet]: Initialization successful.
[4/24/15 10:22:17:297 CEST] 00000161 W UOW= source=com.ibm.pushworks.server.notification.gcm.GCMMediator class=com.ibm.pushworks.server.notification.gcm.GCMMediator method=addTokenToAndroidKey org= prod= component= thread=[WebContainer : 5] requestID=[AAAGStFDCFY-AAAAAAAAAMb] appName=[IBM_Worklight_project_runtime_PushNotificationsMobileFirstTestServer]
FPWSE1079W: GCM push token APA91bHtOJXjXtQvq_goqKOFvqM5ZRT8zwJEmD6U5Jyqi7hxh-EYDyv9lx0JS4LfhyPNdekJs2oYAnYpmmlqx19k9fwoE69CvZaox61u-WO6xuNE_dskvLw2lqspHoqYr9ZMwH6-gY00APw7IPXMIowDTBafzHyFVQ is not added to GCM notification key. GCM Service invocation failed (reason: notification_key already exists)
com.ibm.pushworks.server.exceptions.GCMException: GCM Service invocation failed (reason: notification_key already exists)
at com.ibm.pushworks.server.notification.gcm.GCMSender.sendToGCM(GCMSender.java:409)
at com.ibm.pushworks.server.notification.gcm.GCMSender.addTokenToAndroidKey(GCMSender.java:353)
at com.ibm.pushworks.server.notification.gcm.GCMMediator.addTokenToAndroidKey(GCMMediator.java:206)
at com.ibm.pushworks.server.core.PushServiceImpl.getNotificationKey(PushServiceImpl.java:1215)
at com.ibm.pushworks.server.core.PushServiceImpl.registerDevice(PushServiceImpl.java:429)
at com.worklight.integration.services.impl.DataAccessServiceImpl.updateDeviceToken(DataAccessServiceImpl.java:403)
at com.worklight.gadgets.serving.handler.NotificationSubscriptionHandler.doPost(NotificationSubscriptionHandler.java:126)
at com.worklight.gadgets.serving.GadgetAPIServlet.doGetOrPost(GadgetAPIServlet.java:148)
at com.worklight.gadgets.serving.GadgetAPIServlet.doPost(GadgetAPIServlet.java:108)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:595)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1227)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:776)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:458)
at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.invokeTarget(WebAppFilterChain.java:136)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:97)
at com.worklight.core.auth.impl.AuthenticationFilter$1.execute(AuthenticationFilter.java:215)
at com.worklight.core.auth.impl.AuthenticationServiceBean.accessResource(AuthenticationServiceBean.java:76)
at com.worklight.core.auth.impl.AuthenticationFilter.doFilter(AuthenticationFilter.java:220)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:195)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:91)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:928)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1025)
at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:87)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:909)
at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1662)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:200)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:459)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:526)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:312)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:88)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:175)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1862)
[4/24/15 10:24:35:150 CEST] 00000161 I UOW= source=com.ibm.ws.webcontainer.servlet.ServletWrapper class=com.ibm.ws.webcontainer.servlet.ServletWrapper method=init org= prod= component= thread=[WebContainer : 5] requestID=[AAAGStFDCFY-AAAAAAAAANT] appName=[isclite]
SRVE0242I: [isclite] [/ibm/console] [/com.ibm.ws.console.probdetermination/customSelectDropLayout.jsp]: Initialization successful.
[4/24/15 10:24:40:938 CEST] 00000161 I UOW= source=com.ibm.ws.webcontainer.servlet.ServletWrapper class=com.ibm.ws.webcontainer.servlet.ServletWrapper method=init org= prod= component= thread=[WebContainer : 5] requestID=[AAAGStFDCFY-AAAAAAAAANV] appName=[isclite]
SRVE0242I: [isclite] [/ibm/console] [/com.ibm.ws.console.probdetermination/logfileViewLayout.jsp]: Initialization successful.
The LogCat log is incomplete. It does not show that the device was able to receive a notification token, subscribe for push notifications on the MFP server, etc...
Provide a fuller LogCat log
Verify in your test server's network that all required addresses and ports are open for outgoing and incoming connections that are listed for Android, here: https://developer.ibm.com/mobilefirstplatform/documentation/getting-started-6-3/notifications/push-notifications-hybrid-applications/#projectSetupAndGuidelines

Glassfih + WSO2 ESB 415 Unsupported media type

I am creating "Pass Through Proxy" in WSO2ESB using JAX-WS hosted on Glassfish.
The problem is that the proxy does not work and it happens with EVERY PROXY I create in the ESB that are pointing to every Java Web Services on Glassfish: the console gives this error [1]. The thing is that Proxies to .Net Services instead, works fine.
1) I have tried with the ESB tryit tool to consume the service and I have the following response:
<TryitProxyError h:status="SOAP envelope error" xmlns:h="http://wso2.org/ns/TryitProxy">org.apache.axis2.AxisFault: Transport error: 415 Error: Unsupported Media Type</TryitProxyError>
2) Instead soapUI which gives me this message:
Error loading [ClientProxy?xsd=http://192.168.10.176:8080/ESBAdminWebapp_SERVER/ClientProxy?xsd=1]: java.io.IOException: Attempted read from closed stream
where 192.168.10.176:8080is the Glassfish server. But if I call the real WSDL it works...
I have tried with a fresh installation of WSO2-ESB and fresh Glassfish server as well:
WSO2 ESB, Glassfish and IIS are now installed LOCALLY to try to spot the problem.
Please help!
[1] FULL LOG:
TID: [] [WSO2 ESB] [2012-09-24 11:31:11,689] INFO {org.apache.synapse.mediators.builtin.LogMediator} - To: /services/test.testHttpSoap12Endpoint, WSAction: http://my/Hello/helloRequest, SOAPAction: http://my/Hello/helloRequest, MessageID: urn:uuid:754dfcb5-1008-47ed-9c25-15327370ee11, Direction: request, Envelope: ? {org.apache.synapse.mediators.builtin.LogMediator
[2012-09-24 11:31:11,689] INFO - LogMediator To: /services/test.testHttpSoap12E
ndpoint, WSAction: http://my/Hello/helloRequest, SOAPAction: http://my/Hello/hel
loRequest, MessageID: urn:uuid:754dfcb5-1008-47ed-9c25-15327370ee11, Direction:
request, Envelope: <?xml version='1.0' encoding='utf-8'?><soapenv:Envelope xmlns
:soapenv="http://www.w3.org/2003/05/soap-envelope"><soapenv:Body><p:hello xmlns:
p="http://my/"><!--0 to 1 occurrence--><name>?</name></p:hello></soapenv:Body></
soapenv:Envelope>
[2012-09-24 11:31:11,694] INFO - LogMediator To: http://www.w3.org/2005/08/addr
essing/anonymous, WSAction: , SOAPAction: , MessageID: urn:uuid:e9b224e8-2754-41
1f-8640-5922f1797202, Direction: response, Envelope: <?xml version='1.0' encodin
g='utf-8'?><soapenv:Envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envel
ope"><soapenv:Body><axis2ns7:binary xmlns:axis2ns7="http://ws.apache.org/commons
/ns/payload"></axis2ns7:binary></soapenv:Body></soapenv:Envelope>
[2012-09-24 11:31:11,697] INFO - HTTPSender Unable to sendViaPost to url[http:/
/localhost:8280/services/test.testHttpSoap12Endpoint]
org.apache.axis2.AxisFault: Transport error: 415 Error: Unsupported Media Type
at org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.
java:308)
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.jav
a:194)
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessa
geWithCommons(CommonsHTTPTransportSender.java:449)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(Com
monsHTTPTransportSender.java:276)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:443)
at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisO
peration.java:406)
at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(Out
InAxisOperation.java:229)
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:
165)
at org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:
555)
at org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:
531)
at org.apache.jsp.admin.jsp.WSRequestXSSproxy_005fajaxprocessor_jsp._jsp
Service(WSRequestXSSproxy_005fajaxprocessor_jsp.java:272)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper
.java:332)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3
14)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.wso2.carbon.ui.JspServlet.service(JspServlet.java:161)
at org.wso2.carbon.ui.TilesJspServlet.service(TilesJspServlet.java:80)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.eclipse.equinox.http.helper.ContextPathServletAdaptor.service(Con
textPathServletAdaptor.java:36)
at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleR
equest(ServletRegistration.java:90)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(P
roxyServlet.java:111)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyS
ervlet.java:67)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.wso2.carbon.bridge.BridgeServlet.service(BridgeServlet.java:164)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:304)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:240)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:164)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica
torBase.java:462)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:164)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:100)
at org.wso2.carbon.server.CarbonStuckThreadDetectionValve.invoke(CarbonS
tuckThreadDetectionValve.java:154)
at org.wso2.carbon.server.TomcatServer$1.invoke(TomcatServer.java:254)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
563)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
a:399)
at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcesso
r.java:396)
at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.pr
ocess(Http11NioProtocol.java:356)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoin
t.java:1534)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExec
utor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
.java:908)
at java.lang.Thread.run(Thread.java:662)
The exception indicates that Glassfish response with the following HTTP error:
415 Error: Unsupported Media Type
This likely means that the Content-Type header send by the proxy has a value that is not expected by Glassfish.

MongoDB Record To Array Takes Forever

I'm getting information from the database (MongoDB) and then converting it to an array like that:
#bs = coll.find("headers.from" => { "$regex" => email, "$options" => 'i' }, "date" => {"$gte" => initial_date, "$lte" => Time.now.utc})
puts "a seguir ao fetch"
puts #bs
#bs = #bs.to_a
This works very well but sometimes, it just enters in an infinite cycle (I believe) because It crashes my heroku app.
The response (the first line is the print of #bs):
2011-05-14T17:05:46+00:00 app[web.1]: DBResponse(flags=, cursor_id=, start=)
2011-05-14T17:06:16+00:00 heroku[router]: Error H12 (Request timeout) -> GET yapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-14T17:06:47+00:00 heroku[router]: Error H12 (Request timeout) -> GET yapi.heroku.com/favicon.ico dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-14T17:07:10+00:00 heroku[router]: Error H12 (Request timeout) -> GET yapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-14T17:07:17+00:00 heroku[router]: Error H12 (Request timeout) -> GET yapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-14T17:07:51+00:00 heroku[router]: Error H12 (Request timeout) -> GET yapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
I'd like to know why because I really can't find out why with all the debug information. IT just holds on the ".to_a" forever and the server is blocked.
Please help.
Thanks
From what I see, there is no reason for RoR to terminate this loop.
If you can, try initializing it as a Kernel#Array. Try this:
Array([1,2,3]) #=> [1, 2, 3]
Array(123) #=> [123]
Instead of:
arg = arg.to_a