Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions gxcloudstorage-awss3-v1/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,13 @@
<artifactId>gxcloudstorage-awss3-v1</artifactId>
<name>GeneXus AWS S3 (V1) Cloud Storage</name>

<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<version>${project.version}</version>
</dependency>
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<artifactId>gxcloudstorage-common</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.LogManager;
import com.amazonaws.HttpMethod;
import com.genexus.Application;
import com.genexus.util.GXService;
import com.genexus.util.StorageUtils;
import com.genexus.StructSdtMessages_Message;
Expand All @@ -29,6 +28,7 @@
import java.util.Date;
import java.util.List;


public class ExternalProviderS3V1 extends ExternalProviderBase implements ExternalProvider {
private static Logger logger = LogManager.getLogger(ExternalProviderS3V1.class);

Expand Down Expand Up @@ -74,10 +74,6 @@ public String getName(){
return NAME;
}

public ExternalProviderS3V1(String service) throws Exception{
this(Application.getGXServices().get(service));
}

public ExternalProviderS3V1() throws Exception{
super();
initialize();
Expand Down
1 change: 1 addition & 0 deletions gxcloudstorage-awss3-v2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.LogManager;

import com.genexus.Application;
import com.genexus.util.GXService;
import com.genexus.util.StorageUtils;
import com.genexus.StructSdtMessages_Message;
Expand Down Expand Up @@ -80,10 +79,6 @@ public String getName() {
return NAME;
}

public ExternalProviderS3V2(String service) throws Exception {
this(Application.getGXServices().get(service));
}

public ExternalProviderS3V2() throws Exception {
super();
initialize();
Expand Down
1 change: 1 addition & 0 deletions gxcloudstorage-azureblob/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.genexus.db.driver;

import com.genexus.Application;
import com.genexus.StructSdtMessages_Message;
import com.genexus.util.GXService;
import com.genexus.util.StorageUtils;
Expand Down Expand Up @@ -47,9 +46,6 @@ public class ExternalProviderAzureStorage extends ExternalProviderBase implement
private String privateContainerName;
private String publicContainerName;

public ExternalProviderAzureStorage(String service) throws Exception {
this(Application.getGXServices().get(service));
}

private void init() throws Exception {
try {
Expand Down
17 changes: 16 additions & 1 deletion gxcloudstorage-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,24 @@
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<artifactId>gxcommon</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j.version}</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j.version}</version>
</dependency>
</dependencies>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,17 @@ public ExternalProviderBase(GXService s) {
init();
}


/**
* Starts the necessary processes required for the usage of an External Object.
* This method ensures that the Provider is installed correctly before any
* operations are performed. It should be called at the beginning to set up
* the environment for the External Object.
*/
public void start() {

}

private void init() {
String aclS = getPropertyValue(DEFAULT_ACL, DEFAULT_ACL_DEPRECATED, "");
if (aclS.length() > 0) {
Expand Down
1 change: 1 addition & 0 deletions gxcloudstorage-googlecloudstorage/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.genexus.db.driver;

import com.genexus.Application;
import com.genexus.StructSdtMessages_Message;
import com.genexus.util.GXService;
import com.genexus.util.StorageUtils;
Expand Down Expand Up @@ -57,10 +56,6 @@ public ExternalProviderGoogle() throws Exception{
initialize();
}

public ExternalProviderGoogle(String service) throws Exception{
this(Application.getGXServices().get(service));
}

public ExternalProviderGoogle(GXService providerService) throws Exception{
super(providerService);
initialize();
Expand Down
1 change: 1 addition & 0 deletions gxcloudstorage-ibmcos/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>gxclassR</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
package com.genexus.db.driver;

import com.genexus.Application;
import com.genexus.StructSdtMessages_Message;
import com.genexus.util.GXService;
import com.genexus.util.GXServices;
import com.genexus.util.StorageUtils;
import com.ibm.cloud.objectstorage.ClientConfiguration;
import com.ibm.cloud.objectstorage.HttpMethod;
Expand All @@ -25,7 +23,6 @@
import java.util.Date;
import java.util.List;


public class ExternalProviderIBM extends ExternalProviderBase implements ExternalProvider {

private static Logger logger = LogManager.getLogger(ExternalProviderIBM.class);
Expand Down Expand Up @@ -57,14 +54,10 @@ public class ExternalProviderIBM extends ExternalProviderBase implements Externa
private String endpointUrl;
private int defaultExpirationMinutes = DEFAULT_EXPIRATION_MINUTES;

/* For compatibility reasons with GX16 U6 or lower*/
public ExternalProviderIBM() throws Exception {
this(GXServices.STORAGE_SERVICE);
}

public ExternalProviderIBM(String service) throws Exception {
this(Application.getGXServices().get(service));
}
public ExternalProviderIBM() throws Exception{
super();
init();
}

public ExternalProviderIBM(GXService providerService) throws Exception {
super(providerService);
Expand Down
12 changes: 6 additions & 6 deletions gxcloudstorage-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,36 +20,36 @@
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<groupId>${project.groupId}</groupId>
<artifactId>gxcloudstorage-common</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<groupId>${project.groupId}</groupId>
<artifactId>gxcloudstorage-ibmcos</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<groupId>${project.groupId}</groupId>
<artifactId>gxcloudstorage-googlecloudstorage</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<groupId>${project.groupId}</groupId>
<artifactId>gxcloudstorage-azureblob</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<groupId>${project.groupId}</groupId>
<artifactId>gxcloudstorage-awss3-v1</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.genexus</groupId>
<groupId>${project.groupId}</groupId>
<artifactId>gxcloudstorage-awss3-v2</artifactId>
<version>${project.version}</version>
<scope>test</scope>
Expand Down
2 changes: 1 addition & 1 deletion java/src/main/java/com/genexus/Application.java
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ private static ExternalProvider getExternalProviderImpl(String service)
throw new InternalError("Unrecognized External Provider class (ClassNotFound) : " + providerService.getName() + " / " + providerService.getClassName());
}
try {
externalProviderImpl = (ExternalProvider) providerClass.getConstructor(String.class).newInstance(service);
externalProviderImpl = (ExternalProvider) providerClass.getConstructor(GXService.class).newInstance(providerService);
}
catch (Exception e)
{
Expand Down