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

adding comments for splitting in two scripts #27

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions src/scicat_ingestor.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,21 @@ def main() -> None:
# Receive messages
for message in wrdn_messages(consumer, logger):
logger.info("Processing message: %s", message)

# check if we have received a WRDN message
# if message is not a WRDN, we get None back
if message:

# extract nexus file name from message

# extract job id from message

# saves the WRDN message in a file

# instantiate a new process and runs backeground ingestor
# on the nexus file

# check if we need to commit the individual message
if config.kafka_options.individual_message_commit:
consumer.commit(message=message)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Formatter is complaining about no-newline : D ...

Suggested change

Loading