I'm looking to deploy mapping functionality in the Work Execution app within the Maximo Anywhere framework. The issue I'm having is the app throws an error when I attempt to go into the "Map of Work Orders" screen. The error that displays on the screen is
"Unable to show map. It is possible that the value for the providerURL property is invalid. Contact your administrator."
When I look into the logging data I get a bunch of lines about OpenLayersMap.js - stating that the providerURL is wrong.
In the app.xml for the WorkExecution app we have this configured in the Map tag (line 3320 in our config)
<map adjustToTop="true" androidLocalMapUrl="file://mnt/sdcard/basemaps/Manhattan.tpk" id="WorkExecution.MapView_esri_true" iosLocalMapUrl="Manhattan.tpk" iosMapAccessMethod="useDocumentsFolder" layoutInsertAt="map" provider="esri" workOfflineResource="workOrder" providerUrl="http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer/tile/{z}/{y}/{x}"/>
Additionally, we've enabled maps in the app-feature.properties file by setting map.enabled=true
Does anyone have online maps working in a test environment on 7.5.2 in the work execution app? If so, mind sharing their config if it hits a public server, or point out what's wrong with ours?
This message inform you that the value for providerUrl is invalid or that this connection to the server could not be achieved. I checked here and it seems that this value is correct.
Are you using the adminmode? Because internally, the value for providerUrl from app.xml can be replaced by the value of providerUrl from the server via adminmode (maximo). To check if you are using it, take a look at your worklight.properties file and if the property for si.adminmode is true, you need to confirm if the value put on maximo to providerUrl is a valid one.
Related
Session not persisted in Azure App Service
I have a Web Application in Asp.net MVC, I used to set the session. When I click a LoginButton
Session["FlowType"] : "Auth"
Now the request goes to IdentityServer and during Callback on
I tried to retrieve the session Session["FlowType"] and it gave me null value.
I checked the Azure Affinity Cookie too. It is same, when I checked in fiddler.
Can someone help me with this.
First, make sure the strings is same like 'FlowType'.
Second,you can try to debug your code like below.
Session["FlowType"]="aaa";
string test = Session["FlowType"].ToString();
Check the value of 'test', is null or 'aaa'. If the value of test is correct,maybe you can print Ctrl+Alt+i to open the Immediate Window in Visual Studio. Then you can check when the Session is missing.
The last Step,maybe you can modfiy your web.config to set config about the Session.
I hope the above answers can help you.
Add Pic
How to debug in azure. You also can google it.
step 1: Make sure publish configuration setting. Like pic bellow
step 2: When publish succeed,you can attach debugger
My IDE is vs2019, you can click View-> Cloud Explore ,then you find you sourcegroup and web app.
Like pic, you find it , and click, it will show Attach Debugger, then you
debugger in azure to test.
3. The first debugging will take a long time.
In my company we have identical environments for our application: IT, ST, AT and PRD. We use Terraform to deploy our Azure resources, and are currently attempting to set up an API management solution which passes calls to a Function App backend.
The set up is fairly simple, we have a series of APIs declared, and in their backend policies we declare this bit:
<policies>
<inbound>
<set-backend-service id="apim-generated-policy" backend-id="function-at" />
</inbound>
</policies>
In IT/ST we have been able to set this successfully. However, when our Terraform pipeline runs on AT, it always fails to update our APIs with this error:
Error: Error creating or updating API Operation Policy (Resource Group "rg-at" / API Management Service "api-at" / API "call" / Operation "get-call"):
apimanagement.APIOperationPolicyClient#CreateOrUpdate: Failure responding to request:
StatusCode=400 -- Original Error: autorest/azure: Service returned an error. Status=400 Code="ValidationError" Message="One or more fields contain incorrect values:" Details=[{"code":"ValidationError","message":"Error in element 'set-backend-service' on line 3, column 6: Backend with id 'function-at' could not be found.","target":"set-backend-service"}]
When attempting to add this line manually in the Azure UI, the same error occurs:
Error in element 'set-backend-service' on line 3, column 10:
Backend with id 'function-at' could not be found.
I cannot understand why this refuses to work. The function exists and is in the same resource group as the API manager. My best guess is that someone has changed a setting manually in the other environments that is not reflected in the Terraform code. How can I go about troubleshooting this issue? I did a side-by-side comparison of the ST and AT APIs/functions and did not find any obvious differences.
Thanks in advance for any help!
I faced the same problem during Terraform deployment and for me solution was to add api_management_backend and in policy I was able reference to it.
I would say the problem is you are not setting the base-url property, so then the APIM service is not able to detect the backend component using the id. You need to specify both base-url and backend-id in case you want to use the id, as it explains in this article.
After messing around with this issue for some days, it appears the problems is that to use a backend, this backend needs to be declared first so that the API manager views it as available. I was not able to find anywhere in the UI where these "available" backends can be viewed or edited, but I reached this conclusion based on the (very sparse) description here.
It also seems like this process is done automatically when adding an API manually through the UI. This however is not the case when trying to do it with Terraform, so it appears the correct procedure would be to first publish the backend with Powershell, and then try to add it to the API with TF.
I added this to my terraform xml id="apim-generated-policy" it all then worked! It took a few good hours to figure this one out!
I'm trying to run Heat Clinic 6.0.1 locally following getting started tutorial: https://www.broadleafcommerce.com/docs/core/current/getting-started/running-locally
I managed to run admin and site but not the API project. The application starts without problems but when I go to http://localhost:8082/api/v1/swagger-ui.html I get a 404. In the log I see this exception:
javax.servlet.ServletException: Circular view path [error]: would dispatch back to the current handler URL [/error] again. Check your ViewResolver setup! (Hint: This may be the result of an unspecified view, due to default view name generation.)
Also trying to log in directly in the API with user broadleafapi and password gives 404.
My environment: Windows 10, jdk 8, maven 3.6
What's wrong? Can you help me? Thank you
Thanks for the report. I reproduced this and it looks like that with the update to Spring Boot 2.0, we did not appropriately override the updated property that specifies the servlet location to embedded Tomcat. Thus, when you went to /api/v1/swagger-ui.html, the application treats it exactly like that URL which is what gave the 404.
Setting the server.servlet.contextPath=/api/v1 property appropriately stripped off this path as part of the servlet context and resolved the 404.
I tested around a bit and was able to 'Authorize' the app (button at the top right of the Swagger page) with the credentials information that get spit out in the logs:
Basic auth configured with user broadleafapi and password: <<generated>>
then I was able to hit the API endpoints.
The changes you will need to make locally in your project to consume the fix are at https://github.com/BroadleafCommerce/DemoSite/commit/422d1cdc37f847afd8bec0be477ab784cbad2e9d#diff-991c59b6dbb0f619b8570d8f8779eaddR11. You will notice that I moved the original definition in default.properties over to common.properties and I recommend that you do the same. To be clear, follow these steps:
Delete the server.servlet.contextPath entry in `api/src/main/resources/runtime-properties/default.properties
Change server.servletPath in api/src/main/resources/runtime-properties/common.properties to server.servlet.contextPath
Thanks for trying out Broadleaf and the report, sorry for the rough early start!
I have an Orchard site with a SQL DB, when I try to access the site the following error happen:
Server Error in '/' Application.
None of the constructors found with 'Orchard.Environment.AutofacUtil.DynamicProxy2.ConstructorFinderWrapper' on type 'BodyLogic.Physicians.Services.PhysicianService' can be invoked with the available services and parameters: Cannot resolve parameter 'BodyLogic.LegacyDb.Services.Repositories.Physicians.IPhysicianRepository physicianRepository' of constructor 'Void .ctor(BodyLogic.LegacyDb.Services.Repositories.Physicians.IPhysicianRepository, BodyLogic.LegacyDb.Services.DtoConverters.IDtoConverter)'.
When I delete the "default" folder from App_Data/Sites/... and install a new Orchard everything runs perfectly, no exception and the modules are ok, but when I change the connection string to point to SQL Server again, the same exception happens again.
Any assistance in this matter will be highly appreciated,
Regards and thanks,
Alex.
It's not SQL Server that's causing the error, but corrupted data. There is a feature that should be enabled but is not. I bet it's this one: BodyLogic.LegacyDb.
You probably added a dependency to an already enabled feature, am I right? If so then what you see is the default behavior - Orchard won't auto enable the newly added dependency. You need to do that manually.
Feature enable/disable state is stored in the db table Settings_ShellFeatureStateRecord. To fix the error:
open it,
find a record with Name equal to BodyLogic.LegacyDb and
set both InstallState and EnableState values to Up
After you've done that
clear your App_Data/cache.dat,
restart the app pool and you're set.
What I've done is broken the default 'Version' service on my WSO2 DSS, I tried to set the Scopes variable for WS-Discovery and didn't put a closing tag/element when creating the parameter.
Now when I try to access the parameters screen I get an xml Parse error
TID: [0] [WSO2 Data Services Server] [2012-08-22 12:38:04,404] ERROR {org.wso2.carbon.service.mgt.ServiceAdmin} - Error occured while getting parameters of service : Version
{org.wso2.carbon.service.mgt.ServiceAdmin}org.apache.axiom.om.OMException: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '<' (code 60) in end tag Expected '>'. at [row,col {unknown-source}]: [2,58] at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:296) at
I'm assuming this is stored in the H2 database, I've tried looking for the parameter in the .db file using notepad but I can't find it.
Is there another way to connect/browse the H2 db?
I've scanned through the repository, database and conf directories for clues without success.
UPDATE:
Yes you can connect to the H2 db using the included database Explorer under the Tools menu.
Use the connection details found in the repository/conf/registry.xml file
Then you can do SQL queries on it - (I haven't found the answer yet though)
UPDATE 2:
I don't think the parameters are held in the H2 db, but I managed to fix my problem by:
downloading the Version.aar file using the link on the list services page
deleting the Version service
Copying the Version.aar file into the repository/deployment/server/axis2services dir
I guess deleting the service removed any records/references to my broken parameter
I believe you've tried setting service parameters via the UI? Usually the service parameters you specify via the UI do not get saved in the services.xml of the original axis2 service archive. Instead, they get saved in the registry that is shipped with DSS and get applied to the service at runtime. But if you specify a malformed parameter then wouldn't be saved in the registry instead, throwing an exception while trying to engage that parameter. So there'll be no record saved corresponding to that kind of malformed parameters.
Hope this helps!
Cheers,
Prabath