Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
theodolite
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Sören Henning
theodolite
Commits
ed51b544
Commit
ed51b544
authored
4 years ago
by
Björn Vonheiden
Browse files
Options
Downloads
Patches
Plain Diff
enchance topic deletion in run uc py
parent
34ef183a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!42
Integerate theodolite and run uc python scripts
,
!24
run UC as python implementation
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
execution/run_uc.py
+4
-2
4 additions, 2 deletions
execution/run_uc.py
with
4 additions
and
2 deletions
execution/run_uc.py
+
4
−
2
View file @
ed51b544
...
...
@@ -325,11 +325,13 @@ def delete_topics(topics):
"""
print
(
'
Delete topics from Kafka
'
)
topics_delete
=
'
theodolite-.*|
'
+
'
|
'
.
join
([
ti
[
0
]
for
ti
in
topics
])
num_topics_command
=
[
'
/bin/sh
'
,
'
-c
'
,
f
'
kafka-topics --zookeeper my-confluent-cp-zookeeper:2181 --list
\
| sed -n -E
"
/^(
theodolite-.*|input|output|configuration
)
\
| sed -n -E
"
/^(
{
topics_delete
}
)
\
( - marked for deletion)?$/p
"
| wc -l
'
]
...
...
@@ -337,7 +339,7 @@ def delete_topics(topics):
'
/bin/sh
'
,
'
-c
'
,
f
'
kafka-topics --zookeeper my-confluent-cp-zookeeper:2181 --delete
\
--topic
"
input|output|configuration|theodolite-.*
"'
--topic
"
{
topics_delete
}
"'
]
# Wait that topics get deleted
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment