@classmethod<EOL><INDENT>@provide_session<EOL>def get_many(cls,<EOL>execution_date,<EOL>key=None,<EOL>task_ids=None,<EOL>dag_ids=None,<EOL>include_prior_dates=False,<EOL>limit=<NUM_LIT:100>,<EOL>session=None):<DEDENT>
filters = []<EOL>if key:<EOL><INDENT>filters.append(cls.key == key)<EOL><DEDENT>if task_ids:<EOL><INDENT>filters.append(cls.task_id.in_(as_tuple(task_ids)))<EOL><DEDENT>if dag_ids:<EOL><INDENT>filters.append(cls.dag_id.in_(as_tuple(dag_ids)))<EOL><DEDENT>if include_prior_dates:<EOL><INDENT>filters.append(cls.execution_date <= execution_date)<EOL><DEDENT>else:<EOL><INDENT>filters.append(cls.execution_date == execution_date)<EOL><DEDENT>query = (<EOL>session.query(cls).filter(and_(*filters))<EOL>.order_by(cls.execution_date.desc(), cls.timestamp.desc())<EOL>.limit(limit))<EOL>results = query.all()<EOL>return results<EOL>
Retrieve an XCom value, optionally meeting certain criteria
TODO: "pickling" has been deprecated and JSON is preferred.
"pickling" will be removed in Airflow 2.0.