Atlassian-connect: Error on 'installed' event - node.js

I'm trying to run example Jira add-on.
I have created credentials.json file and have run npm i and node app.js.
But I have problems with installed event. Here is nodejs log:
Watching atlassian-connect.json for changes
Add-on server running at http://MacBook-Air.local:3000
Initialized sqlite3 storage adapter
Local tunnel established at https://a277dbdf.ngrok.io/
Check http://127.0.0.1:4040 for tunnel status
Registering add-on...
GET /atlassian-connect.json 200 13.677 ms - 784
Saved tenant details for 608ff294-74b9-3edf-8124-7efae2c16397 to database
{ key: 'my-add-on',
clientKey: '608ff294-74b9-3edf-8124-7efae2c16397',
publicKey: 'MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCtKxrEBipTMXhRHlv9zcSLR2Y9h5YQgNQ5vpJ40tF9RmuIzByjkKTurCLHFwMAWU6aLQM+H+Z8wAlpL9AVlN5NKrEP8+a3mGFUOj/5nSJ7ZWHjgju0sqUruyEkKLvKuhWkKkd9NqBxogN0hxv7ue5msP5ezwei/nTJXmnmA5qOAQIDAQAB',
sharedSecret: 'LfT9elHM7iHkto5pHr+MnpH0SR1ypunIDoCyt6ugVJ1Q4hWHurG8k5DjVzLcvT2C98DDbiJiA89VNB0e3DiUvQ',
serverVersion: '100075',
pluginsVersion: '1.3.407',
baseUrl: 'https://gleb-olololololo-22.atlassian.net',
productType: 'jira',
description: 'Atlassian JIRA at https://gleb-olololololo-22.atlassian.net ',
eventType: 'installed' }
POST /installed?user_key=admin 204 51.021 ms - -
Failed to register with host https://gleb-olololololo-22%40yopmail.com:gleb-olololololo-22#gleb-olololololo-22.atlassian.net (200)
The add-on host did not respond when we tried to contact it at "https://a277dbdf.ngrok.io/installed" during installation (the attempt timed out). Please try again later or contact the add-on vendor.
{"type":"INSTALL","pingAfter":300,"status":{"done":true,"statusCode":200,"contentType":"application/vnd.atl.plugins.task.install.err+json","errorMessage":"The add-on host did not respond when we tried to contact it at \"https://a277dbdf.ngrok.io/installed\" during installation (the attempt timed out). Please try again later or contact the add-on vendor.","source":"https://a277dbdf.ngrok.io/atlassian-connect.json","name":"https://a277dbdf.ngrok.io/atlassian-connect.json"},"links":{"self":"/rest/plugins/1.0/pending/80928cb9-f64e-42d0-9a7e-a1fe8ba81055","alternate":"/rest/plugins/1.0/tasks/80928cb9-f64e-42d0-9a7e-a1fe8ba81055"},"timestamp":1513692335651,"userKey":"admin","id":"80928cb9-f64e-42d0-9a7e-a1fe8ba81055"}
Add-on not registered; no compatible hosts detected
I have reviewed tons of information in Google, but didn't found an answer.
More details, that can helps you to answer.
It happens suddenly. It worked OK, but about 1 week ago I start to get this error and cannot fix it. So I didn't change anything, just run add-on again, as I did it every day.
If I try to upload add-on manually I got error in terminal
GET / 302 17.224 ms - 0
GET /atlassian-connect.json 200 2.503 ms - 783
Found existing settings for client 608ff294-74b9-3edf-8124-7efae2c16397. Authenticating reinstall request
Authentication verification error: 401 Could not find authentication data on request
POST /installed?user_key=admin 401 22.636 ms - 45
The most possible reason (that I've found in google) is that I have wrong server time. But the time on my local machine is correct (at least for my timezone).
Anyone has any thoughts about this problem?
Thanks!

I kept randomly having this happen to me. It would be working, then run npm start and I would get the error. Since I'm not using a database right now, I simply removed all references to the juggling-sqlite database. This was in package.json, package-lock.json, config.json, and I just removed store.db. That got it working for me. Pretty frustrating that this happens, not sure a better way around it.

Related

Rhel osbuild-composer system repository override is not working

As per document (https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/composing_a_customized_rhel_system_image/managing-repositories_composing-a-customized-rhel-system-image) tried to override the system repository with custom base url . But blueprint depsolve is showing error as below
##composer-cli blueprints depsolve Test1-blueprint
2022-06-09 08:06:58,841: Test1-blueprint: This system does not have any valid subscriptions. Subscribe it before specifying rhsm: true in sources.
And with next service restart osbuild-composer does not start
ERROR: Info Error: Get "http://localhost/api/v1/projects/source/info/appstream": dial unix /run/weldr/api.socket: connect: connection refused
Am I missing something here ?
Having all manner of issues with this myself. A trawl of my /var/log/messages file, and it looks like, for me at least, osbuild-composer is failing to start due to the non existence of /etc/osbuild-composer/osbuild-composer.toml. Actual error is permission denied, but it doesnt exist..
This is on RHEL 8.5, and just updated to 8.6 this morning, and same problem
/edit Ive removed everything, and reverted to using the lorax backend, as per chapter 2.2 in the doc linked (same one I was following). My 'composer-cli compose types' command now at least works. Fingers crossed..

Response as undefined after an API call

I am using the request library to fetch a response from an API, everything was working fine but as of recent, I have started to get local issuer certificate error from the API although the same code is working on my colleague's system.
I have already tried updating the node version and all the version changes regarding the request package of node
The exact error is:
unable to get local issuer certificate node
Here is the error snippet in the console
Could u please console only response..After that u can easily see that there is statusCode is available or not.
Or if u get the statusCode then check its defined or not.
Ex: if(res.statusCode)
console.log("print status code", this.res.statusCode);
This is an SSL error and yo need to make sure that your server's certificate is valid.
With your claim that it used to work - but it stopped working recently with the SSL error message, the possibilities are that either your servers certificate is expired in between or the Sectigo AddTrust External CA Root Expiring May 30, 2020.
https://support.sectigo.com/Com_KnowledgeDetailPage?Id=kA03l00000117LT
Updating the certificate is outside the scope of this answer. You may have to do it yourself or contact the admin.

SSAS Data Pump - IsapiModule could not be found

The data pump was previously running on an server with IIS and SQL Server running on the same server. It was working fine. We've been provided a new SQL named instance and we're trying to re-setup the data pump to point to the new server. New SQL server is also new version, so we are using the new msmdpump from the new SQL installation. We've previously set this up on several client sites, so have followed the requirements with the data pump setup, but in this case I'm stuck with a "specified module could not be found" for the IsapiModule. I suspected that it might be an access issue to the msmdpump dll, but I've gone as far as to move the folder to a location with "full everyone access". I've set up tracing and the relevant details for the problem seems to be;
MODULE_SET_RESPONSE_ERROR_STATUS
ModuleName: IsapiModule
Notofocation: EXECUTE_REQUEST_HANNDLER
HttpStatus: 500
HttpReason: Internal Server Error
HttpSubStatus: 0
ErrorCode: The specified module could not be found. (0x8007007e)
I've tried everything I could find online, so any assistance or advice will be great.
Same error as the following IIS 8.0 Detailed 500.0 Internal Server Error - IsapiModule Not Found
Ok this was quite tough, had exactly the same issue but was able to resolve by installing this:
Which I found here:
https://www.microsoft.com/en-us/download/details.aspx?id=40784

Heroku/MongoLab not working

I ma using heroku and mongolab to host my node app.
So far everything had been working great but now everytime I try to access my mongolab dashboard from heroku I get the following 500 error:
HTTP Status 500 - Cannot call sendRedirect() after the response has been committed
type Exception report
message Cannot call sendRedirect() after the response has been committed
description The server encountered an internal error that prevented it from fulfilling this request.
exception
java.lang.IllegalStateException: Cannot call sendRedirect() after the response has been committed
org.apache.catalina.connector.ResponseFacade.sendRedirect(ResponseFacade.java:482)
javax.servlet.http.HttpServletResponseWrapper.sendRedirect(HttpServletResponseWrapper.java:137)
org.objectlabs.http.RedirectValidatingHttpServletResponseWrapper.sendValidatedRedirect(RedirectValidatingHttpServletResponseWrapper.java:77)
org.objectlabs.http.RedirectValidatingHttpServletResponseWrapper.sendRedirect(RedirectValidatingHttpServletResponseWrapper.java:51)
org.owasp.csrfguard.http.InterceptRedirectResponse.sendRedirect(InterceptRedirectResponse.java:59)
org.olabs.mongolabs.util.ErrorPage.doRedirectTo(ErrorPage.java:53)
org.olabs.mongolabs.util.ErrorPage.redirectTo(ErrorPage.java:32)
org.olabs.mongolabs.user.login.LoginGatekeeper.doFilter(LoginGatekeeper.java:63)
org.owasp.csrfguard.CsrfGuardFilter.doFilter(CsrfGuardFilter.java:79)
org.objectlabs.http.RedirectValidationFilter.doFilter(RedirectValidationFilter.java:20)
org.objectlabs.http.HttpFilter.doFilter(HttpFilter.java:23)
org.objectlabs.http.ClickjackingProtectionFilter.doFilter(ClickjackingProtectionFilter.java:68)
org.objectlabs.http.HttpFilter.doFilter(HttpFilter.java:23)
org.objectlabs.http.AddDefaultCharsetFilter.doFilter(AddDefaultCharsetFilter.java:50)
ch.qos.logback.classic.helpers.MDCInsertingServletFilter.doFilter(MDCInsertingServletFilter.java:51)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.52 logs.
Apache Tomcat/7.0.52
I am trying to access this url:
https://addons-sso.heroku.com/apps/my-app/addons/mongolab:sandbox
have I dont something wrong??
Apologies for the confusion. For your protection, we have expired all passwords after the heartbleed issue was announced this week and it appears that while you usually SSO in from Heroku you do actually have a password with us.
You appear to have hit an edge case with that code. You should be forced to your user info screen where you can update your password, but it appears you're tripping over an error. Could you write us at support#mongolab.com so that we can identify your account and work through the issue with you?

Error reaching the Node.js server in drupal 7

I have installed node.js server on shared hosting.I have drupal site in which I am using node.js integration module to connect to node.js server.
But whenever I am trying to broadcast message from admin panel, I am getting this error message "Error reaching the Node.js server "Error reaching the Node.js server at "nodejs/publish" with {"data":{"somecustomdata":"http://www.google.ca"},"channel":"nodejs_user_1","callback":"myowncallback","clientSocketId":""} "%{"data":{"somecustomdata":"http://www.google.ca"},"channel":"nodejs_user_1","callback":"myowncallback","clientSocketId":""}": [404] Not Found." in db log.
Any help would be appreciated.
It is very likely one of two things:
Drupal server is accessing wrong URI.
Node.js Server is not listening to the URI you expect it to.
Of course something less obvious might cause errors, but please verify those two before proceeding.
Best would be to get your Drupal server print in error logs the URI it is trying to access, and manually verify you can access it within your browser, or another tool.
Thanks "alandrev" for your help.I have resolved that issue on the same day but I forgot to add my mistake.Actually I was not configuring the nodejs correctly.I was using the incorrect port number on backend settings in nodejs.config.js file.The correct settings mentioned below:
backendSettings = {
"scheme":"https",
"host":"yourhostname",
"port":"port number which is not already in use",
'sslKeyPath': 'key file path for ssl enabled site otherwise leave empty',
'sslCertPath': 'certificate path for ssl enabled site otherwise leave empty',
'sslCAPath': '',
"resource":"/socket.io",
"baseAuthPath": '/nodejs/',
"publishUrl":"publish",
"serviceKey":"",
"backend":{
"port":443,
"scheme": 'https or http',
"host":"yourhostname",
"messagePath":"/nodejs/message/"},
"clientsCanWriteToChannels":false,
"clientsCanWriteToClients":false,
"extensions":"",
"debug":false,
"addUserToChannelUrl": 'user/channel/add/:channel/:uid',
"publishMessageToContentChannelUrl": 'content/token/message',
"jsMinification":true,
"jsEtag":true,
"logLevel":1};
Solved this same issue by adding "polling" to the transport
backendSettings = {
"scheme":"http",
"host":"localhost",
"port":8081,
"key":"/path/to/key/file",
"cert":"/path/to/cert/file",
"resource":"/socket.io",
"publishUrl":"publish",
"serviceKey":"SERVICE KEY",
"backend":{
"port":80,
"host":"localhost",
"messagePath":"/mysite/nodejs/message/"},
"clientsCanWriteToChannels":true,
"clientsCanWriteToClients":true,
"extensions":"",
"debug":true,
"transports":["websocket","polling",
"flashsocket",
"htmlfile",
"xhr-polling",
"jsonp-polling"],
"jsMinification":true,
"jsEtag":true,
"logLevel":1};

Resources