I am struggling here and it may very well be a simple fix...
I was successfully able to add the Monitor extension following the documentation! However, when I go to make a new custom CI modifying that, it does not show in the drop down menu for new CI, nor does it show in the overview. actually in the overview i get an error (attached image)
Nothing else is customized outside of this section, but I will upload them just in case.
When reviewing the monitor one, it seemed that the later refence in the menu translated to a display name to me (they used Monitor, instead of monitor). Maybe capitalization doesn't matter? I will attempt to have them match.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Unsure what you are asking. The DUO module i made was with the tool iTop provides. So it was just blank made from when I entered the DUO name and dependencies. Looking through i see nothing more than labels that were auto generated in them, (i have my file above if you wanted to double check)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
In the module descriptor file, it is the second argument in the \ModuleDiscovery::AddModule call.
For example in the backup embedded module, in datamodels/2.x/itop-backup/module.itop-backup.php, the module code is located in the 'itop-backup/3.0.0' string, it is itop-backup.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This is still not clear to me. The only major changes between my file and the Monitor sample is that i changed the name from sample add class to Duo Token Module, and then changed names from monitor to DUOToken in the xml. (i published updated versions on a comment below).
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Is your extension visible when you click the "power" button (top right in iTop) and check the support details (you'll see all extensions/modules listed there)?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
As a hypothetical. Does anyone have a simple non monitor example they could upload and I could test seeing it I can add that? Trying to isolate the why.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The error in the itop interface on Untitled.png you've attached clearly says what is wrong: DBObjectSearch::construct called for an invalid class :"DUO" means that you have created class with the name <class id="DUO Token">, but you want to see a dashlet for a class <class>DUO</class> in Configuration Management Overview which iTop could not find.
You should call <class>DUO Token</class> in dashlets section inside menu section of your datamodel.xml extension.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
As long as you have extension installed, i.e. new class of CI created, added to DB you should be able to create New CI of that type and Search for CI of that type under Configuration Management Menu.
You also should be able to manually add dashlet of that new CI onto Configuration Management Overview via Edit This Page button.
Last edit: Anton Kuznetsov 2021-01-20
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Right but the original issue is that it does not show in the drop down under the current configuration. That is my problem. The dashlet is a side issue that I believe will be resolved with the change. But that still does not explain why it does not show in the drop down menu when i go to create a new CI.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Ok, got that about dashlet.
Before you post dashlet into Configuration Management Menu you must add your new class into Model field which contains list with classes in order for it to show there and work as it is supposed to:
I made the change like you state. However I am still getting the same error. I have tried with spaces, without spaces, an even "black text" having spaces and "red text" without....
I am struggling here and it may very well be a simple fix...
I was successfully able to add the Monitor extension following the documentation! However, when I go to make a new custom CI modifying that, it does not show in the drop down menu for new CI, nor does it show in the overview. actually in the overview i get an error (attached image)
Here is my XML:
Last edit: R Desrosiers 2021-01-13
Can you share the entire extension? Also, it's advised not to use spaces in "id" . Rather make it DuoToken.
Within the menu node tag, you also suddenly seem to refer to DUO instead?
Nothing else is customized outside of this section, but I will upload them just in case.
When reviewing the monitor one, it seemed that the later refence in the menu translated to a display name to me (they used Monitor, instead of monitor). Maybe capitalization doesn't matter? I will attempt to have them match.
I have changed it to DUOToken in both locations, but still have the same result.
Is your module.*.php file containing a unique identifier ? Or have you got bit the Monitor and custom class modules having the same code ?
Unsure what you are asking. The DUO module i made was with the tool iTop provides. So it was just blank made from when I entered the DUO name and dependencies. Looking through i see nothing more than labels that were auto generated in them, (i have my file above if you wanted to double check)
In the module creation form, the module identifier is the "Module name" field.
In the module descriptor file, it is the second argument in the \ModuleDiscovery::AddModule call.
For example in the backup embedded module, in datamodels/2.x/itop-backup/module.itop-backup.php, the module code is located in the
'itop-backup/3.0.0'
string, it isitop-backup
.This is still not clear to me. The only major changes between my file and the Monitor sample is that i changed the name from sample add class to Duo Token Module, and then changed names from monitor to DUOToken in the xml. (i published updated versions on a comment below).
Is your extension visible when you click the "power" button (top right in iTop) and check the support details (you'll see all extensions/modules listed there)?
It does appear to be. Snip attached.
OK. Have you tried to write the class ID without a space? So id="DuoToken" ?
Yes, in the replies above I uploaded the updated XML with the space removed, same result.
I have this in a test environment and use snapshots to cleanly redo it each time.
Any other thoughts?
As a hypothetical. Does anyone have a simple non monitor example they could upload and I could test seeing it I can add that? Trying to isolate the why.
Hi, R Desrosiers!
The error in the itop interface on Untitled.png you've attached clearly says what is wrong: DBObjectSearch::construct called for an invalid class :"DUO" means that you have created class with the name
<class id="DUO Token">
, but you want to see a dashlet for a class<class>DUO</class>
in Configuration Management Overview which iTop could not find.You should call
<class>DUO Token</class>
in dashlets section inside menu section of your datamodel.xml extension.That makes sense for the dashlet and will attempt that fix. However that wouldn't effect it showing in the list of new CIs though right?
As long as you have extension installed, i.e. new class of CI created, added to DB you should be able to create New CI of that type and Search for CI of that type under Configuration Management Menu.
You also should be able to manually add dashlet of that new CI onto Configuration Management Overview via Edit This Page button.
Last edit: Anton Kuznetsov 2021-01-20
Right but the original issue is that it does not show in the drop down under the current configuration. That is my problem. The dashlet is a side issue that I believe will be resolved with the change. But that still does not explain why it does not show in the drop down menu when i go to create a new CI.
Ok, got that about dashlet.
Before you post dashlet into Configuration Management Menu you must add your new class into Model field which contains list with classes in order for it to show there and work as it is supposed to:
Just as it's described in tutorial.
Last edit: Anton Kuznetsov 2021-01-20
I made the change like you state. However I am still getting the same error. I have tried with spaces, without spaces, an even "black text" having spaces and "red text" without....
Here are the latest files.
Oh, I've just see that your class id attribute has the
DUO Token
value... Try to remove this space !A few posts above I did update the xml with this change, and had the same result.
Oh ok sorry
Are you referring to this post ?
Yeah that one. In there I removed the space.
Any chance you have a working custom End user module that i can try and compare?