- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在将 Spring Cloud Stream 与 Azure 服务总线结合使用。这些是我的相关版本和依赖项:
<spring-cloud-azure.version>4.3.0</spring-cloud-azure.version>
<spring-cloud.version>2021.0.3</spring-cloud.version>
<dependency>
<groupId>com.azure.spring</groupId>
<artifactId>spring-cloud-azure-starter</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-stream</artifactId>
</dependency>
<dependency>
<groupId>com.azure.spring</groupId>
<artifactId>spring-cloud-azure-stream-binder-servicebus</artifactId>
<version>4.3.0</version>
</dependency>
我想实现重试策略,其中导致异常的消息会被重试多次,重试之间会有一些延迟。
从文档中,我看到有一些可用的配置设置,但似乎没有考虑这些设置。
配置属性:https://learn.microsoft.com/en-us/azure/developer/java/spring-framework/spring-cloud-azure-appendix
我的application.yml
:
spring:
cloud:
stream:
bindings:
onReceive-in-0:
destination: subscriber-1-input-queue
azure:
servicebus:
consumer:
retry:
exponential:
base-delay: 100
max-delay: 1000
max-retries: 5
fixed:
delay: 100
max-retries: 5
mode: exponential
connection-string: Endpoint=...
我的消费者:
@Slf4j
@Component
public class ValuesConsumer {
@Bean
public Consumer<String> onReceive() {
return (message) -> {
log.info("Received the value {} in Consumer", message);
switch (message) {
case "IntegrationException" -> throw new IntegrationException();
case "PoisonPillException" -> throw new PoisonPillException();
case "ProcessingException" -> throw new ProcessingException();
case "ValidationException" -> throw new ValidationException();
}
};
}
}
当我抛出异常时,消息处理会重试 10 次,没有任何延迟 - 实际上不会发生重试逻辑,只是消息被放弃,然后再次从队列中接收。
这是异常堆栈跟踪,重复 10 次:
2022-08-31 11:26:45.819 INFO 10544 --- [oundedElastic-3] com.demoasb.ValuesConsumer : Received the value IntegrationException in Consumer
2022-08-31 11:26:45.823 ERROR 10544 --- [oundedElastic-3] .s.i.s.i.ServiceBusInboundChannelAdapter : Error in the operation USER_CALLBACK occurred on entity subscriber-1-input-queue. Error: {}
com.azure.messaging.servicebus.ServiceBusException: Dispatcher has no subscribers for channel 'application.errorChannel'.; nested exception is org.springframework.integration.MessageDispatchingException: Dispatcher has no subscribers, failedMessage=ErrorMessage [payload=org.springframework.messaging.MessageHandlingException: error occurred in message handler [org.springframework.cloud.stream.function.FunctionConfiguration$FunctionToDestinationBinder$1@75a1e7f9]; nested exception is com.demoasb.exceptions.IntegrationException, failedMessage=GenericMessage [payload=byte[20], headers={azure_service_bus_expires_at=2022-09-14T09:26:45.740Z, azure_partition_key=415274637, azure_service_bus_received_message_context=com.azure.messaging.servicebus.ServiceBusReceivedMessageContext@6c625687, azure_service_bus_message_id=1981cbaf-68e3-62ec-b28e-9aaf5be48487, azure_service_bus_enqueued_sequence_number=46, azure_service_bus_enqueued_time=2022-08-31T09:26:45.740Z, azure_service_bus_lock_token=54cb3555-6253-4ef6-a858-de894358e56b, azure_service_bus_sequence_number=63, target-protocol=kafka, actionType=EventA, azure_service_bus_time_to_live=PT336H, azure_service_bus_delivery_count=0, azure_service_bus_state=ACTIVE, id=a896f227-28d2-c65e-afa3-b8e1e41b99c2, contentType=application/json, azure_service_bus_locked_until=2022-08-31T09:27:15.755Z, timestamp=1661938005819}], headers={id=d6a9c4de-a566-fb2d-f14f-568a3a2a4e43, timestamp=1661938005821}] for original GenericMessage [payload=byte[20], headers={azure_service_bus_expires_at=2022-09-14T09:26:45.740Z, azure_partition_key=415274637, azure_service_bus_received_message_context=com.azure.messaging.servicebus.ServiceBusReceivedMessageContext@6c625687, azure_service_bus_message_id=1981cbaf-68e3-62ec-b28e-9aaf5be48487, azure_service_bus_enqueued_sequence_number=46, azure_service_bus_enqueued_time=2022-08-31T09:26:45.740Z, azure_service_bus_lock_token=54cb3555-6253-4ef6-a858-de894358e56b, azure_service_bus_sequence_number=63, target-protocol=kafka, actionType=EventA, azure_service_bus_time_to_live=PT336H, azure_service_bus_delivery_count=0, azure_service_bus_state=ACTIVE, id=a896f227-28d2-c65e-afa3-b8e1e41b99c2, contentType=application/json, azure_service_bus_locked_until=2022-08-31T09:27:15.755Z, timestamp=1661938005819}]
at com.azure.messaging.servicebus.ServiceBusProcessorClient$1.onNext(ServiceBusProcessorClient.java:346) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at com.azure.messaging.servicebus.ServiceBusProcessorClient$1.onNext(ServiceBusProcessorClient.java:317) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onNext(FluxOnErrorResume.java:79) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxPublishOn$PublishOnSubscriber.runAsync(FluxPublishOn.java:440) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxPublishOn$PublishOnSubscriber.run(FluxPublishOn.java:527) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.scheduler.ImmediateScheduler$ImmediateSchedulerWorker.schedule(ImmediateScheduler.java:84) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxPublishOn$PublishOnSubscriber.trySchedule(FluxPublishOn.java:312) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxPublishOn$PublishOnSubscriber.onNext(FluxPublishOn.java:237) ~[reactor-core-3.4.22.jar:3.4.22]
at com.azure.messaging.servicebus.FluxAutoComplete$AutoCompleteSubscriber.hookOnNext(FluxAutoComplete.java:94) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at com.azure.messaging.servicebus.FluxAutoComplete$AutoCompleteSubscriber.hookOnNext(FluxAutoComplete.java:55) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at reactor.core.publisher.BaseSubscriber.onNext(BaseSubscriber.java:160) ~[reactor-core-3.4.22.jar:3.4.22]
at com.azure.messaging.servicebus.FluxAutoLockRenew$LockRenewSubscriber.hookOnNext(FluxAutoLockRenew.java:178) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at com.azure.messaging.servicebus.FluxAutoLockRenew$LockRenewSubscriber.hookOnNext(FluxAutoLockRenew.java:79) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at reactor.core.publisher.BaseSubscriber.onNext(BaseSubscriber.java:160) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxMap$MapSubscriber.onNext(FluxMap.java:122) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxMap$MapSubscriber.onNext(FluxMap.java:122) ~[reactor-core-3.4.22.jar:3.4.22]
at com.azure.messaging.servicebus.implementation.ServiceBusReceiveLinkProcessor.drainQueue(ServiceBusReceiveLinkProcessor.java:516) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at com.azure.messaging.servicebus.implementation.ServiceBusReceiveLinkProcessor.drain(ServiceBusReceiveLinkProcessor.java:475) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at com.azure.messaging.servicebus.implementation.ServiceBusReceiveLinkProcessor.lambda$onNext$2(ServiceBusReceiveLinkProcessor.java:227) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
at reactor.core.publisher.LambdaSubscriber.onNext(LambdaSubscriber.java:160) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxPublishOn$PublishOnSubscriber.runAsync(FluxPublishOn.java:440) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.publisher.FluxPublishOn$PublishOnSubscriber.run(FluxPublishOn.java:527) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.scheduler.WorkerTask.call(WorkerTask.java:84) ~[reactor-core-3.4.22.jar:3.4.22]
at reactor.core.scheduler.WorkerTask.call(WorkerTask.java:37) ~[reactor-core-3.4.22.jar:3.4.22]
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[na:na]
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) ~[na:na]
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[na:na]
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[na:na]
at java.base/java.lang.Thread.run(Thread.java:833) ~[na:na]
Caused by: org.springframework.messaging.MessageDeliveryException: Dispatcher has no subscribers for channel 'application.errorChannel'.; nested exception is org.springframework.integration.MessageDispatchingException: Dispatcher has no subscribers, failedMessage=ErrorMessage [payload=org.springframework.messaging.MessageHandlingException: error occurred in message handler [org.springframework.cloud.stream.function.FunctionConfiguration$FunctionToDestinationBinder$1@75a1e7f9]; nested exception is com.demoasb.exceptions.IntegrationException, failedMessage=GenericMessage [payload=byte[20], headers={azure_service_bus_expires_at=2022-09-14T09:26:45.740Z, azure_partition_key=415274637, azure_service_bus_received_message_context=com.azure.messaging.servicebus.ServiceBusReceivedMessageContext@6c625687, azure_service_bus_message_id=1981cbaf-68e3-62ec-b28e-9aaf5be48487, azure_service_bus_enqueued_sequence_number=46, azure_service_bus_enqueued_time=2022-08-31T09:26:45.740Z, azure_service_bus_lock_token=54cb3555-6253-4ef6-a858-de894358e56b, azure_service_bus_sequence_number=63, target-protocol=kafka, actionType=EventA, azure_service_bus_time_to_live=PT336H, azure_service_bus_delivery_count=0, azure_service_bus_state=ACTIVE, id=a896f227-28d2-c65e-afa3-b8e1e41b99c2, contentType=application/json, azure_service_bus_locked_until=2022-08-31T09:27:15.755Z, timestamp=1661938005819}], headers={id=d6a9c4de-a566-fb2d-f14f-568a3a2a4e43, timestamp=1661938005821}] for original GenericMessage [payload=byte[20], headers={azure_service_bus_expires_at=2022-09-14T09:26:45.740Z, azure_partition_key=415274637, azure_service_bus_received_message_context=com.azure.messaging.servicebus.ServiceBusReceivedMessageContext@6c625687, azure_service_bus_message_id=1981cbaf-68e3-62ec-b28e-9aaf5be48487, azure_service_bus_enqueued_sequence_number=46, azure_service_bus_enqueued_time=2022-08-31T09:26:45.740Z, azure_service_bus_lock_token=54cb3555-6253-4ef6-a858-de894358e56b, azure_service_bus_sequence_number=63, target-protocol=kafka, actionType=EventA, azure_service_bus_time_to_live=PT336H, azure_service_bus_delivery_count=0, azure_service_bus_state=ACTIVE, id=a896f227-28d2-c65e-afa3-b8e1e41b99c2, contentType=application/json, azure_service_bus_locked_until=2022-08-31T09:27:15.755Z, timestamp=1661938005819}]
at org.springframework.integration.channel.AbstractSubscribableChannel.doSend(AbstractSubscribableChannel.java:76) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.channel.AbstractMessageChannel.send(AbstractMessageChannel.java:317) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.channel.AbstractMessageChannel.send(AbstractMessageChannel.java:272) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:187) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:166) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:47) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.messaging.core.AbstractMessageSendingTemplate.send(AbstractMessageSendingTemplate.java:109) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.integration.handler.AbstractMessageProducingHandler.sendOutput(AbstractMessageProducingHandler.java:457) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.handler.AbstractMessageProducingHandler.doProduceOutput(AbstractMessageProducingHandler.java:325) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.handler.AbstractMessageProducingHandler.produceOutput(AbstractMessageProducingHandler.java:268) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.handler.AbstractMessageProducingHandler.sendOutputs(AbstractMessageProducingHandler.java:232) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.handler.AbstractReplyProducingMessageHandler.handleMessageInternal(AbstractReplyProducingMessageHandler.java:142) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.handler.AbstractMessageHandler.handleMessage(AbstractMessageHandler.java:56) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.dispatcher.BroadcastingDispatcher.invokeHandler(BroadcastingDispatcher.java:222) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.dispatcher.BroadcastingDispatcher.dispatch(BroadcastingDispatcher.java:178) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.channel.AbstractSubscribableChannel.doSend(AbstractSubscribableChannel.java:72) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.channel.AbstractMessageChannel.send(AbstractMessageChannel.java:317) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.channel.AbstractMessageChannel.send(AbstractMessageChannel.java:272) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:187) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:166) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:47) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.messaging.core.AbstractMessageSendingTemplate.send(AbstractMessageSendingTemplate.java:109) ~[spring-messaging-5.3.22.jar:5.3.22]
at org.springframework.integration.endpoint.MessageProducerSupport.sendErrorMessageIfNecessary(MessageProducerSupport.java:262) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.endpoint.MessageProducerSupport.sendMessage(MessageProducerSupport.java:219) ~[spring-integration-core-5.5.14.jar:5.5.14]
at com.azure.spring.integration.servicebus.inbound.ServiceBusInboundChannelAdapter.access$600(ServiceBusInboundChannelAdapter.java:73) ~[spring-integration-azure-servicebus-4.3.0.jar:4.3.0]
at com.azure.spring.integration.servicebus.inbound.ServiceBusInboundChannelAdapter$IntegrationRecordMessageListener.onMessage(ServiceBusInboundChannelAdapter.java:201) ~[spring-integration-azure-servicebus-4.3.0.jar:4.3.0]
at com.azure.spring.integration.servicebus.inbound.ServiceBusInboundChannelAdapter$IntegrationRecordMessageListener.onMessage(ServiceBusInboundChannelAdapter.java:186) ~[spring-integration-azure-servicebus-4.3.0.jar:4.3.0]
at com.azure.messaging.servicebus.ServiceBusProcessorClient$1.onNext(ServiceBusProcessorClient.java:343) ~[azure-messaging-servicebus-7.9.1.jar:7.9.1]
... 28 common frames omitted
Caused by: org.springframework.integration.MessageDispatchingException: Dispatcher has no subscribers
at org.springframework.integration.dispatcher.BroadcastingDispatcher.dispatch(BroadcastingDispatcher.java:153) ~[spring-integration-core-5.5.14.jar:5.5.14]
at org.springframework.integration.channel.AbstractSubscribableChannel.doSend(AbstractSubscribableChannel.java:72) ~[spring-integration-core-5.5.14.jar:5.5.14]
... 55 common frames omitted
2022-08-31 11:26:45.824 WARN 10544 --- [oundedElastic-3] c.a.m.s.ServiceBusProcessorClient : Error when processing message. Abandoning message.
Dispatcher has no subscribers for channel 'application.errorChannel'.; nested exception is org.springframework.integration.MessageDispatchingException: Dispatcher has no subscribers, failedMessage=ErrorMessage [payload=org.springframework.messaging.MessageHandlingException: error occurred in message handler [org.springframework.cloud.stream.function.FunctionConfiguration$FunctionToDestinationBinder$1@75a1e7f9]; nested exception is com.demoasb.exceptions.IntegrationException, failedMessage=GenericMessage [payload=byte[20], headers={azure_service_bus_expires_at=2022-09-14T09:26:45.740Z, azure_partition_key=415274637, azure_service_bus_received_message_context=com.azure.messaging.servicebus.ServiceBusReceivedMessageContext@6c625687, azure_service_bus_message_id=1981cbaf-68e3-62ec-b28e-9aaf5be48487, azure_service_bus_enqueued_sequence_number=46, azure_service_bus_enqueued_time=2022-08-31T09:26:45.740Z, azure_service_bus_lock_token=54cb3555-6253-4ef6-a858-de894358e56b, azure_service_bus_sequence_number=63, target-protocol=kafka, actionType=EventA, azure_service_bus_time_to_live=PT336H, azure_service_bus_delivery_count=0, azure_service_bus_state=ACTIVE, id=a896f227-28d2-c65e-afa3-b8e1e41b99c2, contentType=application/json, azure_service_bus_locked_until=2022-08-31T09:27:15.755Z, timestamp=1661938005819}], headers={id=d6a9c4de-a566-fb2d-f14f-568a3a2a4e43, timestamp=1661938005821}] for original GenericMessage [payload=byte[20], headers={azure_service_bus_expires_at=2022-09-14T09:26:45.740Z, azure_partition_key=415274637, azure_service_bus_received_message_context=com.azure.messaging.servicebus.ServiceBusReceivedMessageContext@6c625687, azure_service_bus_message_id=1981cbaf-68e3-62ec-b28e-9aaf5be48487, azure_service_bus_enqueued_sequence_number=46, azure_service_bus_enqueued_time=2022-08-31T09:26:45.740Z, azure_service_bus_lock_token=54cb3555-6253-4ef6-a858-de894358e56b, azure_service_bus_sequence_number=63, target-protocol=kafka, actionType=EventA, azure_service_bus_time_to_live=PT336H, azure_service_bus_delivery_count=0, azure_service_bus_state=ACTIVE, id=a896f227-28d2-c65e-afa3-b8e1e41b99c2, contentType=application/json, azure_service_bus_locked_until=2022-08-31T09:27:15.755Z, timestamp=1661938005819}]
2022-08-31 11:26:45.952 INFO 10544 --- [oundedElastic-3] c.a.m.s.i.ServiceBusReceiveLinkProcessor : {"az.sdk.message":"Adding credits.","prefetch":0,"requested":2,"linkCredits":0,"expectedTotalCredit":2,"queuedMessages":1,"creditsToAdd":1,"messageQueueSize":0}
如何正确实现延迟策略?我的配置中是否缺少任何内容?
最佳答案
要设置Service Bus Binder的重试策略,需要在绑定(bind)级别进行配置,例如:
spring:
cloud:
stream:
servicebus:
bindings:
onReceive-in-0:
consumer:
retry:
fixed:
delay: 100
max-retries: 5
mode: fixed
关于java - 使用 Spring Cloud Stream 的 Azure 服务总线重试策略,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/73554259/
我在网上搜索但没有找到任何合适的文章解释如何使用 javascript 使用 WCF 服务,尤其是 WebScriptEndpoint。 任何人都可以对此给出任何指导吗? 谢谢 最佳答案 这是一篇关于
我正在编写一个将运行 Linux 命令的 C 程序,例如: cat/etc/passwd | grep 列表 |剪切-c 1-5 我没有任何结果 *这里 parent 等待第一个 child (chi
所以我正在尝试处理文件上传,然后将该文件作为二进制文件存储到数据库中。在我存储它之后,我尝试在给定的 URL 上提供文件。我似乎找不到适合这里的方法。我需要使用数据库,因为我使用 Google 应用引
我正在尝试制作一个宏,将下面的公式添加到单元格中,然后将其拖到整个列中并在 H 列中复制相同的公式 我想在 F 和 H 列中输入公式的数据 Range("F1").formula = "=IF(ISE
问题类似于this one ,但我想使用 OperatorPrecedenceParser 解析带有函数应用程序的表达式在 FParsec . 这是我的 AST: type Expression =
我想通过使用 sequelize 和 node.js 将这个查询更改为代码取决于在哪里 select COUNT(gender) as genderCount from customers where
我正在使用GNU bash,版本5.0.3(1)-发行版(x86_64-pc-linux-gnu),我想知道为什么简单的赋值语句会出现语法错误: #/bin/bash var1=/tmp
这里,为什么我的代码在 IE 中不起作用。我的代码适用于所有浏览器。没有问题。但是当我在 IE 上运行我的项目时,它发现错误。 而且我的 jquery 类和 insertadjacentHTMl 也不
我正在尝试更改标签的innerHTML。我无权访问该表单,因此无法编辑 HTML。标签具有的唯一标识符是“for”属性。 这是输入和标签的结构:
我有一个页面,我可以在其中返回用户帖子,可以使用一些 jquery 代码对这些帖子进行即时评论,在发布新评论后,我在帖子下插入新评论以及删除 按钮。问题是 Delete 按钮在新插入的元素上不起作用,
我有一个大约有 20 列的“管道分隔”文件。我只想使用 sha1sum 散列第一列,它是一个数字,如帐号,并按原样返回其余列。 使用 awk 或 sed 执行此操作的最佳方法是什么? Accounti
我需要将以下内容插入到我的表中...我的用户表有五列 id、用户名、密码、名称、条目。 (我还没有提交任何东西到条目中,我稍后会使用 php 来做)但由于某种原因我不断收到这个错误:#1054 - U
所以我试图有一个输入字段,我可以在其中输入任何字符,但然后将输入的值小写,删除任何非字母数字字符,留下“。”而不是空格。 例如,如果我输入: 地球的 70% 是水,-!*#$^^ & 30% 土地 输
我正在尝试做一些我认为非常简单的事情,但出于某种原因我没有得到想要的结果?我是 javascript 的新手,但对 java 有经验,所以我相信我没有使用某种正确的规则。 这是一个获取输入值、检查选择
我想使用 angularjs 从 mysql 数据库加载数据。 这就是应用程序的工作原理;用户登录,他们的用户名存储在 cookie 中。该用户名显示在主页上 我想获取这个值并通过 angularjs
我正在使用 autoLayout,我想在 UITableViewCell 上放置一个 UIlabel,它应该始终位于单元格的右侧和右侧的中心。 这就是我想要实现的目标 所以在这里你可以看到我正在谈论的
我需要与 MySql 等效的 elasticsearch 查询。我的 sql 查询: SELECT DISTINCT t.product_id AS id FROM tbl_sup_price t
我正在实现代码以使用 JSON。 func setup() { if let flickrURL = NSURL(string: "https://api.flickr.com/
我尝试使用for循环声明变量,然后测试cols和rols是否相同。如果是,它将运行递归函数。但是,我在 javascript 中执行 do 时遇到问题。有人可以帮忙吗? 现在,在比较 col.1 和
我举了一个我正在处理的问题的简短示例。 HTML代码: 1 2 3 CSS 代码: .BB a:hover{ color: #000; } .BB > li:after {
我是一名优秀的程序员,十分优秀!