Skip to content
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

Onvif discovery Handler incorrectly filter ip address #597

Closed
johnsonshih opened this issue May 2, 2023 · 2 comments · Fixed by #604
Closed

Onvif discovery Handler incorrectly filter ip address #597

johnsonshih opened this issue May 2, 2023 · 2 comments · Fixed by #604
Assignees
Labels
bug Something isn't working

Comments

@johnsonshih
Copy link
Contributor

johnsonshih commented May 2, 2023

Describe the bug
A clear and concise description of what the bug is.
set filter ip address to exclude 10.0.0.1 will end up filtering all ip addresses start with 10.0.0.1, including 10.0.0.1xx.

To Reproduce
Steps to reproduce the behavior:

  1. Create cluster
  2. Install Akri with the Helm command and deploy the Akri Configuration yaml modified from test/yaml/akri-onvif-video-configuration.yaml (see below). In the configuration, only exclude cameras with ip address 10.0.0.1, 10.0.0.2.
  3. My Onvif camera ip is 10.0.0.107, after deploying the Configuration, my camera is not detected.

apiVersion: akri.sh/v0
kind: Configuration
metadata:
name: akri-onvif-video
spec:
discoveryHandler:
name: onvif
discoveryDetails: |+
ipAddresses:
action: Exclude
items:
- 10.0.0.1
- 10.0.0.2
macAddresses:
action: Exclude
items: []
scopes:
action: Exclude
items: []
discoveryTimeoutSeconds: 2
brokerSpec:
brokerPodSpec:
containers:
- name: akri-onvif-video-broker
image: "ghcr.io/project-akri/akri/onvif-video-broker:latest-dev"
imagePullPolicy: Always
resources:
limits:
"{{PLACEHOLDER}}" : "1"
instanceServiceSpec:
ports:
- name: grpc
port: 80
targetPort: 8083
configurationServiceSpec:
ports:
- name: grpc
port: 80
targetPort: 8083
brokerProperties: {}

Expected behavior
Onvif camera ip address 10.0.0.107 discovered.
Onvif discovery handler should only filter out 10.0.0.1 and 10.0.0.2, not others.

@johnsonshih johnsonshih added the bug Something isn't working label May 2, 2023
@jbpaux jbpaux mentioned this issue May 15, 2023
8 tasks
@johnsonshih johnsonshih reopened this Jun 15, 2023
@johnsonshih
Copy link
Contributor Author

The fix causes wrong behavior when filtering scopes.

@johnsonshih johnsonshih mentioned this issue Jun 15, 2023
8 tasks
@johnsonshih
Copy link
Contributor Author

verify the issue is fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant