Spring Boot 应用使用 application.yml 和 application.properties 的区别
Spring 3.1 引入了新的
如何将 SAP Business Application Studio 里开发的 Java 应用部署到 SAP BTP 上
首先在项目根目录新建一个文件 manifest.yml,内容如下: --- applications: - name: bookstore path: srv/target/bookstore-exec.jar random-route: true services: - bookstore-hana 文件描述了应用程序的名称和可以找到应用程序存档的路径。 Sp
如何在 SAP BTP Java 应用里使用 SAP HANA 数据库
进入 SAP BTP cockpit: 把 CloudFoundry API endpoint 抄下来: https://api.cf.us10.hana.ondemand.com/ 收到如下输出: Setting API endpoint to https://api.cf.us10.hana.ondemand.com/…OK 使用 cf login 登录: 安装对应
一个实际的例子学习 SAP BTP Java 应用的 @Before 注解使用方式
我们可以使用了 On 注释,它替换了 CAP Java 运行时提供的事件的默认处理,以此来注册自定义事件处理程序,从而处理实体的 READ 或 CREATE 事件。 如果想增加默认处理,我们将使用 @Before 和 @After 注释。 使用 @Before 注释注册的事件处理程序旨在执行输入实体数据的验证。 这使得在创建订单之前验证特定书籍的可用库存成为可能。 相比之下,使用 @After
给 SAP BTP 创建的 Java 应用添加 Custom Event Handler 支持创建功能
在 productservice 文件夹下新建一个 handler 文件夹: 在该文件夹里新建一个 AdminService.java 文件: 此类现在处理针对 AdminService 的 Products 实体的 READ 和 CREATE 事件。 READ 操作只返回保存在内存中的所有实体。 CREATE 事件从 CQN 表示中提取有效负载并将其存储在内存中。 CD
如何在 SAP BTP Java 应用里使用 SQLite 数据库
SAP Cloud Application Programming 模型的推荐是将 service 和 model 模型的定义分离开。 因此,我们在 db 文件夹里定义 model model. 新建一个 schema.cds 文件: namespace sap.capire.products; using { Currency, cuid, managed, sap.
SAP Commerce Cloud B2B Organization 功能简介
Spartacus B2B Commerce Organization 允许公司管理通过 Spartacus 商务网站进行的采购。 可以将公司的采购经理设置为商业组织的管理员。 管理员可以创建代表组织、地区、城市、部门或公司中任何其他组织实体的单位。 然后将这些单位与买家、送货地址和成本中心相关联,所有这些都是为了允许、控制和跟踪支出。 本节中的以下页面描述了如何使用 B2B Commerce
使用 ABAP 控制 Android 原生应用
How to Control Native Android Apps with ABAP 业务流程不再仅在适用于 Windows 的 SAP GUI 中实现。 在其他设备上的其他 UI 上也越来越多地采取措施。 在这篇博文中,我描述了如何通过 PowerShell 使用 ABAP 在虚拟 Android 设备上控制本机应用程序和 Web 应用程序的可能性。 为了实现这个场景,我们使用这篇文章和
jMeter Thread group 对应的 constant timer
我创建了一个 CSV Data set config,sharing mode 设置成 Current thread,即每个线程会分别从头至尾读取 csv 文件。 我设置的线程数和 loop 数都为 5: csv 文件的内容: 可以看到,第二个线程的第二次,第三次,第四次和第五次执行,都被延迟到了很后面的位置。 如果在 thread group 层级加上一个 1秒的延时:
jMeter 里 CSV Data Set Config Sharing Mode 的含义详解
CSV Data Set Config in Sharing Mode - Made Easy 为了使性能测试更加真实,最好不要在每个线程组中使用相同的用户。因此,您需要一种方法来配置 Apache JMeter™ 以使用具有唯一用户数据的不同用户,并提出有关如何有效存储将在测试运行期间使用的用户数据的想法。 为此,JMeter 有一个非常有用的配置元素,称为 CSV 数据集配置。 “CSV
如何使用 jMeter Parallel Controller - 并行控制器以及一些常犯的错误
How to Use the Parallel Controller in JMeter 本文我们将分析 Apache JMeter™ 的扩展之一 - 并行控制器(Parallel Controller)。 该控制器由 BlazeMeter 开发,作为对开源社区的贡献,由 Andrey Pokhilko 和 Artem Fedorov 开发。 并行控制器可用于创建并行请求。 并行请求是指不是一
jMeter Transaction Controller 学习笔记
JMeter 的事务控制器是一个非常方便的工具,用于组织测试的不同部分并确定这些部分将如何出现在报告中。正如 Apache JMeter 的文档中所述:“事务控制器生成一个额外的样本,用于测量执行嵌套测试元素所花费的总时间。” 但这意味着什么?这个“额外样本”对您的 BlazeMeter 报告有什么影响? 如果您还不是非常熟悉这些功能,那么仅仅因为它是一个抽象的概念,可能会让人有点困惑。为了揭
如何用 SAP BTP 平台上的图形建模器创建一个 OData 服务
官方链接 移动后端工具是一组工具,使开发人员能够对 OData 服务建模并生成 Java EE Web 应用程序以实现 OData 服务,以及在预先存在的数据库模式中自动创建必要的数据库表。 在本教程中,您将使用 SAP Business Application Studio 中的 MBT 图形建模器重建 SAP Gateway Demo 系统 (ES5) 上公开可用的 GWSAMPLE_BA
使用 SAP Business Application Studio 搭建 CAP Java 开发环境
官方教程 为了确保一切设置正确,本教程还包括如何构建和运行一个简单的 Hello World 应用程序。 SAP Cloud 应用程序编程模型 (CAP) 支持 Java 和 Node.js 开发。 但是对于本教程,我们使用的是 Java。 CAP Java SDK 能够与 Spring Boot 紧密集成,Spring Boot 提供了许多开箱即用的功能。 这意味着,Spring Boot 将
SAP Commerce开发之如何找到某个页面对应的JSP实现页面
For example here below is the product detail page of Hybris Storefront. The requirement is to figure out which JSP page has implemented this UI.In some other SAP product it is quite straightforward to
Spring框架里解析配置文件的准确位置
We can define bean configuration in xml and then can get instantiated bean instance with help of all kinds of containers for example ClassPathXmlApplicationContext as displayed below:The content of Be
Java Volatile的一个实际应用场合
Consider the following example:package thread;public class ThreadVerify { public static boolean stop = false; public s
面向切片编程(AOP)应用的一些实际例子
The definition of AOP in wikipedia seems a little bit difficult for beginners to understand, so in this blog I use an example to introduce why we need it.Suppose I have an order command class which pe
SAP offline OData插件的JavaScript代码是如何调用到Android平台的Java代码的
In previous blog How is OData request routed to Offline data store by OData offline plugin, according to comment, the Offline store will only be available once it is opened successfully. The open
Java注解@Autowired的工作原理
Suppose I have a bean named HelloWorld which has a member attribute points to another bean User.With annotation @Autowired, as long as getBean is called in the runtime, the returned HelloWorld instanc