Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Polish

1) Wtyczka powinna posiadać w pom.xml jako parenta moduł plusworkflow-plugin-parent z konkretną wersją systemu >= 4.0.34:

Code Block
<parent>
	<groupId>com.suncode</groupId>
	<artifactId>plusworkflow-plugin-parent</artifactId>
	<version>4.0.35</version>
</parent>

 

2) W resources/suncode-plugin.xml podajemy wymaganą wersję systemu na

...

, która ustawiona jest w pomie jako parent

Code Block
<plugin key="${project.groupId}-${project.artifactId}" name="Plugin Configuration Manager">
    <plugin-details>
        <requirements>
            <plusworkflow>4.0.35</plusworkflow>
        </requirements>
    </plugin-details>
</plugin>


3) Wszystkie publiczne zależności systemowe (na ten moment to plusworkflow-api i plugin-framework-api) powinny mieć scope na provided

Code Block
<dependency>
	<groupId>com.suncode</groupId>
	<artifactId>plusworkflow-api</artifactId>
	<scope>provided</scope>
</dependency>


4) Najlepiej jakby wtyczki korzystały tylko z publicznych zależności systemowych. Dla nowych wtyczek punkt jest obowiązkowy. Dla istniejących wtyczek i tak będzie trzeba z czasem wyeliminować pozostałe zależności systemowe.
Na ten moment w takich zależnościach systemowych, ale niepublicznych (np do plusworfklow-core) zawsze dodajemy wykluczenia

Code Block
<dependency>
	<groupId>com.suncode</groupId>
	<artifactId>plusworkflow-core</artifactId>
	<scope>provided</scope>
	<exclusions>
		<exclusion>
			<groupId>*</groupId>
			<artifactId>*</artifactId>
		</exclusion>
	</exclusions>
</dependency>

 

5) Zależności do naszych wtyczek zawsze dajemy w scope-provided, w konkretnej wersji i z wykluczeniami na wszystko (*).

Code Block
<dependency>
	<groupId>com.suncode.plugin</groupId>
	<artifactId>plugin-configuration-manager</artifactId>
	<version>4.0.5</version>
	<scope>provided</scope>
	<exclusions>
		<exclusion>
			<groupId>*</groupId>
			<artifactId>*</artifactId>
		</exclusion>
	</exclusions>
</dependency>

 

6) Zewnętrzne biblioteki powinny być zdeklarowane w pomie wtyczki razem z wersją. Nie chcemy dziedziczyć zewnętrznych bibliotek z zależności systemowych, chyba że znajdują się w publicznych zależnościach w sekcji <dependency>.

 

7) Usunięcie pluginu maven-bundle-plugin maven-compiler-plugin z pom.xml

Code Block
<plugin>
	<groupId>org.apache.felix</groupId>
	<artifactId>maven-bundle-plugin</artifactId>
	<extensions>true</extensions>
	<configuration>
		<instructions>
			<Import-Package>*;resolution:=optional</Import-Package>
			<Embed-Dependency>!slf4j-log4j12,!slf4j-api,!log4j,*;scope=compile|runtime|system,jackson-datatype-jsr310</Embed-Dependency>
		</instructions>
	</configuration>
</plugin>
<plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-compiler-plugin</artifactId>
	<configuration>
		<source>1.8</source>
		<target>1.8</target>
	</configuration>
</plugin>

 

8) Nazwy pakietów nie mogą się powtarzać. Nazwy pakietów powinny wyglądać w następujący sposób: com.suncode.id-wtyczki.xyz

 

9) Sprawdzić na endpoincie systemowym /PlusWorkflow/api/plugins/debug czy wszystko wygoląda prawidłowo, co jest w host- czyli dostarczane do wtyczki przez system i w unresolved. 

 

English

1) The plugin should have a plusworkflow-plugin-parent module in pom.xml as a parent with specific system version >= 4.0.34:

Code Block
<parent>
	<groupId>com.suncode</groupId>
	<artifactId>plusworkflow-plugin-parent</artifactId>
	<version>4.0.35</version>
</parent>

2) In resources/suncode-plugin.xml specify the required system version to the one set in pom as parent

Code Block
<plugin key="${project.groupId}-${project.artifactId}" name="Plugin Configuration Manager">
    <plugin-details>
        <requirements>
            <plusworkflow>4.0.35</plusworkflow>
        </requirements>
    </plugin-details>
</plugin>


3) All public system dependencies (at the moment it's plusworkflow-api and plugin-framework-api) should have scope on provided

Code Block
<dependency>
	<groupId>com.suncode</groupId>
	<artifactId>plusworkflow-api</artifactId>
	<scope>provided</scope>
</dependency>


4) Preferably, plugins should only use public system dependencies. For new plugins, the point is mandatory. For existing plugins, the remaining system dependencies will have to be eliminated over time anyway. At this moment in such system dependencies, but non-public ones (e.g. to plusworfklow-core) always add exclusions

Code Block
<dependency>
	<groupId>com.suncode</groupId>
	<artifactId>plusworkflow-core</artifactId>
	<scope>provided</scope>
	<exclusions>
		<exclusion>
			<groupId>*</groupId>
			<artifactId>*</artifactId>
		</exclusion>
	</exclusions>
</dependency>

 

5) Always specify dependencies for plugins in scope-provided, in a specific version and with exclusions for everything (*).

Code Block
<dependency>
	<groupId>com.suncode.plugin</groupId>
	<artifactId>plugin-configuration-manager</artifactId>
	<version>4.0.5</version>
	<scope>provided</scope>
	<exclusions>
		<exclusion>
			<groupId>*</groupId>
			<artifactId>*</artifactId>
		</exclusion>
	</exclusions>
</dependency>

 

6) External libraries should be declared in the plugin pom along with the version. We do not want to inherit external libraries from system dependencies unless they are in public dependencies in the <dependency> section.

 

7) Remove maven-bundle-plugin and maven-compiler-plugin plugins from pom.xml

Code Block
<plugin>
	<groupId>org.apache.felix</groupId>
	<artifactId>maven-bundle-plugin</artifactId>
	<extensions>true</extensions>
	<configuration>
		<instructions>
			<Import-Package>*;resolution:=optional</Import-Package>
			<Embed-Dependency>!slf4j-log4j12,!slf4j-api,!log4j,*;scope=compile|runtime|system,jackson-datatype-jsr310</Embed-Dependency>
		</instructions>
	</configuration>
</plugin>
<plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-compiler-plugin</artifactId>
	<configuration>
		<source>1.8</source>
		<target>1.8</target>
	</configuration>
</plugin>

 

8) Package names can't repeat each other. Package names should look like this: com.suncode.id-plugins.xyz

 

9) Check on the system endpoint /PlusWorkflow/api/plugins/debug to make sure everything looks correct, what is in host- that is, delivered to the plugin by the system and in unresolved.