-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Request for site_device_search_by_address in site.rb #35
Comments
It then allows for: device = nsc.site_device_by_address( 32, scan_asset_address) |
Might be faster to write it as an XPath. One question, what are you looking to be returned? As it stands, it would return an XML object. Would returning a parsed Nexpose::Device be good? (like what the device listing returns.) Or are you just looking for the device ID? I'm inclined to return a Device object, just to make it more generally useful. |
Here's a prototype that seems to be working:
|
Agreed a Device object would be very useful. From: Michael Daines notifications@github.com Might be faster to write it as an XPath. One question, what are you looking to be returned? As it stands, it would return an XML object. Would returning a parsed Nexpose::Device be good? (like what the device listing returns.) Or are you just looking for the device ID? I'm inclined to return a Device object, just to make it more generally useful. |
There was a bug in my XPath. I fixed it and also made sure that the site ID is correctly reported if not provided. Pushed in version 0.2.8 of the gem. |
As you are working the asset.rb search feature, would you consider this as a temporary solution in site.rb:
Please keep in mind that I would hope to have future changes made to eliminate the requirement to pull all site devices via the site_device_listing, especially for really large sites. We have a site with 200k devices. It would be great to pass the address filter all the way up through to the where clause in the sql select.
The text was updated successfully, but these errors were encountered: