IoT & Connectivity Tips | ThingWorx & Kepware PTC
Recently active
Scripto provides a RESTful endpoint for Groovy Custom Objects on the Axeda Platform. Custom Objects exposed via Scripto can be accessed via a GET or a POST, and the script will have access to request parameters or body contents. Any Custom Object of the "Action" type will automatically be exposed via Scripto. The URL for a Scripto service is currently defined by the name of the Custom Object:GET: http://{{YourHostName}}/services/v1/rest/Scripto/execute/<customObjectName> Scripto enables the creation of "Domain Specific Services". This allows implementers to take the Axeda Domain Objects (Assets, Models, DataItems, Alarms) and expose them via a service that models the real-world domain directly (trucks, ATMs, MRI Machines, sensor readings). This is especially useful when creating a domain-specific UI, or when integrating with another application that will push or pull data.AuthenticationThere are several ways to test your Scripto scripts, as well as several different authent
In the recent times, one of the frequent questions regarding PostgreSQL is which tools are good with PostgreSQL. With the growing functionality of PostgreSQL, the number of vendors are willing to produce tools for PostgreSQL. There are lot of tools for management, development, data visualization and the list if growing. Here, I'm listing a few tools that might be of interest to Thingworx users.psql terminal: The psql client is a command-line client distributed with PostgreSQL, often called as interactive terminal. psql is a simple yet powerful tool with which you can directly interface with the PostgreSQL server. The psql client comes default with the PostgreSQL database. Key features: Issue queries either through commands or from a file. Provides shell-like features to automate tasks. For more information, refer http://www.postgresql.org/docs/9.5/static/app-psql.htmlpgAdmin III:pgAdmin III is a GUI based administration and development tool for PostgreSQL database. It delivers the nee
From the documentation, a SOLR node is only needed in case of using DataTables. If the SOLR configuration field left blank, the extension will request to provide an input. Are SOLR nodes required or optional in order to use DSE with TW (in the hypothetical case of not using DataTables)? -- As for functionality of the Thingworx, a Solr node is not required. However, the extension does try to validate the configuration, and hence, at this point, a SOLR node is mandatory to properly configure the extension. This will be fixed in the future.When there are 2 entries for addresses, one for a Cassandra Cluster and one for a Solr Cluster, are they the same Cluster, or different Clusters? -- They could be either. There can be one machine with SOLR enabled and using the same IP for both Cassandra and Solr. However, it's not recommend for production workloads. It would be perfectly fine for development or test environments.In a Cluster, in ord
The purpose of this post is to provide some ideas and help diagnosing issues in mashup. First, check if the problem occurs at mashup runtime or in design(edit) mode.Runtime: Is the issue visual or related to improper service execution? (e.g, "my data is displaying correctly but the styling or formatting is wrong" -- visual, "my data is displayed incorrectly but the styling and formatting is right" -- improper service execution)For visual/styling/formatting issues, return to the edit mode of mashup, and ensure the proper style definitions were set up.Ensure the logic behind the connections is correct.Check configuration of the widget(s) involved.Were there any changes made to the styles after the mashup was saved and run the first time? If so, try - clearing the browser cache; -reconnecting the dependent entity with the style involved in the issue.If the problem persists, contact technical support to raise a cosmetic defect ticket.For improper service execution, return to the comp
This document provides API information for all 51.0 releases of ThingWorx Machine Learning.
PostgreSQL is a powerful, open source object-relational database system that provides unlimited database size. Thingworx 6.5 introduces PostgreSQL as persistence provider and supports High Availability. Main advantages with Thingworx Postgres are1. Highly customizablePostgreSQL also includes a framework that allows developers to define and create their own custom data types along with supporting functions and operators that define their behavior. Triggers and stored procedures can be written in C and loaded into the database as a library, allowing great flexibility in extending its capabilities.2. Synchronous replicationPostgreSQL streaming replication is asynchronous by default. Synchronous replication offers the ability to confirm that all changes made by a transaction have been transferred to one synchronous standby server. This extends the standard level of durability offered by a transaction commit. The only possibility that data can be lost is if both the primary and the standby
Here are some tips on how to submit a ticket to the ThingWorx technical support team and what to expect. Providing a typical minimum information is always a good practice to lessen the questions and unnecessary back-and-forth communication prior to the actual investigation of the problem. Open a new ticket for each separate issue. We do track every technical issue that comes in.If the ticket is being submitted for troubleshooting:Please provide the versions of Thingworx, Tomcat, java; Operating System and specs.Attach the list of the extensions used.Include a detailed description of the problem; if applicable, include the screenshots.Evaluate the business impact caused by the issue.Optional: state the method of contact preference, whether it's a phone or email, and time if applicable.Expect a support engineer (SE) to establish the first contact via email, letting known of the case ownership, and further investigation.If the ticket is being submitted for enhancement request or improveme
Hello Developer Community,We are pleased to announce pre-release availability of the ThingWorx Edge SDK for Android!The Android SDK beta is built off the Java SDK code base, but replaces the Netty websocket client with Autobahn for compatibility with Android OS. Those familiar with the Java SDK API will feel very much at home in the Android SDK. We recommend beginning with the included sample application. Please watch this thread for upcoming beta releases. b4 adds file transfers between the ThingWorx platform and Android devices and an example application.We welcome your questions and comments in the thread below! Happy coding!Regards,ThingWorx Edge Products Team
Every edge component that connects to the ThingWorx platform requires an Application Key. This 'AppKey' provides both authentication and authorization control. When an edge component connects it steps through a connection process. The second step of that process is to send the AppKey to the platform. The platform will inspect the key and ensure that it is valid. It also creates a session for that edge connection and associates the AppKey with the session. Any future requests that are sent over that AlwaysOn connection will execute under the security context configured for the user associated with the AppKey.In order for edge applications to interact with the platform they require a certain set of permissions. It is a best practice to not associate the Administrator user with an Application Key. Doing this would allow an edge application to invoke any and all services on the platform, and to modify the property values of any thing. T
Everywhere in the Thingworx Platform (even the edge and extensions) you see the data structure called InfoTables. What are they? They are used to return data from services, map values in mashup and move information around the platform. What they are is very simple, how they are setup and used is also simple but there are a lot of ways to manipulate them. Simply put InfoTables are JSON data, that is all. However they use a standard structure that the platform can recognize and use.There are two peices to an InfoTable, the DataShape definition and the rows array. The DataShape is the definition of each row value in the rows array. This is not accessible directly in service code but there are function and structures to manipulate it in services if needed.Example InfoTable Definitions and Values:{ dataShape: { fieldDefinitions : { name: "ColOneName", baseType: "STRING" &n
A while back, when I was learning about the ThingWorx platform, I could not find any good description of how InfoTables worked so I reverse engineered everything I could about them from a javascript perspective and wrote a short paper that I think is still of use today so I posted a copy here. It discusses what role InfoTables have as a ThingWorx primitive for passing data to and from ThingWorx and some of the lesser known capabilities that the data structure itself has built in. Here is a link to it Getting to Know InfoTables.pdf .
When using the Auto-bind section of an EMS configuration it is very important to note the difference between "gateway":true and "gateway":false. Using either gateway value, when used with a valid "name" field, will result in the EMS attempting to bind the Thing with the ThingWorx platform, and will allow the EMS to respond to file transfer and tunnel services related to the auto-bound things, but this is around where the similarities end.Non-Gateway:This type of auto-bound thing can be thought of as a placeholder because the EMS will still require a LuaScriptResource to be bound in order to respond to property/service/event related messages.There must be a corresponding Thing based on the RemoteThing template (or any RemoteThing derived template e.g. RemoteThingWithFileTransfer) on the ThingWorx server in order for the bind to succeed.There are many reasons to use this type of auto-bound thing, but the most common is to bind a simple thing that can facilitate file transfer and tunnel s
Developing with Axeda Artisan(for Axeda Platform, v6.8 and later)Axeda Artisan is a development tool based on the Apache Maven build system. Artisan includes authoring, management, and deployment mechanisms that define and manage the development of Axeda Platform extension points, allowing you to flexibly install, update, and uninstall many types of objects on the Axeda Platform.The Components of ArtisanThe Artisan framework is comprised of several components:The Axeda PlatformEach instance of the Axeda Platform contains libraries and sample Artisan Projects (archetypes) that are downloaded by developers to author and deploy their own Artisan Projects.The Artisan ProjectAn Artisan Project is a collection of content and configuration files that are used to define a set of objects that will be installed on the Axeda Platform.The Artisan InstallerThe Artisan Installer is a flexible, configurable application that uses the Apache Maven build life-cycle to upload the contents of an Artisan P
Axeda Machine Streams enables external Platform integrators to access the current, raw data from connected assets. The Platform can stream the data item, alarm, mobile location, and registration messages from connected assets to an ActiveMQ server or Azure Service Bus endpoint. Streamed data can be used for data analytics or reporting, or simply for storage.This article explains the Machine Streams Data Relay project that Axeda provides. This sample project illustrates how stream consumers can create their own projects to relay Machine Stream messages from ActiveMQ or Azure Service Bus into their environments.The Machine Streams Data Relay project was created using Apache Maven. The project operates by dispatching messages to a log message processor. Each machine streams message is logged to stdout.Note: The "Axeda Features Guide" provides a high level introduction to the Axeda Machine Streams feature. That PDF is available from PTC Support (http://support.ptc.com/).)Downloading and In
Complete information about installing and using the Axeda Machine Streams Data Relay Project is available here.This page provides the files for Axeda Machine Streams Data Relay Project:For Linux usersready to run (bin) files: download the machine-streams-data-relay-1.0.3-bin.tar_.gz archivefull Maven project files: download the machine-streams-data-relay-1.0.3-project.tar_.gz archiveFor Windows usersready to run (bin) files: download the machine-streams-data-relay-1.0.3-bin.zip archivefull Maven project files: download the machine-streams-data-relay-1.0.3-project.zip archiveFrom the links below, select the project you want to use.
Joint Study by Cognizant and the Economist Intelligence Unit (EIU) -Making products smart can deliver game-changing innovation,enriched customer experiences and new, across-the board levels of efficiency. From R&D and manufacturing, through distribution and after-sales support, product data is changing how products are built, sold and cared for. Our latest research reveals practical steps business leaders can take to benefit from this quickly intensifying and accelerating trend.
One of the signature features of the Axeda Platform is our alarm notification, signalling and auditing capabilities. Our dashboard offers a simplified view into assets that are in an alarm state, and provides interaction between devices and operators. For some customers the dashboard may be too extensive for their application needs. The Axeda Platform from versions 6.6 onward provide a number of ways of interacting with Alarms to allow you to present this data to remote clients (Android, iOS, etc.) or to build extended business logic around alarm processing.If one were to create a remote management application for Android, for example, there are the REST APIs available to interact with Assets and Alarms. For aggregate operations where network traffic and round-trip time can be a concern, we have our Scripto API also available that allows you to use the Custom Object functionality to deliver information on many different aggregating criteria, and allow deve
Background: In the event that a Gateway/Connector Agent is offline or unable to connect to the Axeda Cloud Server, it uses an internal message queue to store information until the connection is restored. The message queue size is configured in the Axeda Builder project.By default, the queue is 200KB in size. Depending on how frequently your Agent sends data or how much data your Agent is collecting and trying to send, 200KB may be too small. If the queue is too small, the data will “overflow” the queue. The queue is kept in memory only; data is not stored to disk and will be removed in a First-In-First-Out (FIFO) manner when the queue overflows. If you see queue overflow error messages in the Agent log (either EKernel.log and xGate.log), it may be time to change the size of the outbound message queue.The correct size setting for the Agent outbound message queue takes three variables into consideration:How much information you are sending?What is the maximum expected duration for
Background: Firewall-Friendly Agents can be configured for server certificate authentication in the Axeda Builder project or via the Axeda Deployment Utility. When server certificate authentication is configured, the Agent will compare the certificate chain sent by the Platform to a local copy of the CA certificate chain stored in the SSLCACert.pem file in the Agent’s home directory.The certificate validation compares three things:Does the name of the Platform certificate match the name in the request?Does the CA certificate match the CA certificate that signed the Platform certificate?Is the Platform or CA certificate not expired?If the answer to any of these questions is “no”, then connection is refused and the Agent does not communicate further with the Platform. To determine if certificate trouble is an issue, see the Agent log: EKernel.log or xGate.log.Recommendation: For Agent-Platform communications, we recommend always using SSL/HTTPS. If the Agent is not configured to validate
Background: Axeda Agents can be configured with standard drivers to collect event-driven data, which is then sent to the Platform. Axeda provides many standard event-driven data (EDD) drivers for use with the Axeda Agent (as explained in Axeda® Agents EDD Toolkit Reference (PDF)). All EDD drivers are configured by an xml file and enabled in Axeda Builder, through the Agent Data Items configuration.You can configure an EDD driver to send important information from your process to the Agent, including data items, events and alarms. The manner in which you configure your drivers will affect the ability for your project to operate efficiently.Recommendation: Use drivers to reduce the amount of data sent to the platform.Instead of sending data items to the Platform, which then generates an event or alarm, it is possible to use the drivers to scan for specificdata points or conditions and send an event or alarm. Before you can configure your agents, you first need to determine how ofte
Background: The frequency with which an Agent checks its connection to the Axeda Cloud Server is called the Agent “ping rate” (also known as heartbeat). (For Axeda IDM Agents, ping rate is referred to as “poll rate”; the meaning is the same.)Pings are a very important aspect of Firewall-Friendly communication. All communication between the Agent and the Cloud Server is initiated by the Agent. In addition to indicating the Agent is still active, the Ping also gives the Cloud Server an opportunity to send commands back to the Agent on the Ping acknowledgement.The ping rate effectively defines how long users must wait before they can deliver a command or request to an Agent. Typical commands may include setting a data item, starting an Access Session, or running a script.The place where Ping rate is most noticeable to system users is when requesting a remote session. When a session request has been submitted by the user, the Cloud Server waits for the next Agent ping in order to send down
Background: In very rare situations, it is possible that the Firewall-Friendly Agent process may stop running. If the Agent is not running, no machine monitoring or communication with the Cloud Server is possible.Recommendation: WatchDog is a little known yet very helpful feature available with Firewall-Friendly Agents. This program lets you monitor whether an Agent is running; if it’s not running, WatchDog can restart that Agent if needed. If the Agent process fails, WatchDog can bring it back up!WatchDog can also be configured to watch other processes. You can configure WatchDog to run as a service (for Windows) or daemon (for Linux).You will register the Watchdog to run as a service. The Watchdog configuration file will specify the process(es) to be monitored and what to do when one exits. The options are to attempt to restart the process or to restart the system.Note: Watchdog detects only if a watched process exits. It will not detect or report on processes that may be “hang
Background: Customer machines create files containing data, configuration, log data, etc. These files may contain critical information for service technicians about the asset and its data. How can you make sure you get this important information to the Cloud as soon as it’s available?Use File Watcher, a standard tool available with Firewall-Friendly Agents. You can configure File Watcher to monitor a directory or file specification and automatically upload the file(s) to the Axeda Cloud. By monitoring selected directories and files on the device, the File Watcher determines which files have changed or appeared and then upload those files to the Axeda Cloud Server.Sometimes the size of the file being written or copied into the file watch target is large enough that it takes time to complete. Without taking the right precautions, the file upload may try to start before the file creation process is completed.Recommendations: To ensure that large files don’t cause problems, we recommend us
Remember that when you are calling an external URL to fetch data via an API call to another system that you must encode special characters specifically. For example the URL that you may type into a browser to test may look like this:https://someserver.somwhere.com:443/apicall?parameter1=test string&parameter2=test^numberbut when scripting that into a string variable you'll need to replace the space and the carrot with the proper encoded values (%20 and %5E)var params = {username : "me",password : "password",url : "https://someserver.somwhere.com:443/apicall?parameter1=test%20string&parameter2=test%5Enumber",ignoreSSLErrors : false,timeout : 60,headers : headers};var result = Resources['ContentLoaderFunctions'].LoadXML(params);also note that in this instance we're making a secure connection therefore port 443 (typically the default) was explicitly specified...
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.