I had created a table in SAPUI5 using ODATA services. And it worked perfectly fine until today. Today the HTML file loads a blank page and when i check the developer tools, I see the following error:
Failed to load resource http://hana_server_name:4000/ui_test/ui5_test/WebContent/ui5_test/VisitorData.view.js
Uncaught Error: failed to load 'ui5_test/VisitorData.view.js' from ./ui5_test/VisitorData.view.js: 0 - NetworkError: A network error occurred.
The ODATA service is working fine, and I'm using the same ODATA file to create a chart, and the chart renders as normal.
I'm getting the same error message for 2 tables that I've created.
It looks like this is caused by some changes to the server but I'm not sure what changed or if its a problem with my code. If its a server error, what should i be looking for.
Thank you,
Salman
The error message is pretty obvious, isn't it? Your view VisitorData.view.js was simply not found and therefore can not load. Did you check if it is physically available on the server? Missing file permissions could be another reason.
You can also check
http://hanaservername.com:4000/ui_test/ui5_test/WebContent/resources/ to see a listing of the deployed sources (if your application/server is configured to allow that). On Java Application Servers (local Tomcat, Java Stack, no clue what HANA uses...) you need to set the following in your web.xml:
<context-param>
<param-name>com.sap.ui5.resource.DEV_MODE</param-name>
<param-value>true</param-value>
</context-param>
i consider you are binding data which you get from server to your table or chart.
Even if server didn't give you the data your code should work properly without giving any error, so i suppose problem should be in your code.
Just run your code with debug mode ON on your browser and click on error thrown by browser and it will lead you to the line which is causing the error
Related
I have published my code into QA server for testing. my code working fine on dev server. But on QA server my image button not fires an event. I went an developer console and see what i am getting. So i compare on my local to QA. Please find the images below. Those images from the developer tool-Console.
This is the error I am getting on QA
This is from my local host for the same page(working)
EDIT
If image not shown. This is the error I got.
Uncaught TypeError: Cannot read property 'PRM_ServerError' of undefined
MsAjaxJs?v=c42ygB2U07n37m_Sfa8ZbLGVu4Rr2gsBo7MvUEnJeZ81:1
I know this is kind of vague. But this is the error I got. I have no idea how I can find why my button not fire an event on QA server.
Please Help! Thanks
I have resolved my issue. As my image button was not fired, I have taken out the update panel from that .aspx page and set custom error mode to off on web.config on QA server. Then I could able to see the yellow(error) page.
My error was it was connecting to the wrong login user to database. When I created a entitymodel, I hide the username and password(integrated security=True). It works perfectly at my local machine. after I published it connecting to the different login. So, I gave username and password (persist security info=True) at datasource connection string. Now my image button event fired and worked perfectly.
Finally, I put back my update panel and comment out custom error mode from web.config on published server.
I will be glad if this helps someone!
Also had this problem with my .ascx user control (ASP.NET Web Pages project).
Make sure you do
this
first
In my case, I was missing a PostBackTrigger on my control:
<asp:PostBackTrigger ControlID="yourControl" />
Turned out, in my case, that the session state was being lost on Login. If this issue occurs for any one on the postback of the login credentials I would investigate this avenue.
I switched my site to use SQLServer Session management and all my problems disappeared.
<sessionState mode="SQLServer" sqlConnectionString="ASPState" allowCustomSqlDatabase="true" cookieless="false" cookieSameSite="None" timeout="780"/>
I have used stomp+ActiveMQ in my application to push the data events received from external applications. I am able to setup this on HTTP [ws] but when I tried moving this setup to my production server where we have HTTPS [wss], the setup is failing with error saying un-authorised access. I understand it is because of the SSL what we have on production server, but I am unable to find out solution for this, I tried searching and tried following the proposed solutions but none are working. Any help would be highly appreciated.
Update 1: Adding the details asked
Here is the code what I have added for STOMP
var client = Stomp.client("wss://domain:61614/stomp");
And the error I get is "ReferenceError: Stomp is not defined"
activemq : 5.9.0
STOM : 1.0.9
it's a js side log, did you have included your js stomp file ??
<script src='stomp.js'></script>
https://github.com/apache/activemq/tree/master/activemq-web-demo/src/main/webapp/websocket
I resolved the issue, and it was related to the key strokes what I had generated earlier. I just deleted the previous one and recreated a new one for my SSL and everything started working with the sample application provided by STOMP team. I will integrate it in my actual project and will paste the solution here for everyone use.
Following are the settings we had used.
transportConnector name="wss" uri="wss://0.0.0.0:61614?maximumConnections=1000&wireFormat.maxFrameSize=104857600&wireFormat.maxInactivityDuration=500000000&wireFormat.maxInactivityDurationInitalDelay=36000000&websocket.maxIdleTime=0&transport.useInactivityMonitor=false"
I have a web form project that I started in VS2010 and I have recently upgraded to VS2013.
However I am now getting the above error. Searching the web the solution states to add the following key in my web.config file.
<add key="ValidationSettings:UnobtrusiveValidationMode" value="None" />
However why am I getting this error in the first place?
I have several pages that work, but it wasn't until I added my Login.aspx file did I start to get this error.
Am I getting this error because this particular page is using ASP validators?
What I don't like is when I add the above web.config key I get a javascript error:
JavaScript critical error at line 3, column 1 in http://localhost:11111/Scripts/jquery-2.2.1.js\n\nSCRIPT1002: Syntax error
If I continue on past the error the page does function correctly.
If I can better understand this error maybe it would be more beneficial for me to address this particular page instead of just turning off stuff in the web.config.
Comments on this post I found in the wild:
Coding Fusion link
Suggest that you can register your jquery script properly in Web Forms by adding this to your page load codebehind:
ScriptManager.ScriptResourceMapping.AddDefinition("jquery", new ScriptResourceDefinition { Path = "~/scripts/...", DebugPath = "~/scripts/..." });"
This may be preferable to turning off settings in your web config.
I've given the docs a good looking over as well as SO, however can't seem to find any answers.
I have a packaged chrome app (new style, not legacy)
I can find many documents on enabling logging as in errors/crash reports, but can't find anything about custom logging. For example:
On initial load some 3rd party data is loaded via a api call, lets just assume it:
$http.get('/api/get-my-data').onSuccess(function(data){
// Yay, I gotz the dataz. Do something
}).onFail(function(error) {
// Damn son, something went wrong.
});
In the above pseudo code I'd like add to a chrome error/custom log to record the onFail condition. I'm not looking to record error in the sense that the app has crashed or a fatal error, I'm looking to log events that in the context of the app running correctly I regard as errors.
If an error caused the app to crash etc then I'd get a entry in the chrome logs, but there must (I assume) be away to log data directly to a log on the server that isn't considered an error (perfectly common if this was a web app on a server (log4j, KLogger, Morgan)) but I can't find it
Anyone else created a chrome packaged add and used the inbuilt logging?
Thanks
N.B. Just to be clear, we are talking about logging in a packaged app with javascript to a log file, not console.log
Thought I'd answer this incase someone else comes across it as it's not clear form the google docs.
when you use console.log it gets sent to your strdout/chrome log file.
You have to enable logging in your chrome app launch config/flags, then any console.log in your code will show up where ever you set your user-dir to be.
It's not clear from the documentation, but basically your chrome app will automatically log and console.log you have
This includes other console methods.
I'm testing my project in the production server where I'm getting several errors of various features in my web application which is working perfectly on my computer.
Please go to http://qlimp.com and login using this username/password: nirmal/karurkarur Then go to http://qlimp.com/cover You'll find a palette where you can upload images and do something similar to flavors.me. I'm having several problems here(images,text,other information are not getting stored in the database).
I think there is no problem with the setup. The problem is it is not even entering into the Django views properly but working without any problem on my computer. Is there anyone experienced the same problem? I'm wondering why is it not working.
Also you can check out in http://qlimp.com/signup/ and you can find the problem where the datas are not get stored.
So there are many problems which I can't ask in one question(not a stackoverflow culture) and so I'm asking this.
When I upload the image I checked in chrome inspector 'network tab' it shows 502 bad gateway
Here is my Django views.py: https://gist.github.com/2778242
jQuery Code for the ajax image upload:
$('#id_tmpbg').live('change', function()
{
$("#ajax-loader").show();
$("#uploadform").ajaxForm({success: showResponse}).submit();
});
function showResponse(responseText, statusText, xhr, $form) {
$.backstretch(responseText)
$("#ajax-loader").hide();
}
And I also checked that it is actually entering into the request.is_ajax() but not into form.is_valid() in my views. Why is it so? I'm uploading the right format.
Could anyone identify the mistake I've done? Also I need an answer on Why the code is not working on production server which is actually working on the development server (this would be helpful for me to solve rest of the problems).
Development server: Ubuntu 11.10/Python 2.7/Django 1.3.1
Production server: Ubuntu 12.04/Python 2.7/Django 1.3.1
UPDATE
There is some problem in everyone signing in with the same user/password. So please register there and it shows [Errno 111] Connection refused, doesn't matter, you can login then.
UPDATE-2
Actually the problem is with form.is_valid() so I removed it and checked but now I'm getting this error:
Exception Type: ValueError
Exception Value: The BackgroundModel could not be created because the data didn't validate.
Exception Location: /home/nirmal/project/local/lib/python2.7/site-packages/django/forms/models.py in save_instance, line 73
I'm all-time uploading the right Image format and I don't know why it is not validating.
UPDATE-3
I'm getting 304 Not Modified for all the static files in http://qlimp.com/cover Will this be a problem for not working?
It's Nginx that gives the 502 error when gunicorn is not available.
gunicorn_django -bind=127.0.0.1:8001 only launches one synchronous worker process and it may be busy responding to other requests.
You may want to spawn more workers (-w2). If you need to handle big data transfers consider using an asynchronous worker flavor (e.g. -k gevent, you need gevent to be installed).
More info on choosing the worker class and the number of workers in Gunicorn FAQ.
I've found the problem which was stucking me for the past 3 days. It is because I've forget to do this sudo apt-get install libjpeg62 libjpeg62-dev zlib1g-dev before the PIL installation, that is why the image is not get validated.
The next issue is I've given a relative path for the MEDIA_ROOT in my settings.py file which leads to 404 NOT FOUND and I changed it to absolute path.
So these are simple mistakes which leads to some mysterious errors. Also Thanks to everyone for the help.