Support Questions

Find answers, ask questions, and share your expertise

Can we use EL in falcon feed entity ?

avatar
Guru

@Team,

I want to use Expression Language in Feed Entity, just like the case we do in process entity For Example:

Process.xml

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <process name="yearWiseReplication-process" xmlns="uri:falcon:process:0.1"> <clusters> ..... <properties> <property name="feed_date" value="${formatTime(dateOffset(instanceTime(), -1, 'DAY'),'yyyy-MM-dd')}" /> </properties> .... </process>

Wanted to use in the following away, But I'm failing

Feed.xml

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <feed name="yearWiseReplication-output-feed" description="yearWiseReplication-output-feed" xmlns="uri:falcon:feed:0.1"> .... <locations> <location type="data" path="/hdptmp/availabilityYear/${YEAR}-${MONTH}-${DAY-1}" /> </locations> .... </feed>

My objective is to run the my job which processes previous day data(yesterday's data)

1 ACCEPTED SOLUTION

avatar

You cannot use ${DAY-1} in feed. IF you want to process previous day's data then you can achieve it using process by using yesterday EL expression.

<inputs>
        <input name="input" feed="SampleInput" start="yesterday(0,0)" end="today(-1,0)" />
    </inputs>

View solution in original post

2 REPLIES 2

avatar

You cannot use ${DAY-1} in feed. IF you want to process previous day's data then you can achieve it using process by using yesterday EL expression.

<inputs>
        <input name="input" feed="SampleInput" start="yesterday(0,0)" end="today(-1,0)" />
    </inputs>

avatar
Guru

Thanks @Sowmya Ramesh, I will try and will let you know.