[ 
https://issues.apache.org/jira/browse/FLINK-41555?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Martijn Visser updated FLINK-41555:
-----------------------------------
    Affects Version/s: 1.20.5
                       2.2.1
                       2.3.0
                       1.15.4
                       2.4.0

> PlanReference.fromResource fails for a plan inside a JAR
> --------------------------------------------------------
>
>                 Key: FLINK-41555
>                 URL: https://issues.apache.org/jira/browse/FLINK-41555
>             Project: Flink
>          Issue Type: Bug
>          Components: Table SQL / Planner
>    Affects Versions: 1.15.4, 2.3.0, 2.2.1, 1.20.5, 2.4.0
>            Reporter: Martijn Visser
>            Assignee: Martijn Visser
>            Priority: Minor
>
> {{PlanReference.fromResource}} works when the plan is in a directory on the 
> classpath, but fails with {{IllegalArgumentException: URI is not 
> hierarchical}} when it is in a JAR, which is the usual place for a resource 
> of a job. {{PlannerBase#loadPlan}} turns the resource URL into a {{File}} 
> with {{new File(url.toURI)}}, which doesn't work for a {{jar:}} URL. We 
> should read the plan from the URL's stream instead. Until then, reading the 
> resource yourself and using {{PlanReference.fromJsonString}} works, which is 
> what the docs from FLINK-26250 show.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to