Ah, that is certainly a separate issue. Hopefully, you figure out what's causing that or somebody has ideas, but I've not seen random recompiles personally.
- Log in to post comments
Ah, that is certainly a separate issue. Hopefully, you figure out what's causing that or somebody has ideas, but I've not seen random recompiles personally.
Hello Brian,
It is interesting to know that this might be implemented at some point.
My first thought is to recommend not compiling a running production, though I understand that's not "helpful" advice. When you compile a business component it should be stopped, and I assume similar best practices apply to compiling a production.
Can you explain why the production needs to be recompiled while active? Maybe that will help somebody present a workaround.
Hello Lawrence,
Screen is certainly an option (and doesn't require more than installing and running ^DBREST per your normal steps), but there is also the built-in function of:
Unattended Restore Using ^DBREST
EXTALL^DBREST and EXTSELECT^DBREST.
Hello T,
Some settings such as AlertOnError aren't in Ens.Config.Item but are stored in the production definition class.
edit: see my comment below, these settings are in the production definition, but you seem to be able to modify them using Ens.Config.Item as well.
Perhaps you could use the System Default Setting?
For something like this, especially with urgency, I'd recommend reaching out to your InterSystems rep or the WRC.
Actually, I'm seeing that I can find the InactivityTimeout setting (for example) and modify it using Ens.Config.Item. I'm not sure where exactly your problem is coming from.
I agree that Danny's suggestion to review where your licenses are being used is a good starting point.
Since you mention using this license across multiple servers, I would consider the different ways your developers are connecting to Caché. If a developer has Studio, the management portal, and a terminal session open, they are probably using more than 1 license. Even with a limit of 2 developers per server, if 6 developers are on the 3 servers connecting multiple ways, you could surpass a 10 user limit.
You may need a more robust license to support your team's usage patterns.
Hello T,
I see that Kurro has already provided some samples but you are still waiting on the first question.
I'm not sure if my understanding of your desire is correct, but individual rules in a routing rule are a part of the overarching rule class. While it is technically possible to programmatically edit a class, my personal feeling is that this approach feels more complicated than necessary. To make changes to individual rules it might make more sense to use a source control solution and deploy the version of the rule class that has the rules that you want.
Another benefit of the source control methodology is that to make changes in prod, rather than editing production code in a live system, you would be choosing between deployment of (hopefully) tested versions of the rule.
Hello Andre,
Take a look at these two other posts with very similar questions, maybe you can find something that works for you. Unfortunately, there doesn't seem to be a built-in random function on the SQL side (though on the Objectscript side there is $RANDOM.)
https://community.intersystems.com/post/how-select-random-row-table
https://community.intersystems.com/post/custom-query-returns-random-number-columns
Hello again Fábio,
These errors are one part of the picture. It would probably be beneficial to open a ticket with the WRC so they can look into these errors and your performance issues to see if they are related/separate.
Do you know what queries are triggering these errors? w3wp.exe is an IIS process but I'm not familiar with EXTRService.exe or KIORAS. Perhaps the IP addresses can also help you narrow down the source.
The <READ> errors indicate something like a problem reading from the socket, but that doesn't explain the cause. There may be other logs you can review in your environment to help explain this.
To add-on to my initial post, I do think that if you use the same type of outbound adapter and inbound adapter (ie counted), it would be expected for the message to be accepted. Since you're sending XML I wonder why the operation isn't using the counted XML adapter. Hopefully, somebody with expertise in this area can help you.
Hello Sai,
You might need to give more details on what your operation/service code looks like to determine what's going on. The WRC or your InterSystems rep could probably help with this.
The TCP adapter (including counted) docs can be found here. There are similar docs for the outbound, but it's pretty much the same but swapped for outbound:
Overview of Inbound TCP Adapter
"EnsLib.TCP.CountedInboundAdapter supports incoming TCP connections over which a TCP client and TCP listener exchange blocks of data, with the block length specified in the first 4 bytes of the block. The adapter uses the block length to acquire the meaningful portion of the data from the client application."
The above doc page also includes some guidance for setting up a TCP service.
Is there a particular reason you are using a Counted operation/service rather than generic TCP? I'm unfamiliar with the use case for the Counted adapters.
The above suggests that the counted adapters are meant for handling "counted data blocks".
The error you are getting seems to indicate a mismatch between the block size being sent, and the expected size. Looking at the traffic in a Wireshark could be helpful to understand what is happening.
Hello Fábio,
I'm just quoting the class reference I linked:
"This method is called to remove data from the %SYS.PTools.SQLStats table. It does not remove data from %SYS_PTools.SQLQuery, those rows are cleaned up when a query is compiled"
You can take a look at what's actually filling up your CACHE database to determine if this will work for you. For a complete purging, I'd go with purging cached queries, as that's the "full" solution.
Hello Fábio,
In IRIS there is a convenient SQL Runtime Statistics page where you can purge those stats.
Using the SQL Runtime Statistics Tool
On your version, the equivalent tool only offers the option to purge cached queries, so I think that's what you'll need to do. %SYS.PTools.SQLStats.Purge will purge some of the SQL stats data, though not all.
"Purging a cached query purges any related SQL Stats data. Dropping a table or view purges any related SQL Stats data."
edit: corrected, CE 2018.1.5 does not have the purge stats option that IRIS does.
Hello Alex,
Have you confirmed that the original transaction process goes away when the VPN disconnects? How are you opening the terminal in the first place?
If disconnecting the VPN leaves the original process around, it won't have a chance to rollback the transaction.
edit: perhaps this is related to your Journal Freeze on error setting?
Hello Kevin,
I'm not very familiar with 3rd party tools that could be good for this (I'm sure they exist), but you should be able to design a Caché-role that has the restrictions you are looking for. I think you should be able to use SQL and portal permissions to lock down a role to your specifications.
Hello Eudoro,
It sounds like you may be able to leverage mirroring, which is built-in and is an IRIS functionality where separate instances of IRIS can automatically transfer journal files to synchronize their copies of a database. Docs here:
Rico,
WRC stands for Worldwide Response Center and is short for InterSystems Support.
Ah, that might be because you are on a base version of 2017.1, but it was added in a maintenance release (perhaps 2017.1.3)? I tried to find some documentation on that but it wasn't super obvious to me. I'd definitely recommend upgrading if possible.
Hello Michael,
I tested this in terminal calling ##class(Ens.Util.FunctionSet).CurrentDateTime(), and I can't see a reason why you couldn't use a variable in this function. You'd need to concatenate your variable into the time format string, ex:
..CurrentDateTime("%K("_tDstOffSet_")%q")
Let me know if that works for you.
Hello Virginia, this isn't directly related to your question, but consider using zf(-100) as zf(-1) is deprecated. 2017.1 docs here:
$ZF(-100)
"$ZF(-100) provides similar functionality to $ZF(-1) and $ZF(-2). Its use is preferable to $ZF(-1) or $ZF(-2), which are both deprecated functions."
Hello Abed,
What permissions do you have exactly for cstop, the database directories / cache.lck, and the contents of the bin directory?
Perhaps the Unix permissions docs would be helpful:
UNIX® Users, Groups and Permissions
Also, can you try using "ccontrol stop" rather than calling cstop directly?
Hello Adrian,
Some people already talked about the system mode for the portal, but John (one of your commenters) previously wrote a different post about adding information to the terminal prompt itself which may be useful as well:
https://community.intersystems.com/post/where-am-i-adding-extra-information-terminal-prompt
There's a documentation link on that page, but you can have your terminal be prefixed by host name or instance name, for example.
Hello Michael,
What is your current CurrentDateTime call and are you familiar with the syntax for setting the format? What is missing or needs to change in your current result?
Sorry Chip, I'm afraid you're out of luck. On Unix there's "iris rename" but this doesn't work on Windows because of registry stuff.
To rename an instance on Windows you'll have to migrate.
Re: mirroring HSSYS (or other system / library databases), please make sure you review the documentation for the product you are using specifically. Documentation for older versions of HealthShare Information Exchange's documentation is not available online, but in recent versions HSSYS can and should be mirrored.
Example from HS 2018.1 docs:
Mirroring a New Information Exchange
"Now that you have created the mirror, you can mirror the databases. For a new installation, you only have to mirror one database, HSSYS. When you configure Information Exchange using the Installer Wizard (or an installer script), all of the databases that are created in that process will then be automatically mirrored."
Hello Augusto,
Please check out the mirroring documentation, which is quite robust. After joining your async to the mirror you will need to sync the databases.
"Only a local database on the current primary failover member can be added to a mirror; it is added on the primary first, then on the backup, and then on any desired async members. All mirrored databases must be journaled.
You must add the same set of mirrored databases to both the primary and backup failover members, as well as to any DR async members; which mirrored databases you add to reporting async members depends on your reporting needs. "
Add an Existing Database to the Mirror
This documentation covers some ways of syncing a database from the primary to the other members.
Hope that helps!
Piggybacking on Dmitry's comment, here's the documentation for:
"For most data types, the three SelectMode modes return the same results. The following data types are affected by the SelectMode option:
Date, Time, and Timestamp data types. InterSystems SQL supports numerous Date, Time, and Timestamp data types (%Library.Date, %Library.Time, %Library.PosixTime, %Library.TimeStamp, and %MV.Date). With the exception of %Library.TimeStamp, these data types use different representations for Logical, Display, and ODBC modes."
Hello Cedric,
Aside from Dmitry's suggestion, you could add some debugging to check what namespace you are in right before your operation calls the query. What namespace do you have that would return 1875 rows for that query, if that namespace exists at all?
If you rule that out, you could reach out to the WRC to investigate.
Martin,
This makes sense to me. Access to databases is controlled by that database resource setting, which can be customized and assigned to various roles. A role that is assigned %DB_%DEFAULT access will grant access to any databases that are controlled by that resource.
If you are concerned, you could review the other databases and make sure that you want your user to have access to the other databases secured by %DB_%DEFAULT. If you wanted more restriction, you could assign your databases a different resource other than %DB_%DEFAULT, such as having specific database resources for each database. That way, you only grant permissions for 1 specific database when granting the custom resource.
See documentation here:
Hope that helps.
Hello Martin,
The <PROTECT> error is on the UKERALL database so I would start there. The first thing that comes to mind for me is whether that database has a different resource securing it, as under the "Roles" list I don't necessarily see a role that seems to correspond to that database exactly. This is dependent on how your roles and database resources are configured.
Does your admin user have %ALL or some subset of permissions? If not %ALL, you could try comparing the admin user's permissions to the user getting the error here.