Skip to content

Commit

Permalink
Enable all charsets in native image for quarkus-tika
Browse files Browse the repository at this point in the history
  • Loading branch information
sberyozkin committed Oct 18, 2021
1 parent 93f3547 commit 3613236
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import io.quarkus.deployment.annotations.ExecutionTime;
import io.quarkus.deployment.annotations.Record;
import io.quarkus.deployment.builditem.FeatureBuildItem;
import io.quarkus.deployment.builditem.NativeImageEnableAllCharsetsBuildItem;
import io.quarkus.deployment.builditem.nativeimage.NativeImageResourceBuildItem;
import io.quarkus.deployment.builditem.nativeimage.NativeImageResourceDirectoryBuildItem;
import io.quarkus.deployment.builditem.nativeimage.RuntimeInitializedClassBuildItem;
Expand Down Expand Up @@ -87,6 +88,11 @@ public void registerPdfBoxResources(BuildProducer<NativeImageResourceDirectoryBu
resource.produce(new NativeImageResourceDirectoryBuildItem("org/apache/fontbox/unicode"));
}

@BuildStep
public NativeImageEnableAllCharsetsBuildItem registerAllCharsets() {
return new NativeImageEnableAllCharsetsBuildItem();
}

@BuildStep
@Record(ExecutionTime.STATIC_INIT)
void initializeTikaParser(BeanContainerBuildItem beanContainer, TikaRecorder recorder,
Expand Down
4 changes: 0 additions & 4 deletions integration-tests/tika/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -99,10 +99,6 @@
<name>native</name>
</property>
</activation>
<!-- add some custom config, the rest comes from parent -->
<properties>
<quarkus.native.add-all-charsets>true</quarkus.native.add-all-charsets>
</properties>
</profile>
</profiles>

Expand Down

0 comments on commit 3613236

Please sign in to comment.