Skip to content

Commit

Permalink
Add atomic port locking mechanism
Browse files Browse the repository at this point in the history
  • Loading branch information
xDaile committed Jun 11, 2024
1 parent e33e29e commit e1393a2
Show file tree
Hide file tree
Showing 3 changed files with 529 additions and 102 deletions.
10 changes: 7 additions & 3 deletions iib/workers/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import logging
import shutil
import types
from typing import Any, Dict, List, Optional, Type, Union
from typing import Any, Dict, List, Optional, Tuple, Type, Union

from kombu import Queue
from celery import Celery, app
Expand Down Expand Up @@ -34,9 +34,13 @@ class Config(object):
)
iib_greenwave_url: Optional[str] = None
iib_grpc_init_wait_time: int = 100
iib_grpc_max_port_tries: int = 100
iib_grpc_max_tries: int = 5
iib_grpc_start_port: int = 50051
# size of both ranges, needs to be the same, ranges neeeds to be exclusive
iib_opm_port_ranges: Dict[str, Tuple[int, int]] = {
"opm_port": (50051, 50151),
"opm_pprof_port": (50151, 50251),
}
iib_opm_pprof_lock_required_min_version = "1.29.0"
iib_image_push_template: str = '{registry}/iib-build:{request_id}'
iib_index_image_output_registry: Optional[str] = None
iib_log_level: str = 'INFO'
Expand Down
Loading

0 comments on commit e1393a2

Please sign in to comment.